We recommend new projects start with resources from the AWS provider.
aws-native.lambda.Function
Explore with Pulumi AI
We recommend new projects start with resources from the AWS provider.
The AWS::Lambda::Function resource creates a Lambda function. To create a function, you need a deployment package and an execution role. The deployment package is a .zip file archive or container image that contains your function code. The execution role grants the function permission to use AWS services, such as Amazon CloudWatch Logs for log streaming and AWS X-Ray for request tracing.
You set the package type to Image if the deployment package is a container image. For these functions, include the URI of the container image in the ECR registry in the ImageUri property of the Code property. You do not need to specify the handler and runtime properties.
You set the package type to Zip if the deployment package is a .zip file archive. For these functions, specify the S3 location of your .zip file in the Code property. Alternatively, for Node.js and Python functions, you can define your function inline in the ZipFile property of the Code property. In both cases, you must also specify the handler and runtime properties.
You can use code signing if your deployment package is a .zip file archive. To enable code signing for this function, specify the ARN of a code-signing configuration. When a user attempts to deploy a code package with UpdateFunctionCode, Lambda checks that the code package has a valid signature from a trusted publisher. The code-signing configuration includes a set of signing profiles, which define the trusted publishers for this function.
When you update a AWS::Lambda::Function resource, CFNshort calls the UpdateFunctionConfiguration and UpdateFunctionCode LAM APIs under the hood. Because these calls happen sequentially, and invocations can happen between these calls, your function may encounter errors in the time between the calls. For example, if you remove an environment variable, and the code that references that environment variable in the same CFNshort update, you may see invocation errors related to a missing environment variable. To work around this, you can invoke your function against a version or alias by default, rather than the $LATEST version.
Note that you configure provisioned concurrency on a AWS::Lambda::Version or a AWS::Lambda::Alias.
For a complete introduction to Lambda functions, see What is Lambda? in the Lambda developer guide.
Example Usage
Example
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AwsNative = Pulumi.AwsNative;
return await Deployment.RunAsync(() => 
{
    var function = new AwsNative.Lambda.Function("function", new()
    {
        Handler = "index.handler",
        Role = "arn:aws:iam::123456789012:role/lambda-role",
        Code = new AwsNative.Lambda.Inputs.FunctionCodeArgs
        {
            ZipFile = @"exports.handler = function(event){
    console.log(JSON.stringify(event, null, 2))
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!')
    }
    return response
};
",
        },
        Runtime = "nodejs18.x",
        TracingConfig = new AwsNative.Lambda.Inputs.FunctionTracingConfigArgs
        {
            Mode = AwsNative.Lambda.FunctionTracingConfigMode.Active,
        },
    });
    var version = new AwsNative.Lambda.Version("version", new()
    {
        FunctionName = function.Id,
        Description = "v1",
    });
    var @alias = new AwsNative.Lambda.Alias("alias", new()
    {
        FunctionName = function.Id,
        FunctionVersion = version.Version,
        Name = "BLUE",
    });
});
package main
import (
	"github.com/pulumi/pulumi-aws-native/sdk/go/aws/lambda"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		function, err := lambda.NewFunction(ctx, "function", &lambda.FunctionArgs{
			Handler: pulumi.String("index.handler"),
			Role:    pulumi.String("arn:aws:iam::123456789012:role/lambda-role"),
			Code: &lambda.FunctionCodeArgs{
				ZipFile: pulumi.String(`exports.handler = function(event){
    console.log(JSON.stringify(event, null, 2))
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!')
    }
    return response
};
`),
			},
			Runtime: pulumi.String("nodejs18.x"),
			TracingConfig: &lambda.FunctionTracingConfigArgs{
				Mode: lambda.FunctionTracingConfigModeActive,
			},
		})
		if err != nil {
			return err
		}
		version, err := lambda.NewVersion(ctx, "version", &lambda.VersionArgs{
			FunctionName: function.ID(),
			Description:  pulumi.String("v1"),
		})
		if err != nil {
			return err
		}
		_, err = lambda.NewAlias(ctx, "alias", &lambda.AliasArgs{
			FunctionName:    function.ID(),
			FunctionVersion: version.Version,
			Name:            pulumi.String("BLUE"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as aws_native from "@pulumi/aws-native";
const _function = new aws_native.lambda.Function("function", {
    handler: "index.handler",
    role: "arn:aws:iam::123456789012:role/lambda-role",
    code: {
        zipFile: `exports.handler = function(event){
    console.log(JSON.stringify(event, null, 2))
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!')
    }
    return response
};
`,
    },
    runtime: "nodejs18.x",
    tracingConfig: {
        mode: aws_native.lambda.FunctionTracingConfigMode.Active,
    },
});
const version = new aws_native.lambda.Version("version", {
    functionName: _function.id,
    description: "v1",
});
const alias = new aws_native.lambda.Alias("alias", {
    functionName: _function.id,
    functionVersion: version.version,
    name: "BLUE",
});
import pulumi
import pulumi_aws_native as aws_native
function = aws_native.lambda_.Function("function",
    handler="index.handler",
    role="arn:aws:iam::123456789012:role/lambda-role",
    code={
        "zip_file": """exports.handler = function(event){
    console.log(JSON.stringify(event, null, 2))
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!')
    }
    return response
};
""",
    },
    runtime="nodejs18.x",
    tracing_config={
        "mode": aws_native.lambda_.FunctionTracingConfigMode.ACTIVE,
    })
version = aws_native.lambda_.Version("version",
    function_name=function.id,
    description="v1")
alias = aws_native.lambda_.Alias("alias",
    function_name=function.id,
    function_version=version.version,
    name="BLUE")
Coming soon!
Example
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AwsNative = Pulumi.AwsNative;
return await Deployment.RunAsync(() => 
{
    var function = new AwsNative.Lambda.Function("function", new()
    {
        Handler = "index.handler",
        Role = "arn:aws:iam::123456789012:role/lambda-role",
        Code = new AwsNative.Lambda.Inputs.FunctionCodeArgs
        {
            ZipFile = @"exports.handler = function(event){
    console.log(JSON.stringify(event, null, 2))
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello again from Lambda!')
    }
    return response
}
",
        },
        Runtime = "nodejs18.x",
        TracingConfig = new AwsNative.Lambda.Inputs.FunctionTracingConfigArgs
        {
            Mode = AwsNative.Lambda.FunctionTracingConfigMode.Active,
        },
    });
    var version = new AwsNative.Lambda.Version("version", new()
    {
        FunctionName = function.Id,
        Description = "v1",
    });
    var newVersion = new AwsNative.Lambda.Version("newVersion", new()
    {
        FunctionName = function.Id,
        Description = "v2",
    });
    var @alias = new AwsNative.Lambda.Alias("alias", new()
    {
        FunctionName = function.Id,
        FunctionVersion = newVersion.Version,
        Name = "BLUE",
        RoutingConfig = new AwsNative.Lambda.Inputs.AliasRoutingConfigurationArgs
        {
            AdditionalVersionWeights = new[]
            {
                new AwsNative.Lambda.Inputs.AliasVersionWeightArgs
                {
                    FunctionVersion = version.Version,
                    FunctionWeight = 0.5,
                },
            },
        },
    });
});
package main
import (
	"github.com/pulumi/pulumi-aws-native/sdk/go/aws/lambda"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		function, err := lambda.NewFunction(ctx, "function", &lambda.FunctionArgs{
			Handler: pulumi.String("index.handler"),
			Role:    pulumi.String("arn:aws:iam::123456789012:role/lambda-role"),
			Code: &lambda.FunctionCodeArgs{
				ZipFile: pulumi.String(`exports.handler = function(event){
    console.log(JSON.stringify(event, null, 2))
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello again from Lambda!')
    }
    return response
}
`),
			},
			Runtime: pulumi.String("nodejs18.x"),
			TracingConfig: &lambda.FunctionTracingConfigArgs{
				Mode: lambda.FunctionTracingConfigModeActive,
			},
		})
		if err != nil {
			return err
		}
		version, err := lambda.NewVersion(ctx, "version", &lambda.VersionArgs{
			FunctionName: function.ID(),
			Description:  pulumi.String("v1"),
		})
		if err != nil {
			return err
		}
		newVersion, err := lambda.NewVersion(ctx, "newVersion", &lambda.VersionArgs{
			FunctionName: function.ID(),
			Description:  pulumi.String("v2"),
		})
		if err != nil {
			return err
		}
		_, err = lambda.NewAlias(ctx, "alias", &lambda.AliasArgs{
			FunctionName:    function.ID(),
			FunctionVersion: newVersion.Version,
			Name:            pulumi.String("BLUE"),
			RoutingConfig: &lambda.AliasRoutingConfigurationArgs{
				AdditionalVersionWeights: lambda.AliasVersionWeightArray{
					&lambda.AliasVersionWeightArgs{
						FunctionVersion: version.Version,
						FunctionWeight:  pulumi.Float64(0.5),
					},
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as aws_native from "@pulumi/aws-native";
const _function = new aws_native.lambda.Function("function", {
    handler: "index.handler",
    role: "arn:aws:iam::123456789012:role/lambda-role",
    code: {
        zipFile: `exports.handler = function(event){
    console.log(JSON.stringify(event, null, 2))
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello again from Lambda!')
    }
    return response
}
`,
    },
    runtime: "nodejs18.x",
    tracingConfig: {
        mode: aws_native.lambda.FunctionTracingConfigMode.Active,
    },
});
const version = new aws_native.lambda.Version("version", {
    functionName: _function.id,
    description: "v1",
});
const newVersion = new aws_native.lambda.Version("newVersion", {
    functionName: _function.id,
    description: "v2",
});
const alias = new aws_native.lambda.Alias("alias", {
    functionName: _function.id,
    functionVersion: newVersion.version,
    name: "BLUE",
    routingConfig: {
        additionalVersionWeights: [{
            functionVersion: version.version,
            functionWeight: 0.5,
        }],
    },
});
import pulumi
import pulumi_aws_native as aws_native
function = aws_native.lambda_.Function("function",
    handler="index.handler",
    role="arn:aws:iam::123456789012:role/lambda-role",
    code={
        "zip_file": """exports.handler = function(event){
    console.log(JSON.stringify(event, null, 2))
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello again from Lambda!')
    }
    return response
}
""",
    },
    runtime="nodejs18.x",
    tracing_config={
        "mode": aws_native.lambda_.FunctionTracingConfigMode.ACTIVE,
    })
version = aws_native.lambda_.Version("version",
    function_name=function.id,
    description="v1")
new_version = aws_native.lambda_.Version("newVersion",
    function_name=function.id,
    description="v2")
alias = aws_native.lambda_.Alias("alias",
    function_name=function.id,
    function_version=new_version.version,
    name="BLUE",
    routing_config={
        "additional_version_weights": [{
            "function_version": version.version,
            "function_weight": 0.5,
        }],
    })
Coming soon!
Example
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AwsNative = Pulumi.AwsNative;
return await Deployment.RunAsync(() => 
{
    var function = new AwsNative.Lambda.Function("function", new()
    {
        Handler = "index.handler",
        Role = "arn:aws:iam::123456789012:role/lambda-role",
        Code = new AwsNative.Lambda.Inputs.FunctionCodeArgs
        {
            ZipFile = @"exports.handler = async (event) => {
    console.log(JSON.stringify(event, null, 2));
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!'),
    };
    return response;
};
",
        },
        Runtime = "nodejs18.x",
        TracingConfig = new AwsNative.Lambda.Inputs.FunctionTracingConfigArgs
        {
            Mode = AwsNative.Lambda.FunctionTracingConfigMode.Active,
        },
    });
    var version = new AwsNative.Lambda.Version("version", new()
    {
        FunctionName = function.Id,
    });
    var asyncconfig = new AwsNative.Lambda.EventInvokeConfig("asyncconfig", new()
    {
        DestinationConfig = new AwsNative.Lambda.Inputs.EventInvokeConfigDestinationConfigArgs
        {
            OnFailure = new AwsNative.Lambda.Inputs.EventInvokeConfigOnFailureArgs
            {
                Destination = "arn:aws:sqs:us-east-2:123456789012:dlq",
            },
            OnSuccess = new AwsNative.Lambda.Inputs.EventInvokeConfigOnSuccessArgs
            {
                Destination = "arn:aws:sqs:us-east-2:123456789012:dlq",
            },
        },
        FunctionName = function.Id,
        MaximumEventAgeInSeconds = 300,
        MaximumRetryAttempts = 1,
        Qualifier = version.Version,
    });
});
package main
import (
	"github.com/pulumi/pulumi-aws-native/sdk/go/aws/lambda"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		function, err := lambda.NewFunction(ctx, "function", &lambda.FunctionArgs{
			Handler: pulumi.String("index.handler"),
			Role:    pulumi.String("arn:aws:iam::123456789012:role/lambda-role"),
			Code: &lambda.FunctionCodeArgs{
				ZipFile: pulumi.String(`exports.handler = async (event) => {
    console.log(JSON.stringify(event, null, 2));
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!'),
    };
    return response;
};
`),
			},
			Runtime: pulumi.String("nodejs18.x"),
			TracingConfig: &lambda.FunctionTracingConfigArgs{
				Mode: lambda.FunctionTracingConfigModeActive,
			},
		})
		if err != nil {
			return err
		}
		version, err := lambda.NewVersion(ctx, "version", &lambda.VersionArgs{
			FunctionName: function.ID(),
		})
		if err != nil {
			return err
		}
		_, err = lambda.NewEventInvokeConfig(ctx, "asyncconfig", &lambda.EventInvokeConfigArgs{
			DestinationConfig: &lambda.EventInvokeConfigDestinationConfigArgs{
				OnFailure: &lambda.EventInvokeConfigOnFailureArgs{
					Destination: pulumi.String("arn:aws:sqs:us-east-2:123456789012:dlq"),
				},
				OnSuccess: &lambda.EventInvokeConfigOnSuccessArgs{
					Destination: pulumi.String("arn:aws:sqs:us-east-2:123456789012:dlq"),
				},
			},
			FunctionName:             function.ID(),
			MaximumEventAgeInSeconds: pulumi.Int(300),
			MaximumRetryAttempts:     pulumi.Int(1),
			Qualifier:                version.Version,
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as aws_native from "@pulumi/aws-native";
const _function = new aws_native.lambda.Function("function", {
    handler: "index.handler",
    role: "arn:aws:iam::123456789012:role/lambda-role",
    code: {
        zipFile: `exports.handler = async (event) => {
    console.log(JSON.stringify(event, null, 2));
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!'),
    };
    return response;
};
`,
    },
    runtime: "nodejs18.x",
    tracingConfig: {
        mode: aws_native.lambda.FunctionTracingConfigMode.Active,
    },
});
const version = new aws_native.lambda.Version("version", {functionName: _function.id});
const asyncconfig = new aws_native.lambda.EventInvokeConfig("asyncconfig", {
    destinationConfig: {
        onFailure: {
            destination: "arn:aws:sqs:us-east-2:123456789012:dlq",
        },
        onSuccess: {
            destination: "arn:aws:sqs:us-east-2:123456789012:dlq",
        },
    },
    functionName: _function.id,
    maximumEventAgeInSeconds: 300,
    maximumRetryAttempts: 1,
    qualifier: version.version,
});
import pulumi
import pulumi_aws_native as aws_native
function = aws_native.lambda_.Function("function",
    handler="index.handler",
    role="arn:aws:iam::123456789012:role/lambda-role",
    code={
        "zip_file": """exports.handler = async (event) => {
    console.log(JSON.stringify(event, null, 2));
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!'),
    };
    return response;
};
""",
    },
    runtime="nodejs18.x",
    tracing_config={
        "mode": aws_native.lambda_.FunctionTracingConfigMode.ACTIVE,
    })
version = aws_native.lambda_.Version("version", function_name=function.id)
asyncconfig = aws_native.lambda_.EventInvokeConfig("asyncconfig",
    destination_config={
        "on_failure": {
            "destination": "arn:aws:sqs:us-east-2:123456789012:dlq",
        },
        "on_success": {
            "destination": "arn:aws:sqs:us-east-2:123456789012:dlq",
        },
    },
    function_name=function.id,
    maximum_event_age_in_seconds=300,
    maximum_retry_attempts=1,
    qualifier=version.version)
Coming soon!
Example
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AwsNative = Pulumi.AwsNative;
return await Deployment.RunAsync(() => 
{
    var primer = new AwsNative.Lambda.Function("primer", new()
    {
        Runtime = "nodejs18.x",
        Role = "arn:aws:iam::123456789012:role/lambda-role",
        Handler = "index.handler",
        Code = new AwsNative.Lambda.Inputs.FunctionCodeArgs
        {
            ZipFile = @"const { S3Client, ListBucketsCommand } = require(""@aws-sdk/client-s3"");
const s3 = new S3Client({ region: ""us-east-1"" }); // replace ""us-east-1"" with your AWS region
exports.handler = async function(event) {
  const command = new ListBucketsCommand({});
  const response = await s3.send(command);
  return response.Buckets;
};
",
        },
        Description = "List Amazon S3 buckets in us-east-1.",
        TracingConfig = new AwsNative.Lambda.Inputs.FunctionTracingConfigArgs
        {
            Mode = AwsNative.Lambda.FunctionTracingConfigMode.Active,
        },
    });
});
package main
import (
	"github.com/pulumi/pulumi-aws-native/sdk/go/aws/lambda"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := lambda.NewFunction(ctx, "primer", &lambda.FunctionArgs{
			Runtime: pulumi.String("nodejs18.x"),
			Role:    pulumi.String("arn:aws:iam::123456789012:role/lambda-role"),
			Handler: pulumi.String("index.handler"),
			Code: &lambda.FunctionCodeArgs{
				ZipFile: pulumi.String(`const { S3Client, ListBucketsCommand } = require("@aws-sdk/client-s3");
const s3 = new S3Client({ region: "us-east-1" }); // replace "us-east-1" with your AWS region
exports.handler = async function(event) {
  const command = new ListBucketsCommand({});
  const response = await s3.send(command);
  return response.Buckets;
};
`),
			},
			Description: pulumi.String("List Amazon S3 buckets in us-east-1."),
			TracingConfig: &lambda.FunctionTracingConfigArgs{
				Mode: lambda.FunctionTracingConfigModeActive,
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as aws_native from "@pulumi/aws-native";
const primer = new aws_native.lambda.Function("primer", {
    runtime: "nodejs18.x",
    role: "arn:aws:iam::123456789012:role/lambda-role",
    handler: "index.handler",
    code: {
        zipFile: `const { S3Client, ListBucketsCommand } = require("@aws-sdk/client-s3");
const s3 = new S3Client({ region: "us-east-1" }); // replace "us-east-1" with your AWS region
exports.handler = async function(event) {
  const command = new ListBucketsCommand({});
  const response = await s3.send(command);
  return response.Buckets;
};
`,
    },
    description: "List Amazon S3 buckets in us-east-1.",
    tracingConfig: {
        mode: aws_native.lambda.FunctionTracingConfigMode.Active,
    },
});
import pulumi
import pulumi_aws_native as aws_native
primer = aws_native.lambda_.Function("primer",
    runtime="nodejs18.x",
    role="arn:aws:iam::123456789012:role/lambda-role",
    handler="index.handler",
    code={
        "zip_file": """const { S3Client, ListBucketsCommand } = require("@aws-sdk/client-s3");
const s3 = new S3Client({ region: "us-east-1" }); // replace "us-east-1" with your AWS region
exports.handler = async function(event) {
  const command = new ListBucketsCommand({});
  const response = await s3.send(command);
  return response.Buckets;
};
""",
    },
    description="List Amazon S3 buckets in us-east-1.",
    tracing_config={
        "mode": aws_native.lambda_.FunctionTracingConfigMode.ACTIVE,
    })
Coming soon!
Example
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AwsNative = Pulumi.AwsNative;
return await Deployment.RunAsync(() => 
{
    var function = new AwsNative.Lambda.Function("function", new()
    {
        Handler = "index.handler",
        Role = "arn:aws:iam::123456789012:role/lambda-role",
        Code = new AwsNative.Lambda.Inputs.FunctionCodeArgs
        {
            S3Bucket = "my-bucket",
            S3Key = "function.zip",
        },
        Runtime = "nodejs18.x",
        Timeout = 5,
        TracingConfig = new AwsNative.Lambda.Inputs.FunctionTracingConfigArgs
        {
            Mode = AwsNative.Lambda.FunctionTracingConfigMode.Active,
        },
        VpcConfig = new AwsNative.Lambda.Inputs.FunctionVpcConfigArgs
        {
            SecurityGroupIds = new[]
            {
                "sg-085912345678492fb",
            },
            SubnetIds = new[]
            {
                "subnet-071f712345678e7c8",
                "subnet-07fd123456788a036",
            },
        },
    });
});
package main
import (
	"github.com/pulumi/pulumi-aws-native/sdk/go/aws/lambda"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := lambda.NewFunction(ctx, "function", &lambda.FunctionArgs{
			Handler: pulumi.String("index.handler"),
			Role:    pulumi.String("arn:aws:iam::123456789012:role/lambda-role"),
			Code: &lambda.FunctionCodeArgs{
				S3Bucket: pulumi.String("my-bucket"),
				S3Key:    pulumi.String("function.zip"),
			},
			Runtime: pulumi.String("nodejs18.x"),
			Timeout: pulumi.Int(5),
			TracingConfig: &lambda.FunctionTracingConfigArgs{
				Mode: lambda.FunctionTracingConfigModeActive,
			},
			VpcConfig: &lambda.FunctionVpcConfigArgs{
				SecurityGroupIds: pulumi.StringArray{
					pulumi.String("sg-085912345678492fb"),
				},
				SubnetIds: pulumi.StringArray{
					pulumi.String("subnet-071f712345678e7c8"),
					pulumi.String("subnet-07fd123456788a036"),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as aws_native from "@pulumi/aws-native";
const _function = new aws_native.lambda.Function("function", {
    handler: "index.handler",
    role: "arn:aws:iam::123456789012:role/lambda-role",
    code: {
        s3Bucket: "my-bucket",
        s3Key: "function.zip",
    },
    runtime: "nodejs18.x",
    timeout: 5,
    tracingConfig: {
        mode: aws_native.lambda.FunctionTracingConfigMode.Active,
    },
    vpcConfig: {
        securityGroupIds: ["sg-085912345678492fb"],
        subnetIds: [
            "subnet-071f712345678e7c8",
            "subnet-07fd123456788a036",
        ],
    },
});
import pulumi
import pulumi_aws_native as aws_native
function = aws_native.lambda_.Function("function",
    handler="index.handler",
    role="arn:aws:iam::123456789012:role/lambda-role",
    code={
        "s3_bucket": "my-bucket",
        "s3_key": "function.zip",
    },
    runtime="nodejs18.x",
    timeout=5,
    tracing_config={
        "mode": aws_native.lambda_.FunctionTracingConfigMode.ACTIVE,
    },
    vpc_config={
        "security_group_ids": ["sg-085912345678492fb"],
        "subnet_ids": [
            "subnet-071f712345678e7c8",
            "subnet-07fd123456788a036",
        ],
    })
Coming soon!
Example
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AwsNative = Pulumi.AwsNative;
return await Deployment.RunAsync(() => 
{
    var function = new AwsNative.Lambda.Function("function", new()
    {
        Handler = "index.handler",
        Role = "arn:aws:iam::123456789012:role/lambda-role",
        Code = new AwsNative.Lambda.Inputs.FunctionCodeArgs
        {
            ZipFile = @"exports.handler = async (event) => {
    console.log(JSON.stringify(event, null, 2));
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!'),
    };
    return response;
};
",
        },
        Runtime = "nodejs18.x",
        TracingConfig = new AwsNative.Lambda.Inputs.FunctionTracingConfigArgs
        {
            Mode = AwsNative.Lambda.FunctionTracingConfigMode.Active,
        },
    });
    var version = new AwsNative.Lambda.Version("version", new()
    {
        FunctionName = function.Id,
        Description = "v1",
        ProvisionedConcurrencyConfig = new AwsNative.Lambda.Inputs.VersionProvisionedConcurrencyConfigurationArgs
        {
            ProvisionedConcurrentExecutions = 20,
        },
    });
});
package main
import (
	"github.com/pulumi/pulumi-aws-native/sdk/go/aws/lambda"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		function, err := lambda.NewFunction(ctx, "function", &lambda.FunctionArgs{
			Handler: pulumi.String("index.handler"),
			Role:    pulumi.String("arn:aws:iam::123456789012:role/lambda-role"),
			Code: &lambda.FunctionCodeArgs{
				ZipFile: pulumi.String(`exports.handler = async (event) => {
    console.log(JSON.stringify(event, null, 2));
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!'),
    };
    return response;
};
`),
			},
			Runtime: pulumi.String("nodejs18.x"),
			TracingConfig: &lambda.FunctionTracingConfigArgs{
				Mode: lambda.FunctionTracingConfigModeActive,
			},
		})
		if err != nil {
			return err
		}
		_, err = lambda.NewVersion(ctx, "version", &lambda.VersionArgs{
			FunctionName: function.ID(),
			Description:  pulumi.String("v1"),
			ProvisionedConcurrencyConfig: &lambda.VersionProvisionedConcurrencyConfigurationArgs{
				ProvisionedConcurrentExecutions: pulumi.Int(20),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as aws_native from "@pulumi/aws-native";
const _function = new aws_native.lambda.Function("function", {
    handler: "index.handler",
    role: "arn:aws:iam::123456789012:role/lambda-role",
    code: {
        zipFile: `exports.handler = async (event) => {
    console.log(JSON.stringify(event, null, 2));
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!'),
    };
    return response;
};
`,
    },
    runtime: "nodejs18.x",
    tracingConfig: {
        mode: aws_native.lambda.FunctionTracingConfigMode.Active,
    },
});
const version = new aws_native.lambda.Version("version", {
    functionName: _function.id,
    description: "v1",
    provisionedConcurrencyConfig: {
        provisionedConcurrentExecutions: 20,
    },
});
import pulumi
import pulumi_aws_native as aws_native
function = aws_native.lambda_.Function("function",
    handler="index.handler",
    role="arn:aws:iam::123456789012:role/lambda-role",
    code={
        "zip_file": """exports.handler = async (event) => {
    console.log(JSON.stringify(event, null, 2));
    const response = {
        statusCode: 200,
        body: JSON.stringify('Hello from Lambda!'),
    };
    return response;
};
""",
    },
    runtime="nodejs18.x",
    tracing_config={
        "mode": aws_native.lambda_.FunctionTracingConfigMode.ACTIVE,
    })
version = aws_native.lambda_.Version("version",
    function_name=function.id,
    description="v1",
    provisioned_concurrency_config={
        "provisioned_concurrent_executions": 20,
    })
Coming soon!
Create Function Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Function(name: string, args: FunctionArgs, opts?: CustomResourceOptions);@overload
def Function(resource_name: str,
             args: FunctionArgs,
             opts: Optional[ResourceOptions] = None)
@overload
def Function(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             role: Optional[str] = None,
             code: Optional[_lambda_.FunctionCodeArgs] = None,
             ephemeral_storage: Optional[_lambda_.FunctionEphemeralStorageArgs] = None,
             timeout: Optional[int] = None,
             description: Optional[str] = None,
             environment: Optional[_lambda_.FunctionEnvironmentArgs] = None,
             architectures: Optional[Sequence[lambda_.FunctionArchitecturesItem]] = None,
             file_system_configs: Optional[Sequence[_lambda_.FunctionFileSystemConfigArgs]] = None,
             function_name: Optional[str] = None,
             handler: Optional[str] = None,
             image_config: Optional[_lambda_.FunctionImageConfigArgs] = None,
             kms_key_arn: Optional[str] = None,
             vpc_config: Optional[_lambda_.FunctionVpcConfigArgs] = None,
             dead_letter_config: Optional[_lambda_.FunctionDeadLetterConfigArgs] = None,
             recursive_loop: Optional[lambda_.FunctionRecursiveLoop] = None,
             package_type: Optional[lambda_.FunctionPackageType] = None,
             memory_size: Optional[int] = None,
             reserved_concurrent_executions: Optional[int] = None,
             code_signing_config_arn: Optional[str] = None,
             runtime: Optional[str] = None,
             runtime_management_config: Optional[_lambda_.FunctionRuntimeManagementConfigArgs] = None,
             snap_start: Optional[_lambda_.FunctionSnapStartArgs] = None,
             tags: Optional[Sequence[_root_inputs.TagArgs]] = None,
             logging_config: Optional[_lambda_.FunctionLoggingConfigArgs] = None,
             tracing_config: Optional[_lambda_.FunctionTracingConfigArgs] = None,
             layers: Optional[Sequence[str]] = None)func NewFunction(ctx *Context, name string, args FunctionArgs, opts ...ResourceOption) (*Function, error)public Function(string name, FunctionArgs args, CustomResourceOptions? opts = null)
public Function(String name, FunctionArgs args)
public Function(String name, FunctionArgs args, CustomResourceOptions options)
type: aws-native:lambda:Function
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args FunctionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args FunctionArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args FunctionArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args FunctionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args FunctionArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Function Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Function resource accepts the following input properties:
- Code
Pulumi.Aws Native. Lambda. Inputs. Function Code 
- The code for the function. You can define your function code in multiple ways:- For .zip deployment packages, you can specify the S3 location of the .zip file in the S3Bucket,S3Key, andS3ObjectVersionproperties.
- For .zip deployment packages, you can alternatively define the function code inline in the ZipFileproperty. This method works only for Node.js and Python functions.
- For container images, specify the URI of your container image in the ECR registry in the ImageUriproperty.
 
- For .zip deployment packages, you can specify the S3 location of the .zip file in the 
- Role string
- The Amazon Resource Name (ARN) of the function's execution role.
- Architectures
List<Pulumi.Aws Native. Lambda. Function Architectures Item> 
- The instruction set architecture that the function supports. Enter a string array with one of the valid values (arm64 or x86_64). The default value is x86_64.
- CodeSigning stringConfig Arn 
- To enable code signing for this function, specify the ARN of a code-signing configuration. A code-signing configuration includes a set of signing profiles, which define the trusted publishers for this function.
- DeadLetter Pulumi.Config Aws Native. Lambda. Inputs. Function Dead Letter Config 
- A dead-letter queue configuration that specifies the queue or topic where Lambda sends asynchronous events when they fail processing. For more information, see Dead-letter queues.
- Description string
- A description of the function.
- Environment
Pulumi.Aws Native. Lambda. Inputs. Function Environment 
- Environment variables that are accessible from function code during execution.
- EphemeralStorage Pulumi.Aws Native. Lambda. Inputs. Function Ephemeral Storage 
- The size of the function's /tmpdirectory in MB. The default value is 512, but it can be any whole number between 512 and 10,240 MB.
- FileSystem List<Pulumi.Configs Aws Native. Lambda. Inputs. Function File System Config> 
- Connection settings for an Amazon EFS file system. To connect a function to a file system, a mount target must be available in every Availability Zone that your function connects to. If your template contains an AWS::EFS::MountTarget resource, you must also specify a DependsOnattribute to ensure that the mount target is created or updated before the function. For more information about using theDependsOnattribute, see DependsOn Attribute.
- FunctionName string
- The name of the Lambda function, up to 64 characters in length. If you don't specify a name, CFN generates one. If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
- Handler string
- The name of the method within your code that Lambda calls to run your function. Handler is required if the deployment package is a .zip file archive. The format includes the file name. It can also include namespaces and other qualifiers, depending on the runtime. For more information, see Lambda programming model.
- ImageConfig Pulumi.Aws Native. Lambda. Inputs. Function Image Config 
- Configuration values that override the container image Dockerfile settings. For more information, see Container image settings.
- KmsKey stringArn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt the following resources: - The function's environment variables.
- The function's Lambda SnapStart snapshots.
- When used with SourceKMSKeyArn, the unzipped version of the .zip deployment package that's used for function invocations. For more information, see Specifying a customer managed key for Lambda.
- The optimized version of the container image that's used for function invocations. Note that this is not the same key that's used to protect your container image in the Amazon Elastic Container Registry (Amazon ECR). For more information, see Function lifecycle.
 - If you don't provide a customer managed key, Lambda uses an owned key or an . 
- Layers List<string>
- A list of function layers to add to the function's execution environment. Specify each layer by its ARN, including the version.
- LoggingConfig Pulumi.Aws Native. Lambda. Inputs. Function Logging Config 
- The function's Amazon CloudWatch Logs configuration settings.
- MemorySize int
- The amount of memory available to the function at runtime. Increasing the function memory also increases its CPU allocation. The default value is 128 MB. The value can be any multiple of 1 MB. Note that new AWS accounts have reduced concurrency and memory quotas. AWS raises these quotas automatically based on your usage. You can also request a quota increase.
- PackageType Pulumi.Aws Native. Lambda. Function Package Type 
- The type of deployment package. Set to Imagefor container image and setZipfor .zip file archive.
- RecursiveLoop Pulumi.Aws Native. Lambda. Function Recursive Loop 
- The status of your function's recursive loop detection configuration.
When this value is set to Allowand Lambda detects your function being invoked as part of a recursive loop, it doesn't take any action. When this value is set toTerminateand Lambda detects your function being invoked as part of a recursive loop, it stops your function being invoked and notifies you.
- ReservedConcurrent intExecutions 
- The number of simultaneous executions to reserve for the function.
- Runtime string
- The identifier of the function's runtime. Runtime is required if the deployment package is a .zip file archive. Specifying a runtime results in an error if you're deploying a function using a container image. The following list includes deprecated runtimes. Lambda blocks creating new functions and updating existing functions shortly after each runtime is deprecated. For more information, see Runtime use after deprecation. For a list of all currently supported runtimes, see Supported runtimes.
- RuntimeManagement Pulumi.Config Aws Native. Lambda. Inputs. Function Runtime Management Config 
- Sets the runtime management configuration for a function's version. For more information, see Runtime updates.
- SnapStart Pulumi.Aws Native. Lambda. Inputs. Function Snap Start 
- The function's SnapStart setting.
- 
List<Pulumi.Aws Native. Inputs. Tag> 
- A list of tags to apply to the function.
You must have the lambda:TagResource,lambda:UntagResource, andlambda:ListTagspermissions for your principal to manage the CFN stack. If you don't have these permissions, there might be unexpected behavior with stack-level tags propagating to the resource during resource creation and update.
- Timeout int
- The amount of time (in seconds) that Lambda allows a function to run before stopping it. The default is 3 seconds. The maximum allowed value is 900 seconds. For more information, see Lambda execution environment.
- TracingConfig Pulumi.Aws Native. Lambda. Inputs. Function Tracing Config 
- Set ModetoActiveto sample and trace a subset of incoming requests with X-Ray.
- VpcConfig Pulumi.Aws Native. Lambda. Inputs. Function Vpc Config 
- For network connectivity to AWS resources in a VPC, specify a list of security groups and subnets in the VPC. When you connect a function to a VPC, it can access resources and the internet only through that VPC. For more information, see Configuring a Lambda function to access resources in a VPC.
- Code
FunctionCode Args 
- The code for the function. You can define your function code in multiple ways:- For .zip deployment packages, you can specify the S3 location of the .zip file in the S3Bucket,S3Key, andS3ObjectVersionproperties.
- For .zip deployment packages, you can alternatively define the function code inline in the ZipFileproperty. This method works only for Node.js and Python functions.
- For container images, specify the URI of your container image in the ECR registry in the ImageUriproperty.
 
- For .zip deployment packages, you can specify the S3 location of the .zip file in the 
- Role string
- The Amazon Resource Name (ARN) of the function's execution role.
- Architectures
[]FunctionArchitectures Item 
- The instruction set architecture that the function supports. Enter a string array with one of the valid values (arm64 or x86_64). The default value is x86_64.
- CodeSigning stringConfig Arn 
- To enable code signing for this function, specify the ARN of a code-signing configuration. A code-signing configuration includes a set of signing profiles, which define the trusted publishers for this function.
- DeadLetter FunctionConfig Dead Letter Config Args 
- A dead-letter queue configuration that specifies the queue or topic where Lambda sends asynchronous events when they fail processing. For more information, see Dead-letter queues.
- Description string
- A description of the function.
- Environment
FunctionEnvironment Args 
- Environment variables that are accessible from function code during execution.
- EphemeralStorage FunctionEphemeral Storage Args 
- The size of the function's /tmpdirectory in MB. The default value is 512, but it can be any whole number between 512 and 10,240 MB.
- FileSystem []FunctionConfigs File System Config Args 
- Connection settings for an Amazon EFS file system. To connect a function to a file system, a mount target must be available in every Availability Zone that your function connects to. If your template contains an AWS::EFS::MountTarget resource, you must also specify a DependsOnattribute to ensure that the mount target is created or updated before the function. For more information about using theDependsOnattribute, see DependsOn Attribute.
- FunctionName string
- The name of the Lambda function, up to 64 characters in length. If you don't specify a name, CFN generates one. If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
- Handler string
- The name of the method within your code that Lambda calls to run your function. Handler is required if the deployment package is a .zip file archive. The format includes the file name. It can also include namespaces and other qualifiers, depending on the runtime. For more information, see Lambda programming model.
- ImageConfig FunctionImage Config Args 
- Configuration values that override the container image Dockerfile settings. For more information, see Container image settings.
- KmsKey stringArn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt the following resources: - The function's environment variables.
- The function's Lambda SnapStart snapshots.
- When used with SourceKMSKeyArn, the unzipped version of the .zip deployment package that's used for function invocations. For more information, see Specifying a customer managed key for Lambda.
- The optimized version of the container image that's used for function invocations. Note that this is not the same key that's used to protect your container image in the Amazon Elastic Container Registry (Amazon ECR). For more information, see Function lifecycle.
 - If you don't provide a customer managed key, Lambda uses an owned key or an . 
- Layers []string
- A list of function layers to add to the function's execution environment. Specify each layer by its ARN, including the version.
- LoggingConfig FunctionLogging Config Args 
- The function's Amazon CloudWatch Logs configuration settings.
- MemorySize int
- The amount of memory available to the function at runtime. Increasing the function memory also increases its CPU allocation. The default value is 128 MB. The value can be any multiple of 1 MB. Note that new AWS accounts have reduced concurrency and memory quotas. AWS raises these quotas automatically based on your usage. You can also request a quota increase.
- PackageType FunctionPackage Type 
- The type of deployment package. Set to Imagefor container image and setZipfor .zip file archive.
- RecursiveLoop FunctionRecursive Loop 
- The status of your function's recursive loop detection configuration.
When this value is set to Allowand Lambda detects your function being invoked as part of a recursive loop, it doesn't take any action. When this value is set toTerminateand Lambda detects your function being invoked as part of a recursive loop, it stops your function being invoked and notifies you.
- ReservedConcurrent intExecutions 
- The number of simultaneous executions to reserve for the function.
- Runtime string
- The identifier of the function's runtime. Runtime is required if the deployment package is a .zip file archive. Specifying a runtime results in an error if you're deploying a function using a container image. The following list includes deprecated runtimes. Lambda blocks creating new functions and updating existing functions shortly after each runtime is deprecated. For more information, see Runtime use after deprecation. For a list of all currently supported runtimes, see Supported runtimes.
- RuntimeManagement FunctionConfig Runtime Management Config Args 
- Sets the runtime management configuration for a function's version. For more information, see Runtime updates.
- SnapStart FunctionSnap Start Args 
- The function's SnapStart setting.
- 
TagArgs 
- A list of tags to apply to the function.
You must have the lambda:TagResource,lambda:UntagResource, andlambda:ListTagspermissions for your principal to manage the CFN stack. If you don't have these permissions, there might be unexpected behavior with stack-level tags propagating to the resource during resource creation and update.
- Timeout int
- The amount of time (in seconds) that Lambda allows a function to run before stopping it. The default is 3 seconds. The maximum allowed value is 900 seconds. For more information, see Lambda execution environment.
- TracingConfig FunctionTracing Config Args 
- Set ModetoActiveto sample and trace a subset of incoming requests with X-Ray.
- VpcConfig FunctionVpc Config Args 
- For network connectivity to AWS resources in a VPC, specify a list of security groups and subnets in the VPC. When you connect a function to a VPC, it can access resources and the internet only through that VPC. For more information, see Configuring a Lambda function to access resources in a VPC.
- code
FunctionCode 
- The code for the function. You can define your function code in multiple ways:- For .zip deployment packages, you can specify the S3 location of the .zip file in the S3Bucket,S3Key, andS3ObjectVersionproperties.
- For .zip deployment packages, you can alternatively define the function code inline in the ZipFileproperty. This method works only for Node.js and Python functions.
- For container images, specify the URI of your container image in the ECR registry in the ImageUriproperty.
 
- For .zip deployment packages, you can specify the S3 location of the .zip file in the 
- role String
- The Amazon Resource Name (ARN) of the function's execution role.
- architectures
List<FunctionArchitectures Item> 
- The instruction set architecture that the function supports. Enter a string array with one of the valid values (arm64 or x86_64). The default value is x86_64.
- codeSigning StringConfig Arn 
- To enable code signing for this function, specify the ARN of a code-signing configuration. A code-signing configuration includes a set of signing profiles, which define the trusted publishers for this function.
- deadLetter FunctionConfig Dead Letter Config 
- A dead-letter queue configuration that specifies the queue or topic where Lambda sends asynchronous events when they fail processing. For more information, see Dead-letter queues.
- description String
- A description of the function.
- environment
FunctionEnvironment 
- Environment variables that are accessible from function code during execution.
- ephemeralStorage FunctionEphemeral Storage 
- The size of the function's /tmpdirectory in MB. The default value is 512, but it can be any whole number between 512 and 10,240 MB.
- fileSystem List<FunctionConfigs File System Config> 
- Connection settings for an Amazon EFS file system. To connect a function to a file system, a mount target must be available in every Availability Zone that your function connects to. If your template contains an AWS::EFS::MountTarget resource, you must also specify a DependsOnattribute to ensure that the mount target is created or updated before the function. For more information about using theDependsOnattribute, see DependsOn Attribute.
- functionName String
- The name of the Lambda function, up to 64 characters in length. If you don't specify a name, CFN generates one. If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
- handler String
- The name of the method within your code that Lambda calls to run your function. Handler is required if the deployment package is a .zip file archive. The format includes the file name. It can also include namespaces and other qualifiers, depending on the runtime. For more information, see Lambda programming model.
- imageConfig FunctionImage Config 
- Configuration values that override the container image Dockerfile settings. For more information, see Container image settings.
- kmsKey StringArn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt the following resources: - The function's environment variables.
- The function's Lambda SnapStart snapshots.
- When used with SourceKMSKeyArn, the unzipped version of the .zip deployment package that's used for function invocations. For more information, see Specifying a customer managed key for Lambda.
- The optimized version of the container image that's used for function invocations. Note that this is not the same key that's used to protect your container image in the Amazon Elastic Container Registry (Amazon ECR). For more information, see Function lifecycle.
 - If you don't provide a customer managed key, Lambda uses an owned key or an . 
- layers List<String>
- A list of function layers to add to the function's execution environment. Specify each layer by its ARN, including the version.
- loggingConfig FunctionLogging Config 
- The function's Amazon CloudWatch Logs configuration settings.
- memorySize Integer
- The amount of memory available to the function at runtime. Increasing the function memory also increases its CPU allocation. The default value is 128 MB. The value can be any multiple of 1 MB. Note that new AWS accounts have reduced concurrency and memory quotas. AWS raises these quotas automatically based on your usage. You can also request a quota increase.
- packageType FunctionPackage Type 
- The type of deployment package. Set to Imagefor container image and setZipfor .zip file archive.
- recursiveLoop FunctionRecursive Loop 
- The status of your function's recursive loop detection configuration.
When this value is set to Allowand Lambda detects your function being invoked as part of a recursive loop, it doesn't take any action. When this value is set toTerminateand Lambda detects your function being invoked as part of a recursive loop, it stops your function being invoked and notifies you.
- reservedConcurrent IntegerExecutions 
- The number of simultaneous executions to reserve for the function.
- runtime String
- The identifier of the function's runtime. Runtime is required if the deployment package is a .zip file archive. Specifying a runtime results in an error if you're deploying a function using a container image. The following list includes deprecated runtimes. Lambda blocks creating new functions and updating existing functions shortly after each runtime is deprecated. For more information, see Runtime use after deprecation. For a list of all currently supported runtimes, see Supported runtimes.
- runtimeManagement FunctionConfig Runtime Management Config 
- Sets the runtime management configuration for a function's version. For more information, see Runtime updates.
- snapStart FunctionSnap Start 
- The function's SnapStart setting.
- List<Tag>
- A list of tags to apply to the function.
You must have the lambda:TagResource,lambda:UntagResource, andlambda:ListTagspermissions for your principal to manage the CFN stack. If you don't have these permissions, there might be unexpected behavior with stack-level tags propagating to the resource during resource creation and update.
- timeout Integer
- The amount of time (in seconds) that Lambda allows a function to run before stopping it. The default is 3 seconds. The maximum allowed value is 900 seconds. For more information, see Lambda execution environment.
- tracingConfig FunctionTracing Config 
- Set ModetoActiveto sample and trace a subset of incoming requests with X-Ray.
- vpcConfig FunctionVpc Config 
- For network connectivity to AWS resources in a VPC, specify a list of security groups and subnets in the VPC. When you connect a function to a VPC, it can access resources and the internet only through that VPC. For more information, see Configuring a Lambda function to access resources in a VPC.
- code
FunctionCode 
- The code for the function. You can define your function code in multiple ways:- For .zip deployment packages, you can specify the S3 location of the .zip file in the S3Bucket,S3Key, andS3ObjectVersionproperties.
- For .zip deployment packages, you can alternatively define the function code inline in the ZipFileproperty. This method works only for Node.js and Python functions.
- For container images, specify the URI of your container image in the ECR registry in the ImageUriproperty.
 
- For .zip deployment packages, you can specify the S3 location of the .zip file in the 
- role string
- The Amazon Resource Name (ARN) of the function's execution role.
- architectures
FunctionArchitectures Item[] 
- The instruction set architecture that the function supports. Enter a string array with one of the valid values (arm64 or x86_64). The default value is x86_64.
- codeSigning stringConfig Arn 
- To enable code signing for this function, specify the ARN of a code-signing configuration. A code-signing configuration includes a set of signing profiles, which define the trusted publishers for this function.
- deadLetter FunctionConfig Dead Letter Config 
- A dead-letter queue configuration that specifies the queue or topic where Lambda sends asynchronous events when they fail processing. For more information, see Dead-letter queues.
- description string
- A description of the function.
- environment
FunctionEnvironment 
- Environment variables that are accessible from function code during execution.
- ephemeralStorage FunctionEphemeral Storage 
- The size of the function's /tmpdirectory in MB. The default value is 512, but it can be any whole number between 512 and 10,240 MB.
- fileSystem FunctionConfigs File System Config[] 
- Connection settings for an Amazon EFS file system. To connect a function to a file system, a mount target must be available in every Availability Zone that your function connects to. If your template contains an AWS::EFS::MountTarget resource, you must also specify a DependsOnattribute to ensure that the mount target is created or updated before the function. For more information about using theDependsOnattribute, see DependsOn Attribute.
- functionName string
- The name of the Lambda function, up to 64 characters in length. If you don't specify a name, CFN generates one. If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
- handler string
- The name of the method within your code that Lambda calls to run your function. Handler is required if the deployment package is a .zip file archive. The format includes the file name. It can also include namespaces and other qualifiers, depending on the runtime. For more information, see Lambda programming model.
- imageConfig FunctionImage Config 
- Configuration values that override the container image Dockerfile settings. For more information, see Container image settings.
- kmsKey stringArn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt the following resources: - The function's environment variables.
- The function's Lambda SnapStart snapshots.
- When used with SourceKMSKeyArn, the unzipped version of the .zip deployment package that's used for function invocations. For more information, see Specifying a customer managed key for Lambda.
- The optimized version of the container image that's used for function invocations. Note that this is not the same key that's used to protect your container image in the Amazon Elastic Container Registry (Amazon ECR). For more information, see Function lifecycle.
 - If you don't provide a customer managed key, Lambda uses an owned key or an . 
- layers string[]
- A list of function layers to add to the function's execution environment. Specify each layer by its ARN, including the version.
- loggingConfig FunctionLogging Config 
- The function's Amazon CloudWatch Logs configuration settings.
- memorySize number
- The amount of memory available to the function at runtime. Increasing the function memory also increases its CPU allocation. The default value is 128 MB. The value can be any multiple of 1 MB. Note that new AWS accounts have reduced concurrency and memory quotas. AWS raises these quotas automatically based on your usage. You can also request a quota increase.
- packageType FunctionPackage Type 
- The type of deployment package. Set to Imagefor container image and setZipfor .zip file archive.
- recursiveLoop FunctionRecursive Loop 
- The status of your function's recursive loop detection configuration.
When this value is set to Allowand Lambda detects your function being invoked as part of a recursive loop, it doesn't take any action. When this value is set toTerminateand Lambda detects your function being invoked as part of a recursive loop, it stops your function being invoked and notifies you.
- reservedConcurrent numberExecutions 
- The number of simultaneous executions to reserve for the function.
- runtime string
- The identifier of the function's runtime. Runtime is required if the deployment package is a .zip file archive. Specifying a runtime results in an error if you're deploying a function using a container image. The following list includes deprecated runtimes. Lambda blocks creating new functions and updating existing functions shortly after each runtime is deprecated. For more information, see Runtime use after deprecation. For a list of all currently supported runtimes, see Supported runtimes.
- runtimeManagement FunctionConfig Runtime Management Config 
- Sets the runtime management configuration for a function's version. For more information, see Runtime updates.
- snapStart FunctionSnap Start 
- The function's SnapStart setting.
- Tag[]
- A list of tags to apply to the function.
You must have the lambda:TagResource,lambda:UntagResource, andlambda:ListTagspermissions for your principal to manage the CFN stack. If you don't have these permissions, there might be unexpected behavior with stack-level tags propagating to the resource during resource creation and update.
- timeout number
- The amount of time (in seconds) that Lambda allows a function to run before stopping it. The default is 3 seconds. The maximum allowed value is 900 seconds. For more information, see Lambda execution environment.
- tracingConfig FunctionTracing Config 
- Set ModetoActiveto sample and trace a subset of incoming requests with X-Ray.
- vpcConfig FunctionVpc Config 
- For network connectivity to AWS resources in a VPC, specify a list of security groups and subnets in the VPC. When you connect a function to a VPC, it can access resources and the internet only through that VPC. For more information, see Configuring a Lambda function to access resources in a VPC.
- code
lambda_.Function Code Args 
- The code for the function. You can define your function code in multiple ways:- For .zip deployment packages, you can specify the S3 location of the .zip file in the S3Bucket,S3Key, andS3ObjectVersionproperties.
- For .zip deployment packages, you can alternatively define the function code inline in the ZipFileproperty. This method works only for Node.js and Python functions.
- For container images, specify the URI of your container image in the ECR registry in the ImageUriproperty.
 
- For .zip deployment packages, you can specify the S3 location of the .zip file in the 
- role str
- The Amazon Resource Name (ARN) of the function's execution role.
- architectures
Sequence[lambda_.Function Architectures Item] 
- The instruction set architecture that the function supports. Enter a string array with one of the valid values (arm64 or x86_64). The default value is x86_64.
- code_signing_ strconfig_ arn 
- To enable code signing for this function, specify the ARN of a code-signing configuration. A code-signing configuration includes a set of signing profiles, which define the trusted publishers for this function.
- dead_letter_ lambda_.config Function Dead Letter Config Args 
- A dead-letter queue configuration that specifies the queue or topic where Lambda sends asynchronous events when they fail processing. For more information, see Dead-letter queues.
- description str
- A description of the function.
- environment
lambda_.Function Environment Args 
- Environment variables that are accessible from function code during execution.
- ephemeral_storage lambda_.Function Ephemeral Storage Args 
- The size of the function's /tmpdirectory in MB. The default value is 512, but it can be any whole number between 512 and 10,240 MB.
- file_system_ Sequence[lambda_.configs Function File System Config Args] 
- Connection settings for an Amazon EFS file system. To connect a function to a file system, a mount target must be available in every Availability Zone that your function connects to. If your template contains an AWS::EFS::MountTarget resource, you must also specify a DependsOnattribute to ensure that the mount target is created or updated before the function. For more information about using theDependsOnattribute, see DependsOn Attribute.
- function_name str
- The name of the Lambda function, up to 64 characters in length. If you don't specify a name, CFN generates one. If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
- handler str
- The name of the method within your code that Lambda calls to run your function. Handler is required if the deployment package is a .zip file archive. The format includes the file name. It can also include namespaces and other qualifiers, depending on the runtime. For more information, see Lambda programming model.
- image_config lambda_.Function Image Config Args 
- Configuration values that override the container image Dockerfile settings. For more information, see Container image settings.
- kms_key_ strarn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt the following resources: - The function's environment variables.
- The function's Lambda SnapStart snapshots.
- When used with SourceKMSKeyArn, the unzipped version of the .zip deployment package that's used for function invocations. For more information, see Specifying a customer managed key for Lambda.
- The optimized version of the container image that's used for function invocations. Note that this is not the same key that's used to protect your container image in the Amazon Elastic Container Registry (Amazon ECR). For more information, see Function lifecycle.
 - If you don't provide a customer managed key, Lambda uses an owned key or an . 
- layers Sequence[str]
- A list of function layers to add to the function's execution environment. Specify each layer by its ARN, including the version.
- logging_config lambda_.Function Logging Config Args 
- The function's Amazon CloudWatch Logs configuration settings.
- memory_size int
- The amount of memory available to the function at runtime. Increasing the function memory also increases its CPU allocation. The default value is 128 MB. The value can be any multiple of 1 MB. Note that new AWS accounts have reduced concurrency and memory quotas. AWS raises these quotas automatically based on your usage. You can also request a quota increase.
- package_type lambda_.Function Package Type 
- The type of deployment package. Set to Imagefor container image and setZipfor .zip file archive.
- recursive_loop lambda_.Function Recursive Loop 
- The status of your function's recursive loop detection configuration.
When this value is set to Allowand Lambda detects your function being invoked as part of a recursive loop, it doesn't take any action. When this value is set toTerminateand Lambda detects your function being invoked as part of a recursive loop, it stops your function being invoked and notifies you.
- reserved_concurrent_ intexecutions 
- The number of simultaneous executions to reserve for the function.
- runtime str
- The identifier of the function's runtime. Runtime is required if the deployment package is a .zip file archive. Specifying a runtime results in an error if you're deploying a function using a container image. The following list includes deprecated runtimes. Lambda blocks creating new functions and updating existing functions shortly after each runtime is deprecated. For more information, see Runtime use after deprecation. For a list of all currently supported runtimes, see Supported runtimes.
- runtime_management_ lambda_.config Function Runtime Management Config Args 
- Sets the runtime management configuration for a function's version. For more information, see Runtime updates.
- snap_start lambda_.Function Snap Start Args 
- The function's SnapStart setting.
- 
Sequence[TagArgs] 
- A list of tags to apply to the function.
You must have the lambda:TagResource,lambda:UntagResource, andlambda:ListTagspermissions for your principal to manage the CFN stack. If you don't have these permissions, there might be unexpected behavior with stack-level tags propagating to the resource during resource creation and update.
- timeout int
- The amount of time (in seconds) that Lambda allows a function to run before stopping it. The default is 3 seconds. The maximum allowed value is 900 seconds. For more information, see Lambda execution environment.
- tracing_config lambda_.Function Tracing Config Args 
- Set ModetoActiveto sample and trace a subset of incoming requests with X-Ray.
- vpc_config lambda_.Function Vpc Config Args 
- For network connectivity to AWS resources in a VPC, specify a list of security groups and subnets in the VPC. When you connect a function to a VPC, it can access resources and the internet only through that VPC. For more information, see Configuring a Lambda function to access resources in a VPC.
- code Property Map
- The code for the function. You can define your function code in multiple ways:- For .zip deployment packages, you can specify the S3 location of the .zip file in the S3Bucket,S3Key, andS3ObjectVersionproperties.
- For .zip deployment packages, you can alternatively define the function code inline in the ZipFileproperty. This method works only for Node.js and Python functions.
- For container images, specify the URI of your container image in the ECR registry in the ImageUriproperty.
 
- For .zip deployment packages, you can specify the S3 location of the .zip file in the 
- role String
- The Amazon Resource Name (ARN) of the function's execution role.
- architectures List<"x86_64" | "arm64">
- The instruction set architecture that the function supports. Enter a string array with one of the valid values (arm64 or x86_64). The default value is x86_64.
- codeSigning StringConfig Arn 
- To enable code signing for this function, specify the ARN of a code-signing configuration. A code-signing configuration includes a set of signing profiles, which define the trusted publishers for this function.
- deadLetter Property MapConfig 
- A dead-letter queue configuration that specifies the queue or topic where Lambda sends asynchronous events when they fail processing. For more information, see Dead-letter queues.
- description String
- A description of the function.
- environment Property Map
- Environment variables that are accessible from function code during execution.
- ephemeralStorage Property Map
- The size of the function's /tmpdirectory in MB. The default value is 512, but it can be any whole number between 512 and 10,240 MB.
- fileSystem List<Property Map>Configs 
- Connection settings for an Amazon EFS file system. To connect a function to a file system, a mount target must be available in every Availability Zone that your function connects to. If your template contains an AWS::EFS::MountTarget resource, you must also specify a DependsOnattribute to ensure that the mount target is created or updated before the function. For more information about using theDependsOnattribute, see DependsOn Attribute.
- functionName String
- The name of the Lambda function, up to 64 characters in length. If you don't specify a name, CFN generates one. If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
- handler String
- The name of the method within your code that Lambda calls to run your function. Handler is required if the deployment package is a .zip file archive. The format includes the file name. It can also include namespaces and other qualifiers, depending on the runtime. For more information, see Lambda programming model.
- imageConfig Property Map
- Configuration values that override the container image Dockerfile settings. For more information, see Container image settings.
- kmsKey StringArn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt the following resources: - The function's environment variables.
- The function's Lambda SnapStart snapshots.
- When used with SourceKMSKeyArn, the unzipped version of the .zip deployment package that's used for function invocations. For more information, see Specifying a customer managed key for Lambda.
- The optimized version of the container image that's used for function invocations. Note that this is not the same key that's used to protect your container image in the Amazon Elastic Container Registry (Amazon ECR). For more information, see Function lifecycle.
 - If you don't provide a customer managed key, Lambda uses an owned key or an . 
- layers List<String>
- A list of function layers to add to the function's execution environment. Specify each layer by its ARN, including the version.
- loggingConfig Property Map
- The function's Amazon CloudWatch Logs configuration settings.
- memorySize Number
- The amount of memory available to the function at runtime. Increasing the function memory also increases its CPU allocation. The default value is 128 MB. The value can be any multiple of 1 MB. Note that new AWS accounts have reduced concurrency and memory quotas. AWS raises these quotas automatically based on your usage. You can also request a quota increase.
- packageType "Image" | "Zip"
- The type of deployment package. Set to Imagefor container image and setZipfor .zip file archive.
- recursiveLoop "Allow" | "Terminate"
- The status of your function's recursive loop detection configuration.
When this value is set to Allowand Lambda detects your function being invoked as part of a recursive loop, it doesn't take any action. When this value is set toTerminateand Lambda detects your function being invoked as part of a recursive loop, it stops your function being invoked and notifies you.
- reservedConcurrent NumberExecutions 
- The number of simultaneous executions to reserve for the function.
- runtime String
- The identifier of the function's runtime. Runtime is required if the deployment package is a .zip file archive. Specifying a runtime results in an error if you're deploying a function using a container image. The following list includes deprecated runtimes. Lambda blocks creating new functions and updating existing functions shortly after each runtime is deprecated. For more information, see Runtime use after deprecation. For a list of all currently supported runtimes, see Supported runtimes.
- runtimeManagement Property MapConfig 
- Sets the runtime management configuration for a function's version. For more information, see Runtime updates.
- snapStart Property Map
- The function's SnapStart setting.
- List<Property Map>
- A list of tags to apply to the function.
You must have the lambda:TagResource,lambda:UntagResource, andlambda:ListTagspermissions for your principal to manage the CFN stack. If you don't have these permissions, there might be unexpected behavior with stack-level tags propagating to the resource during resource creation and update.
- timeout Number
- The amount of time (in seconds) that Lambda allows a function to run before stopping it. The default is 3 seconds. The maximum allowed value is 900 seconds. For more information, see Lambda execution environment.
- tracingConfig Property Map
- Set ModetoActiveto sample and trace a subset of incoming requests with X-Ray.
- vpcConfig Property Map
- For network connectivity to AWS resources in a VPC, specify a list of security groups and subnets in the VPC. When you connect a function to a VPC, it can access resources and the internet only through that VPC. For more information, see Configuring a Lambda function to access resources in a VPC.
Outputs
All input properties are implicitly available as output properties. Additionally, the Function resource produces the following output properties:
- Arn string
- The Amazon Resource Name (ARN) of the function.
- Id string
- The provider-assigned unique ID for this managed resource.
- SnapStart Pulumi.Response Aws Native. Lambda. Outputs. Function Snap Start Response 
- Arn string
- The Amazon Resource Name (ARN) of the function.
- Id string
- The provider-assigned unique ID for this managed resource.
- SnapStart FunctionResponse Snap Start Response 
- arn String
- The Amazon Resource Name (ARN) of the function.
- id String
- The provider-assigned unique ID for this managed resource.
- snapStart FunctionResponse Snap Start Response 
- arn string
- The Amazon Resource Name (ARN) of the function.
- id string
- The provider-assigned unique ID for this managed resource.
- snapStart FunctionResponse Snap Start Response 
- arn str
- The Amazon Resource Name (ARN) of the function.
- id str
- The provider-assigned unique ID for this managed resource.
- snap_start_ lambda_.response Function Snap Start Response 
- arn String
- The Amazon Resource Name (ARN) of the function.
- id String
- The provider-assigned unique ID for this managed resource.
- snapStart Property MapResponse 
Supporting Types
FunctionArchitecturesItem, FunctionArchitecturesItemArgs      
- X8664
- x86_64
- Arm64
- arm64
- FunctionArchitectures Item X8664 
- x86_64
- FunctionArchitectures Item Arm64 
- arm64
- X8664
- x86_64
- Arm64
- arm64
- X8664
- x86_64
- Arm64
- arm64
- X8664
- x86_64
- ARM64
- arm64
- "x86_64"
- x86_64
- "arm64"
- arm64
FunctionCode, FunctionCodeArgs    
- ImageUri string
- URI of a container image in the Amazon ECR registry.
- S3Bucket string
- An Amazon S3 bucket in the same AWS-Region as your function. The bucket can be in a different AWS-account.
- S3Key string
- The Amazon S3 key of the deployment package.
- S3ObjectVersion string
- For versioned objects, the version of the deployment package object to use.
- SourceKms stringKey Arn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt your function's .zip deployment package. If you don't provide a customer managed key, Lambda uses an owned key.
- ZipFile string
- (Node.js and Python) The source code of your Lambda function. If you include your function source inline with this parameter, CFN places it in a file named indexand zips it to create a deployment package. This zip file cannot exceed 4MB. For theHandlerproperty, the first part of the handler identifier must beindex. For example,index.handler. When you specify source code inline for a Node.js function, theindexfile that CFN creates uses the extension.js. This means that LAM treats the file as a CommonJS module. ES modules aren't supported for inline functions. For JSON, you must escape quotes and special characters such as newline (\n) with a backslash. If you specify a function that interacts with an AWS CloudFormation custom resource, you don't have to write your own functions to send responses to the custom resource that invoked the function. AWS CloudFormation provides a response module (cfn-response) that simplifies sending responses. See Using Lambda with CloudFormation for details.
- ImageUri string
- URI of a container image in the Amazon ECR registry.
- S3Bucket string
- An Amazon S3 bucket in the same AWS-Region as your function. The bucket can be in a different AWS-account.
- S3Key string
- The Amazon S3 key of the deployment package.
- S3ObjectVersion string
- For versioned objects, the version of the deployment package object to use.
- SourceKms stringKey Arn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt your function's .zip deployment package. If you don't provide a customer managed key, Lambda uses an owned key.
- ZipFile string
- (Node.js and Python) The source code of your Lambda function. If you include your function source inline with this parameter, CFN places it in a file named indexand zips it to create a deployment package. This zip file cannot exceed 4MB. For theHandlerproperty, the first part of the handler identifier must beindex. For example,index.handler. When you specify source code inline for a Node.js function, theindexfile that CFN creates uses the extension.js. This means that LAM treats the file as a CommonJS module. ES modules aren't supported for inline functions. For JSON, you must escape quotes and special characters such as newline (\n) with a backslash. If you specify a function that interacts with an AWS CloudFormation custom resource, you don't have to write your own functions to send responses to the custom resource that invoked the function. AWS CloudFormation provides a response module (cfn-response) that simplifies sending responses. See Using Lambda with CloudFormation for details.
- imageUri String
- URI of a container image in the Amazon ECR registry.
- s3Bucket String
- An Amazon S3 bucket in the same AWS-Region as your function. The bucket can be in a different AWS-account.
- s3Key String
- The Amazon S3 key of the deployment package.
- s3ObjectVersion String
- For versioned objects, the version of the deployment package object to use.
- sourceKms StringKey Arn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt your function's .zip deployment package. If you don't provide a customer managed key, Lambda uses an owned key.
- zipFile String
- (Node.js and Python) The source code of your Lambda function. If you include your function source inline with this parameter, CFN places it in a file named indexand zips it to create a deployment package. This zip file cannot exceed 4MB. For theHandlerproperty, the first part of the handler identifier must beindex. For example,index.handler. When you specify source code inline for a Node.js function, theindexfile that CFN creates uses the extension.js. This means that LAM treats the file as a CommonJS module. ES modules aren't supported for inline functions. For JSON, you must escape quotes and special characters such as newline (\n) with a backslash. If you specify a function that interacts with an AWS CloudFormation custom resource, you don't have to write your own functions to send responses to the custom resource that invoked the function. AWS CloudFormation provides a response module (cfn-response) that simplifies sending responses. See Using Lambda with CloudFormation for details.
- imageUri string
- URI of a container image in the Amazon ECR registry.
- s3Bucket string
- An Amazon S3 bucket in the same AWS-Region as your function. The bucket can be in a different AWS-account.
- s3Key string
- The Amazon S3 key of the deployment package.
- s3ObjectVersion string
- For versioned objects, the version of the deployment package object to use.
- sourceKms stringKey Arn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt your function's .zip deployment package. If you don't provide a customer managed key, Lambda uses an owned key.
- zipFile string
- (Node.js and Python) The source code of your Lambda function. If you include your function source inline with this parameter, CFN places it in a file named indexand zips it to create a deployment package. This zip file cannot exceed 4MB. For theHandlerproperty, the first part of the handler identifier must beindex. For example,index.handler. When you specify source code inline for a Node.js function, theindexfile that CFN creates uses the extension.js. This means that LAM treats the file as a CommonJS module. ES modules aren't supported for inline functions. For JSON, you must escape quotes and special characters such as newline (\n) with a backslash. If you specify a function that interacts with an AWS CloudFormation custom resource, you don't have to write your own functions to send responses to the custom resource that invoked the function. AWS CloudFormation provides a response module (cfn-response) that simplifies sending responses. See Using Lambda with CloudFormation for details.
- image_uri str
- URI of a container image in the Amazon ECR registry.
- s3_bucket str
- An Amazon S3 bucket in the same AWS-Region as your function. The bucket can be in a different AWS-account.
- s3_key str
- The Amazon S3 key of the deployment package.
- s3_object_ strversion 
- For versioned objects, the version of the deployment package object to use.
- source_kms_ strkey_ arn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt your function's .zip deployment package. If you don't provide a customer managed key, Lambda uses an owned key.
- zip_file str
- (Node.js and Python) The source code of your Lambda function. If you include your function source inline with this parameter, CFN places it in a file named indexand zips it to create a deployment package. This zip file cannot exceed 4MB. For theHandlerproperty, the first part of the handler identifier must beindex. For example,index.handler. When you specify source code inline for a Node.js function, theindexfile that CFN creates uses the extension.js. This means that LAM treats the file as a CommonJS module. ES modules aren't supported for inline functions. For JSON, you must escape quotes and special characters such as newline (\n) with a backslash. If you specify a function that interacts with an AWS CloudFormation custom resource, you don't have to write your own functions to send responses to the custom resource that invoked the function. AWS CloudFormation provides a response module (cfn-response) that simplifies sending responses. See Using Lambda with CloudFormation for details.
- imageUri String
- URI of a container image in the Amazon ECR registry.
- s3Bucket String
- An Amazon S3 bucket in the same AWS-Region as your function. The bucket can be in a different AWS-account.
- s3Key String
- The Amazon S3 key of the deployment package.
- s3ObjectVersion String
- For versioned objects, the version of the deployment package object to use.
- sourceKms StringKey Arn 
- The ARN of the KMSlong (KMS) customer managed key that's used to encrypt your function's .zip deployment package. If you don't provide a customer managed key, Lambda uses an owned key.
- zipFile String
- (Node.js and Python) The source code of your Lambda function. If you include your function source inline with this parameter, CFN places it in a file named indexand zips it to create a deployment package. This zip file cannot exceed 4MB. For theHandlerproperty, the first part of the handler identifier must beindex. For example,index.handler. When you specify source code inline for a Node.js function, theindexfile that CFN creates uses the extension.js. This means that LAM treats the file as a CommonJS module. ES modules aren't supported for inline functions. For JSON, you must escape quotes and special characters such as newline (\n) with a backslash. If you specify a function that interacts with an AWS CloudFormation custom resource, you don't have to write your own functions to send responses to the custom resource that invoked the function. AWS CloudFormation provides a response module (cfn-response) that simplifies sending responses. See Using Lambda with CloudFormation for details.
FunctionDeadLetterConfig, FunctionDeadLetterConfigArgs        
- TargetArn string
- The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic.
- TargetArn string
- The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic.
- targetArn String
- The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic.
- targetArn string
- The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic.
- target_arn str
- The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic.
- targetArn String
- The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic.
FunctionEnvironment, FunctionEnvironmentArgs    
- Variables Dictionary<string, string>
- Environment variable key-value pairs. For more information, see Using Lambda environment variables. If the value of the environment variable is a time or a duration, enclose the value in quotes.
- Variables map[string]string
- Environment variable key-value pairs. For more information, see Using Lambda environment variables. If the value of the environment variable is a time or a duration, enclose the value in quotes.
- variables Map<String,String>
- Environment variable key-value pairs. For more information, see Using Lambda environment variables. If the value of the environment variable is a time or a duration, enclose the value in quotes.
- variables {[key: string]: string}
- Environment variable key-value pairs. For more information, see Using Lambda environment variables. If the value of the environment variable is a time or a duration, enclose the value in quotes.
- variables Mapping[str, str]
- Environment variable key-value pairs. For more information, see Using Lambda environment variables. If the value of the environment variable is a time or a duration, enclose the value in quotes.
- variables Map<String>
- Environment variable key-value pairs. For more information, see Using Lambda environment variables. If the value of the environment variable is a time or a duration, enclose the value in quotes.
FunctionEphemeralStorage, FunctionEphemeralStorageArgs      
- Size int
- The size of the function's /tmpdirectory.
- Size int
- The size of the function's /tmpdirectory.
- size Integer
- The size of the function's /tmpdirectory.
- size number
- The size of the function's /tmpdirectory.
- size int
- The size of the function's /tmpdirectory.
- size Number
- The size of the function's /tmpdirectory.
FunctionFileSystemConfig, FunctionFileSystemConfigArgs        
- Arn string
- The Amazon Resource Name (ARN) of the Amazon EFS access point that provides access to the file system.
- LocalMount stringPath 
- The path where the function can access the file system, starting with /mnt/.
- Arn string
- The Amazon Resource Name (ARN) of the Amazon EFS access point that provides access to the file system.
- LocalMount stringPath 
- The path where the function can access the file system, starting with /mnt/.
- arn String
- The Amazon Resource Name (ARN) of the Amazon EFS access point that provides access to the file system.
- localMount StringPath 
- The path where the function can access the file system, starting with /mnt/.
- arn string
- The Amazon Resource Name (ARN) of the Amazon EFS access point that provides access to the file system.
- localMount stringPath 
- The path where the function can access the file system, starting with /mnt/.
- arn str
- The Amazon Resource Name (ARN) of the Amazon EFS access point that provides access to the file system.
- local_mount_ strpath 
- The path where the function can access the file system, starting with /mnt/.
- arn String
- The Amazon Resource Name (ARN) of the Amazon EFS access point that provides access to the file system.
- localMount StringPath 
- The path where the function can access the file system, starting with /mnt/.
FunctionImageConfig, FunctionImageConfigArgs      
- Command List<string>
- Specifies parameters that you want to pass in with ENTRYPOINT. You can specify a maximum of 1,500 parameters in the list.
- EntryPoint List<string>
- Specifies the entry point to their application, which is typically the location of the runtime executable. You can specify a maximum of 1,500 string entries in the list.
- WorkingDirectory string
- Specifies the working directory. The length of the directory string cannot exceed 1,000 characters.
- Command []string
- Specifies parameters that you want to pass in with ENTRYPOINT. You can specify a maximum of 1,500 parameters in the list.
- EntryPoint []string
- Specifies the entry point to their application, which is typically the location of the runtime executable. You can specify a maximum of 1,500 string entries in the list.
- WorkingDirectory string
- Specifies the working directory. The length of the directory string cannot exceed 1,000 characters.
- command List<String>
- Specifies parameters that you want to pass in with ENTRYPOINT. You can specify a maximum of 1,500 parameters in the list.
- entryPoint List<String>
- Specifies the entry point to their application, which is typically the location of the runtime executable. You can specify a maximum of 1,500 string entries in the list.
- workingDirectory String
- Specifies the working directory. The length of the directory string cannot exceed 1,000 characters.
- command string[]
- Specifies parameters that you want to pass in with ENTRYPOINT. You can specify a maximum of 1,500 parameters in the list.
- entryPoint string[]
- Specifies the entry point to their application, which is typically the location of the runtime executable. You can specify a maximum of 1,500 string entries in the list.
- workingDirectory string
- Specifies the working directory. The length of the directory string cannot exceed 1,000 characters.
- command Sequence[str]
- Specifies parameters that you want to pass in with ENTRYPOINT. You can specify a maximum of 1,500 parameters in the list.
- entry_point Sequence[str]
- Specifies the entry point to their application, which is typically the location of the runtime executable. You can specify a maximum of 1,500 string entries in the list.
- working_directory str
- Specifies the working directory. The length of the directory string cannot exceed 1,000 characters.
- command List<String>
- Specifies parameters that you want to pass in with ENTRYPOINT. You can specify a maximum of 1,500 parameters in the list.
- entryPoint List<String>
- Specifies the entry point to their application, which is typically the location of the runtime executable. You can specify a maximum of 1,500 string entries in the list.
- workingDirectory String
- Specifies the working directory. The length of the directory string cannot exceed 1,000 characters.
FunctionLoggingConfig, FunctionLoggingConfigArgs      
- ApplicationLog Pulumi.Level Aws Native. Lambda. Function Logging Config Application Log Level 
- Set this property to filter the application logs for your function that Lambda sends to CloudWatch. Lambda only sends application logs at the selected level of detail and lower, where TRACEis the highest level andFATALis the lowest.
- LogFormat Pulumi.Aws Native. Lambda. Function Logging Config Log Format 
- The format in which Lambda sends your function's application and system logs to CloudWatch. Select between plain text and structured JSON.
- LogGroup string
- The name of the Amazon CloudWatch log group the function sends logs to. By default, Lambda functions send logs to a default log group named /aws/lambda/<function name>. To use a different log group, enter an existing log group or enter a new log group name.
- SystemLog Pulumi.Level Aws Native. Lambda. Function Logging Config System Log Level 
- Set this property to filter the system logs for your function that Lambda sends to CloudWatch. Lambda only sends system logs at the selected level of detail and lower, where DEBUGis the highest level andWARNis the lowest.
- ApplicationLog FunctionLevel Logging Config Application Log Level 
- Set this property to filter the application logs for your function that Lambda sends to CloudWatch. Lambda only sends application logs at the selected level of detail and lower, where TRACEis the highest level andFATALis the lowest.
- LogFormat FunctionLogging Config Log Format 
- The format in which Lambda sends your function's application and system logs to CloudWatch. Select between plain text and structured JSON.
- LogGroup string
- The name of the Amazon CloudWatch log group the function sends logs to. By default, Lambda functions send logs to a default log group named /aws/lambda/<function name>. To use a different log group, enter an existing log group or enter a new log group name.
- SystemLog FunctionLevel Logging Config System Log Level 
- Set this property to filter the system logs for your function that Lambda sends to CloudWatch. Lambda only sends system logs at the selected level of detail and lower, where DEBUGis the highest level andWARNis the lowest.
- applicationLog FunctionLevel Logging Config Application Log Level 
- Set this property to filter the application logs for your function that Lambda sends to CloudWatch. Lambda only sends application logs at the selected level of detail and lower, where TRACEis the highest level andFATALis the lowest.
- logFormat FunctionLogging Config Log Format 
- The format in which Lambda sends your function's application and system logs to CloudWatch. Select between plain text and structured JSON.
- logGroup String
- The name of the Amazon CloudWatch log group the function sends logs to. By default, Lambda functions send logs to a default log group named /aws/lambda/<function name>. To use a different log group, enter an existing log group or enter a new log group name.
- systemLog FunctionLevel Logging Config System Log Level 
- Set this property to filter the system logs for your function that Lambda sends to CloudWatch. Lambda only sends system logs at the selected level of detail and lower, where DEBUGis the highest level andWARNis the lowest.
- applicationLog FunctionLevel Logging Config Application Log Level 
- Set this property to filter the application logs for your function that Lambda sends to CloudWatch. Lambda only sends application logs at the selected level of detail and lower, where TRACEis the highest level andFATALis the lowest.
- logFormat FunctionLogging Config Log Format 
- The format in which Lambda sends your function's application and system logs to CloudWatch. Select between plain text and structured JSON.
- logGroup string
- The name of the Amazon CloudWatch log group the function sends logs to. By default, Lambda functions send logs to a default log group named /aws/lambda/<function name>. To use a different log group, enter an existing log group or enter a new log group name.
- systemLog FunctionLevel Logging Config System Log Level 
- Set this property to filter the system logs for your function that Lambda sends to CloudWatch. Lambda only sends system logs at the selected level of detail and lower, where DEBUGis the highest level andWARNis the lowest.
- application_log_ lambda_.level Function Logging Config Application Log Level 
- Set this property to filter the application logs for your function that Lambda sends to CloudWatch. Lambda only sends application logs at the selected level of detail and lower, where TRACEis the highest level andFATALis the lowest.
- log_format lambda_.Function Logging Config Log Format 
- The format in which Lambda sends your function's application and system logs to CloudWatch. Select between plain text and structured JSON.
- log_group str
- The name of the Amazon CloudWatch log group the function sends logs to. By default, Lambda functions send logs to a default log group named /aws/lambda/<function name>. To use a different log group, enter an existing log group or enter a new log group name.
- system_log_ lambda_.level Function Logging Config System Log Level 
- Set this property to filter the system logs for your function that Lambda sends to CloudWatch. Lambda only sends system logs at the selected level of detail and lower, where DEBUGis the highest level andWARNis the lowest.
- applicationLog "TRACE" | "DEBUG" | "INFO" | "WARN" | "ERROR" | "FATAL"Level 
- Set this property to filter the application logs for your function that Lambda sends to CloudWatch. Lambda only sends application logs at the selected level of detail and lower, where TRACEis the highest level andFATALis the lowest.
- logFormat "Text" | "JSON"
- The format in which Lambda sends your function's application and system logs to CloudWatch. Select between plain text and structured JSON.
- logGroup String
- The name of the Amazon CloudWatch log group the function sends logs to. By default, Lambda functions send logs to a default log group named /aws/lambda/<function name>. To use a different log group, enter an existing log group or enter a new log group name.
- systemLog "DEBUG" | "INFO" | "WARN"Level 
- Set this property to filter the system logs for your function that Lambda sends to CloudWatch. Lambda only sends system logs at the selected level of detail and lower, where DEBUGis the highest level andWARNis the lowest.
FunctionLoggingConfigApplicationLogLevel, FunctionLoggingConfigApplicationLogLevelArgs            
- Trace
- TRACE
- Debug
- DEBUG
- Info
- INFO
- Warn
- WARN
- Error
- ERROR
- Fatal
- FATAL
- FunctionLogging Config Application Log Level Trace 
- TRACE
- FunctionLogging Config Application Log Level Debug 
- DEBUG
- FunctionLogging Config Application Log Level Info 
- INFO
- FunctionLogging Config Application Log Level Warn 
- WARN
- FunctionLogging Config Application Log Level Error 
- ERROR
- FunctionLogging Config Application Log Level Fatal 
- FATAL
- Trace
- TRACE
- Debug
- DEBUG
- Info
- INFO
- Warn
- WARN
- Error
- ERROR
- Fatal
- FATAL
- Trace
- TRACE
- Debug
- DEBUG
- Info
- INFO
- Warn
- WARN
- Error
- ERROR
- Fatal
- FATAL
- TRACE
- TRACE
- DEBUG
- DEBUG
- INFO
- INFO
- WARN
- WARN
- ERROR
- ERROR
- FATAL
- FATAL
- "TRACE"
- TRACE
- "DEBUG"
- DEBUG
- "INFO"
- INFO
- "WARN"
- WARN
- "ERROR"
- ERROR
- "FATAL"
- FATAL
FunctionLoggingConfigLogFormat, FunctionLoggingConfigLogFormatArgs          
- Text
- Text
- Json
- JSON
- FunctionLogging Config Log Format Text 
- Text
- FunctionLogging Config Log Format Json 
- JSON
- Text
- Text
- Json
- JSON
- Text
- Text
- Json
- JSON
- TEXT
- Text
- JSON
- JSON
- "Text"
- Text
- "JSON"
- JSON
FunctionLoggingConfigSystemLogLevel, FunctionLoggingConfigSystemLogLevelArgs            
- Debug
- DEBUG
- Info
- INFO
- Warn
- WARN
- FunctionLogging Config System Log Level Debug 
- DEBUG
- FunctionLogging Config System Log Level Info 
- INFO
- FunctionLogging Config System Log Level Warn 
- WARN
- Debug
- DEBUG
- Info
- INFO
- Warn
- WARN
- Debug
- DEBUG
- Info
- INFO
- Warn
- WARN
- DEBUG
- DEBUG
- INFO
- INFO
- WARN
- WARN
- "DEBUG"
- DEBUG
- "INFO"
- INFO
- "WARN"
- WARN
FunctionPackageType, FunctionPackageTypeArgs      
- Image
- Image
- Zip
- Zip
- FunctionPackage Type Image 
- Image
- FunctionPackage Type Zip 
- Zip
- Image
- Image
- Zip
- Zip
- Image
- Image
- Zip
- Zip
- IMAGE
- Image
- ZIP
- Zip
- "Image"
- Image
- "Zip"
- Zip
FunctionRecursiveLoop, FunctionRecursiveLoopArgs      
- Allow
- Allow
- Terminate
- Terminate
- FunctionRecursive Loop Allow 
- Allow
- FunctionRecursive Loop Terminate 
- Terminate
- Allow
- Allow
- Terminate
- Terminate
- Allow
- Allow
- Terminate
- Terminate
- ALLOW
- Allow
- TERMINATE
- Terminate
- "Allow"
- Allow
- "Terminate"
- Terminate
FunctionRuntimeManagementConfig, FunctionRuntimeManagementConfigArgs        
- UpdateRuntime Pulumi.On Aws Native. Lambda. Function Runtime Management Config Update Runtime On 
- Specify the runtime update mode. - Auto (default) - Automatically update to the most recent and secure runtime version using a Two-phase runtime version rollout. This is the best choice for most customers to ensure they always benefit from runtime updates.
- FunctionUpdate - LAM updates the runtime of you function to the most recent and secure runtime version when you update your function. This approach synchronizes runtime updates with function deployments, giving you control over when runtime updates are applied and allowing you to detect and mitigate rare runtime update incompatibilities early. When using this setting, you need to regularly update your functions to keep their runtime up-to-date.
- Manual - You specify a runtime version in your function configuration. The function will use this runtime version indefinitely. In the rare case where a new runtime version is incompatible with an existing function, this allows you to roll back your function to an earlier runtime version. For more information, see Roll back a runtime version.
 - Valid Values: - Auto|- FunctionUpdate|- Manual
- RuntimeVersion stringArn 
- The ARN of the runtime version you want the function to use. This is only required if you're using the Manual runtime update mode.
- UpdateRuntime FunctionOn Runtime Management Config Update Runtime On 
- Specify the runtime update mode. - Auto (default) - Automatically update to the most recent and secure runtime version using a Two-phase runtime version rollout. This is the best choice for most customers to ensure they always benefit from runtime updates.
- FunctionUpdate - LAM updates the runtime of you function to the most recent and secure runtime version when you update your function. This approach synchronizes runtime updates with function deployments, giving you control over when runtime updates are applied and allowing you to detect and mitigate rare runtime update incompatibilities early. When using this setting, you need to regularly update your functions to keep their runtime up-to-date.
- Manual - You specify a runtime version in your function configuration. The function will use this runtime version indefinitely. In the rare case where a new runtime version is incompatible with an existing function, this allows you to roll back your function to an earlier runtime version. For more information, see Roll back a runtime version.
 - Valid Values: - Auto|- FunctionUpdate|- Manual
- RuntimeVersion stringArn 
- The ARN of the runtime version you want the function to use. This is only required if you're using the Manual runtime update mode.
- updateRuntime FunctionOn Runtime Management Config Update Runtime On 
- Specify the runtime update mode. - Auto (default) - Automatically update to the most recent and secure runtime version using a Two-phase runtime version rollout. This is the best choice for most customers to ensure they always benefit from runtime updates.
- FunctionUpdate - LAM updates the runtime of you function to the most recent and secure runtime version when you update your function. This approach synchronizes runtime updates with function deployments, giving you control over when runtime updates are applied and allowing you to detect and mitigate rare runtime update incompatibilities early. When using this setting, you need to regularly update your functions to keep their runtime up-to-date.
- Manual - You specify a runtime version in your function configuration. The function will use this runtime version indefinitely. In the rare case where a new runtime version is incompatible with an existing function, this allows you to roll back your function to an earlier runtime version. For more information, see Roll back a runtime version.
 - Valid Values: - Auto|- FunctionUpdate|- Manual
- runtimeVersion StringArn 
- The ARN of the runtime version you want the function to use. This is only required if you're using the Manual runtime update mode.
- updateRuntime FunctionOn Runtime Management Config Update Runtime On 
- Specify the runtime update mode. - Auto (default) - Automatically update to the most recent and secure runtime version using a Two-phase runtime version rollout. This is the best choice for most customers to ensure they always benefit from runtime updates.
- FunctionUpdate - LAM updates the runtime of you function to the most recent and secure runtime version when you update your function. This approach synchronizes runtime updates with function deployments, giving you control over when runtime updates are applied and allowing you to detect and mitigate rare runtime update incompatibilities early. When using this setting, you need to regularly update your functions to keep their runtime up-to-date.
- Manual - You specify a runtime version in your function configuration. The function will use this runtime version indefinitely. In the rare case where a new runtime version is incompatible with an existing function, this allows you to roll back your function to an earlier runtime version. For more information, see Roll back a runtime version.
 - Valid Values: - Auto|- FunctionUpdate|- Manual
- runtimeVersion stringArn 
- The ARN of the runtime version you want the function to use. This is only required if you're using the Manual runtime update mode.
- update_runtime_ lambda_.on Function Runtime Management Config Update Runtime On 
- Specify the runtime update mode. - Auto (default) - Automatically update to the most recent and secure runtime version using a Two-phase runtime version rollout. This is the best choice for most customers to ensure they always benefit from runtime updates.
- FunctionUpdate - LAM updates the runtime of you function to the most recent and secure runtime version when you update your function. This approach synchronizes runtime updates with function deployments, giving you control over when runtime updates are applied and allowing you to detect and mitigate rare runtime update incompatibilities early. When using this setting, you need to regularly update your functions to keep their runtime up-to-date.
- Manual - You specify a runtime version in your function configuration. The function will use this runtime version indefinitely. In the rare case where a new runtime version is incompatible with an existing function, this allows you to roll back your function to an earlier runtime version. For more information, see Roll back a runtime version.
 - Valid Values: - Auto|- FunctionUpdate|- Manual
- runtime_version_ strarn 
- The ARN of the runtime version you want the function to use. This is only required if you're using the Manual runtime update mode.
- updateRuntime "Auto" | "FunctionOn Update" | "Manual" 
- Specify the runtime update mode. - Auto (default) - Automatically update to the most recent and secure runtime version using a Two-phase runtime version rollout. This is the best choice for most customers to ensure they always benefit from runtime updates.
- FunctionUpdate - LAM updates the runtime of you function to the most recent and secure runtime version when you update your function. This approach synchronizes runtime updates with function deployments, giving you control over when runtime updates are applied and allowing you to detect and mitigate rare runtime update incompatibilities early. When using this setting, you need to regularly update your functions to keep their runtime up-to-date.
- Manual - You specify a runtime version in your function configuration. The function will use this runtime version indefinitely. In the rare case where a new runtime version is incompatible with an existing function, this allows you to roll back your function to an earlier runtime version. For more information, see Roll back a runtime version.
 - Valid Values: - Auto|- FunctionUpdate|- Manual
- runtimeVersion StringArn 
- The ARN of the runtime version you want the function to use. This is only required if you're using the Manual runtime update mode.
FunctionRuntimeManagementConfigUpdateRuntimeOn, FunctionRuntimeManagementConfigUpdateRuntimeOnArgs              
- Auto
- Auto
- FunctionUpdate 
- FunctionUpdate
- Manual
- Manual
- FunctionRuntime Management Config Update Runtime On Auto 
- Auto
- FunctionRuntime Management Config Update Runtime On Function Update 
- FunctionUpdate
- FunctionRuntime Management Config Update Runtime On Manual 
- Manual
- Auto
- Auto
- FunctionUpdate 
- FunctionUpdate
- Manual
- Manual
- Auto
- Auto
- FunctionUpdate 
- FunctionUpdate
- Manual
- Manual
- AUTO
- Auto
- FUNCTION_UPDATE
- FunctionUpdate
- MANUAL
- Manual
- "Auto"
- Auto
- "FunctionUpdate" 
- FunctionUpdate
- "Manual"
- Manual
FunctionSnapStart, FunctionSnapStartArgs      
- ApplyOn Pulumi.Aws Native. Lambda. Function Snap Start Apply On 
- Set ApplyOntoPublishedVersionsto create a snapshot of the initialized execution environment when you publish a function version.
- ApplyOn FunctionSnap Start Apply On 
- Set ApplyOntoPublishedVersionsto create a snapshot of the initialized execution environment when you publish a function version.
- applyOn FunctionSnap Start Apply On 
- Set ApplyOntoPublishedVersionsto create a snapshot of the initialized execution environment when you publish a function version.
- applyOn FunctionSnap Start Apply On 
- Set ApplyOntoPublishedVersionsto create a snapshot of the initialized execution environment when you publish a function version.
- apply_on lambda_.Function Snap Start Apply On 
- Set ApplyOntoPublishedVersionsto create a snapshot of the initialized execution environment when you publish a function version.
- applyOn "PublishedVersions" | "None" 
- Set ApplyOntoPublishedVersionsto create a snapshot of the initialized execution environment when you publish a function version.
FunctionSnapStartApplyOn, FunctionSnapStartApplyOnArgs          
- PublishedVersions 
- PublishedVersions
- None
- None
- FunctionSnap Start Apply On Published Versions 
- PublishedVersions
- FunctionSnap Start Apply On None 
- None
- PublishedVersions 
- PublishedVersions
- None
- None
- PublishedVersions 
- PublishedVersions
- None
- None
- PUBLISHED_VERSIONS
- PublishedVersions
- NONE
- None
- "PublishedVersions" 
- PublishedVersions
- "None"
- None
FunctionSnapStartResponse, FunctionSnapStartResponseArgs        
- ApplyOn Pulumi.Aws Native. Lambda. Function Snap Start Response Apply On 
- When set to PublishedVersions, Lambda creates a snapshot of the execution environment when you publish a function version.
- OptimizationStatus Pulumi.Aws Native. Lambda. Function Snap Start Response Optimization Status 
- When you provide a qualified Amazon Resource Name (ARN), this response element indicates whether SnapStart is activated for the specified function version.
- ApplyOn FunctionSnap Start Response Apply On 
- When set to PublishedVersions, Lambda creates a snapshot of the execution environment when you publish a function version.
- OptimizationStatus FunctionSnap Start Response Optimization Status 
- When you provide a qualified Amazon Resource Name (ARN), this response element indicates whether SnapStart is activated for the specified function version.
- applyOn FunctionSnap Start Response Apply On 
- When set to PublishedVersions, Lambda creates a snapshot of the execution environment when you publish a function version.
- optimizationStatus FunctionSnap Start Response Optimization Status 
- When you provide a qualified Amazon Resource Name (ARN), this response element indicates whether SnapStart is activated for the specified function version.
- applyOn FunctionSnap Start Response Apply On 
- When set to PublishedVersions, Lambda creates a snapshot of the execution environment when you publish a function version.
- optimizationStatus FunctionSnap Start Response Optimization Status 
- When you provide a qualified Amazon Resource Name (ARN), this response element indicates whether SnapStart is activated for the specified function version.
- apply_on lambda_.Function Snap Start Response Apply On 
- When set to PublishedVersions, Lambda creates a snapshot of the execution environment when you publish a function version.
- optimization_status lambda_.Function Snap Start Response Optimization Status 
- When you provide a qualified Amazon Resource Name (ARN), this response element indicates whether SnapStart is activated for the specified function version.
- applyOn "PublishedVersions" | "None" 
- When set to PublishedVersions, Lambda creates a snapshot of the execution environment when you publish a function version.
- optimizationStatus "On" | "Off"
- When you provide a qualified Amazon Resource Name (ARN), this response element indicates whether SnapStart is activated for the specified function version.
FunctionSnapStartResponseApplyOn, FunctionSnapStartResponseApplyOnArgs            
- PublishedVersions 
- PublishedVersions
- None
- None
- FunctionSnap Start Response Apply On Published Versions 
- PublishedVersions
- FunctionSnap Start Response Apply On None 
- None
- PublishedVersions 
- PublishedVersions
- None
- None
- PublishedVersions 
- PublishedVersions
- None
- None
- PUBLISHED_VERSIONS
- PublishedVersions
- NONE
- None
- "PublishedVersions" 
- PublishedVersions
- "None"
- None
FunctionSnapStartResponseOptimizationStatus, FunctionSnapStartResponseOptimizationStatusArgs            
- On
- On
- Off
- Off
- FunctionSnap Start Response Optimization Status On 
- On
- FunctionSnap Start Response Optimization Status Off 
- Off
- On
- On
- Off
- Off
- On
- On
- Off
- Off
- ON
- On
- OFF
- Off
- "On"
- On
- "Off"
- Off
FunctionTracingConfig, FunctionTracingConfigArgs      
- Mode
Pulumi.Aws Native. Lambda. Function Tracing Config Mode 
- The tracing mode.
- Mode
FunctionTracing Config Mode 
- The tracing mode.
- mode
FunctionTracing Config Mode 
- The tracing mode.
- mode
FunctionTracing Config Mode 
- The tracing mode.
- mode
lambda_.Function Tracing Config Mode 
- The tracing mode.
- mode
"Active" | "PassThrough" 
- The tracing mode.
FunctionTracingConfigMode, FunctionTracingConfigModeArgs        
- Active
- Active
- PassThrough 
- PassThrough
- FunctionTracing Config Mode Active 
- Active
- FunctionTracing Config Mode Pass Through 
- PassThrough
- Active
- Active
- PassThrough 
- PassThrough
- Active
- Active
- PassThrough 
- PassThrough
- ACTIVE
- Active
- PASS_THROUGH
- PassThrough
- "Active"
- Active
- "PassThrough" 
- PassThrough
FunctionVpcConfig, FunctionVpcConfigArgs      
- Ipv6AllowedFor boolDual Stack 
- Allows outbound IPv6 traffic on VPC functions that are connected to dual-stack subnets.
- SecurityGroup List<string>Ids 
- A list of VPC security group IDs.
- SubnetIds List<string>
- A list of VPC subnet IDs.
- Ipv6AllowedFor boolDual Stack 
- Allows outbound IPv6 traffic on VPC functions that are connected to dual-stack subnets.
- SecurityGroup []stringIds 
- A list of VPC security group IDs.
- SubnetIds []string
- A list of VPC subnet IDs.
- ipv6AllowedFor BooleanDual Stack 
- Allows outbound IPv6 traffic on VPC functions that are connected to dual-stack subnets.
- securityGroup List<String>Ids 
- A list of VPC security group IDs.
- subnetIds List<String>
- A list of VPC subnet IDs.
- ipv6AllowedFor booleanDual Stack 
- Allows outbound IPv6 traffic on VPC functions that are connected to dual-stack subnets.
- securityGroup string[]Ids 
- A list of VPC security group IDs.
- subnetIds string[]
- A list of VPC subnet IDs.
- ipv6_allowed_ boolfor_ dual_ stack 
- Allows outbound IPv6 traffic on VPC functions that are connected to dual-stack subnets.
- security_group_ Sequence[str]ids 
- A list of VPC security group IDs.
- subnet_ids Sequence[str]
- A list of VPC subnet IDs.
- ipv6AllowedFor BooleanDual Stack 
- Allows outbound IPv6 traffic on VPC functions that are connected to dual-stack subnets.
- securityGroup List<String>Ids 
- A list of VPC security group IDs.
- subnetIds List<String>
- A list of VPC subnet IDs.
Tag, TagArgs  
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
We recommend new projects start with resources from the AWS provider.