Skip to main content

AWS Lambda .NET Library

---

cdk-constructs: Experimental

The APIs of higher level constructs in this module are experimental and under active development. They are subject to non-backward compatible changes or removal in any future version. These are not subject to the Semantic Versioning model and breaking changes will be announced in the release notes. This means that while you may use them, you may need to update your source code when upgrading to a newer version of this package.


This library provides constructs for .NET Lambda functions.

To use this module you will either need to have .NET SDK installed (.NET 6.0 or later) with the AWS Lambda Tools for .NET or Docker installed.

.NET Function

Define a DotNetFunction:

dotnet.DotNetFunction(self, "MyFunction",
    project_dir="src/MyFunction"
)

All other properties of lambda.Function are supported, see also the AWS Lambda construct library.

Custom Runtime and Native AOT

With this construct it is possible to use s custom runtime by setting the runtime to PROVIDED_AL2. This allows you to run unsupported .NET runtime versions like .NET 7.0 or Native AOT. Setting the runtime to PROVIDED_AL2 will instruct CDK and the AWS Lambda Tools for .NET to build your project in a Docker container based of Amazon Linux 2. An example can be found below.

dotnet.DotNetFunction(self, "MyFunction",
    project_dir="src/MyFunction",
    runtime=lambda_.Runtime.PROVIDED_AL2,
    bundling=dotnet.BundlingOptions(
        msbuild_parameters=["/p:PublishAot=true"]
    )
)

Publishing your application with Native AOT requires you to use the same processor architecture for the Lambda function as for your build environment. Without specification, the construct automatically selects the processor architecture of the machine where CDK is building your project.

Community Extensions

We encourage the development of Community Service Extensions that support advanced features. Here are some useful extensions that we have reviewed:

Please submit a pull request so that we can review your service extension and list it here.

Metadata

Release files for cdklabs.aws-lambda-dotnet 0.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cdklabs.aws-lambda-dotnet 0.0.0
File Size Uploaded Provenance Actions
cdklabs.aws-lambda-dotnet-0.0.0.tar.gz 73.6 kB Without provenance Details for cdklabs.aws-lambda-dotnet-0.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for cdklabs.aws-lambda-dotnet 0.0.0
File Interpreter ABI Platform Actions
cdklabs.aws_lambda_dotnet-0.0.0-py3-none-any.whl Python 3 none any Details for cdklabs.aws_lambda_dotnet-0.0.0-py3-none-any.whl

Total release size: 145.3 kB

Release files / cdklabs.aws-lambda-dotnet-0.0.0.tar.gz

Download URL cdklabs.aws-lambda-dotnet-0.0.0.tar.gz
Size 73.6 kB
Tags Source
SHA-256 checksum
How to use checksums
60fa432db6237c20d33fe80cdb9aca7fdd849671f44943ee0100cfd502c7437a
BLAKE2b-256 checksum
How to use checksums
2ff2cd3ae220af157fac2e92f0aa900a98b3ef848247402449d01ab5b3516a23
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.12.1

Release files / cdklabs.aws_lambda_dotnet-0.0.0-py3-none-any.whl

Download URL cdklabs.aws_lambda_dotnet-0.0.0-py3-none-any.whl
Size 71.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d080de047028669a804728d5b47f402207e787fa9bdd180e8fabdd4147f9d9eb
BLAKE2b-256 checksum
How to use checksums
57138ae56f2c6d1f1e14e4f3adf93aab20c178f099925d283e502609ee883dcc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.12.1

Security for cdklabs.aws-lambda-dotnet 0.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page