1. Packages
  2. AWS
  3. API Docs
  4. lambda
  5. getLayerVersion
AWS v7.2.0 published on Thursday, Jul 31, 2025 by Pulumi

aws.lambda.getLayerVersion

Explore with Pulumi AI

aws logo
AWS v7.2.0 published on Thursday, Jul 31, 2025 by Pulumi

    Provides details about an AWS Lambda Layer Version. Use this data source to retrieve information about a specific layer version or find the latest version compatible with your runtime and architecture requirements.

    Example Usage

    Get Latest Layer Version

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = aws.lambda.getLayerVersion({
        layerName: "my-shared-utilities",
    });
    // Use the layer in a Lambda function
    const exampleFunction = new aws.lambda.Function("example", {
        code: new pulumi.asset.FileArchive("function.zip"),
        name: "example_function",
        role: lambdaRole.arn,
        handler: "index.handler",
        runtime: aws.lambda.Runtime.NodeJS20dX,
        layers: [example.then(example => example.arn)],
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.lambda.get_layer_version(layer_name="my-shared-utilities")
    # Use the layer in a Lambda function
    example_function = aws.lambda_.Function("example",
        code=pulumi.FileArchive("function.zip"),
        name="example_function",
        role=lambda_role["arn"],
        handler="index.handler",
        runtime=aws.lambda_.Runtime.NODE_JS20D_X,
        layers=[example.arn])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/lambda"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := lambda.LookupLayerVersion(ctx, &lambda.LookupLayerVersionArgs{
    			LayerName: "my-shared-utilities",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		// Use the layer in a Lambda function
    		_, err = lambda.NewFunction(ctx, "example", &lambda.FunctionArgs{
    			Code:    pulumi.NewFileArchive("function.zip"),
    			Name:    pulumi.String("example_function"),
    			Role:    pulumi.Any(lambdaRole.Arn),
    			Handler: pulumi.String("index.handler"),
    			Runtime: pulumi.String(lambda.RuntimeNodeJS20dX),
    			Layers: pulumi.StringArray{
    				pulumi.String(example.Arn),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Aws.Lambda.GetLayerVersion.Invoke(new()
        {
            LayerName = "my-shared-utilities",
        });
    
        // Use the layer in a Lambda function
        var exampleFunction = new Aws.Lambda.Function("example", new()
        {
            Code = new FileArchive("function.zip"),
            Name = "example_function",
            Role = lambdaRole.Arn,
            Handler = "index.handler",
            Runtime = Aws.Lambda.Runtime.NodeJS20dX,
            Layers = new[]
            {
                example.Apply(getLayerVersionResult => getLayerVersionResult.Arn),
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.lambda.LambdaFunctions;
    import com.pulumi.aws.lambda.inputs.GetLayerVersionArgs;
    import com.pulumi.aws.lambda.Function;
    import com.pulumi.aws.lambda.FunctionArgs;
    import com.pulumi.asset.FileArchive;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var example = LambdaFunctions.getLayerVersion(GetLayerVersionArgs.builder()
                .layerName("my-shared-utilities")
                .build());
    
            // Use the layer in a Lambda function
            var exampleFunction = new Function("exampleFunction", FunctionArgs.builder()
                .code(new FileArchive("function.zip"))
                .name("example_function")
                .role(lambdaRole.arn())
                .handler("index.handler")
                .runtime("nodejs20.x")
                .layers(example.arn())
                .build());
    
        }
    }
    
    resources:
      # Use the layer in a Lambda function
      exampleFunction:
        type: aws:lambda:Function
        name: example
        properties:
          code:
            fn::FileArchive: function.zip
          name: example_function
          role: ${lambdaRole.arn}
          handler: index.handler
          runtime: nodejs20.x
          layers:
            - ${example.arn}
    variables:
      example:
        fn::invoke:
          function: aws:lambda:getLayerVersion
          arguments:
            layerName: my-shared-utilities
    

    Get Specific Layer Version

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = aws.lambda.getLayerVersion({
        layerName: "production-utilities",
        version: 5,
    });
    export const layerInfo = {
        arn: example.then(example => example.arn),
        version: example.then(example => example.version),
        description: example.then(example => example.description),
    };
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.lambda.get_layer_version(layer_name="production-utilities",
        version=5)
    pulumi.export("layerInfo", {
        "arn": example.arn,
        "version": example.version,
        "description": example.description,
    })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/lambda"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := lambda.LookupLayerVersion(ctx, &lambda.LookupLayerVersionArgs{
    			LayerName: "production-utilities",
    			Version:   pulumi.IntRef(5),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("layerInfo", pulumi.Map{
    			"arn":         example.Arn,
    			"version":     example.Version,
    			"description": example.Description,
    		})
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Aws.Lambda.GetLayerVersion.Invoke(new()
        {
            LayerName = "production-utilities",
            Version = 5,
        });
    
        return new Dictionary<string, object?>
        {
            ["layerInfo"] = 
            {
                { "arn", example.Apply(getLayerVersionResult => getLayerVersionResult.Arn) },
                { "version", example.Apply(getLayerVersionResult => getLayerVersionResult.Version) },
                { "description", example.Apply(getLayerVersionResult => getLayerVersionResult.Description) },
            },
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.lambda.LambdaFunctions;
    import com.pulumi.aws.lambda.inputs.GetLayerVersionArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var example = LambdaFunctions.getLayerVersion(GetLayerVersionArgs.builder()
                .layerName("production-utilities")
                .version(5)
                .build());
    
            ctx.export("layerInfo", Map.ofEntries(
                Map.entry("arn", example.arn()),
                Map.entry("version", example.version()),
                Map.entry("description", example.description())
            ));
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: aws:lambda:getLayerVersion
          arguments:
            layerName: production-utilities
            version: 5
    outputs:
      layerInfo:
        arn: ${example.arn}
        version: ${example.version}
        description: ${example.description}
    

    Get Latest Compatible Layer Version

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    // Find latest layer version compatible with Python 3.12
    const pythonLayer = aws.lambda.getLayerVersion({
        layerName: "python-dependencies",
        compatibleRuntime: "python3.12",
    });
    // Find latest layer version compatible with ARM64 architecture
    const armLayer = aws.lambda.getLayerVersion({
        layerName: "optimized-libraries",
        compatibleArchitecture: "arm64",
    });
    // Use both layers in a function
    const example = new aws.lambda.Function("example", {
        code: new pulumi.asset.FileArchive("function.zip"),
        name: "multi_layer_function",
        role: lambdaRole.arn,
        handler: "app.handler",
        runtime: aws.lambda.Runtime.Python3d12,
        architectures: ["arm64"],
        layers: [
            pythonLayer.then(pythonLayer => pythonLayer.arn),
            armLayer.then(armLayer => armLayer.arn),
        ],
    });
    
    import pulumi
    import pulumi_aws as aws
    
    # Find latest layer version compatible with Python 3.12
    python_layer = aws.lambda.get_layer_version(layer_name="python-dependencies",
        compatible_runtime="python3.12")
    # Find latest layer version compatible with ARM64 architecture
    arm_layer = aws.lambda.get_layer_version(layer_name="optimized-libraries",
        compatible_architecture="arm64")
    # Use both layers in a function
    example = aws.lambda_.Function("example",
        code=pulumi.FileArchive("function.zip"),
        name="multi_layer_function",
        role=lambda_role["arn"],
        handler="app.handler",
        runtime=aws.lambda_.Runtime.PYTHON3D12,
        architectures=["arm64"],
        layers=[
            python_layer.arn,
            arm_layer.arn,
        ])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/lambda"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Find latest layer version compatible with Python 3.12
    		pythonLayer, err := lambda.LookupLayerVersion(ctx, &lambda.LookupLayerVersionArgs{
    			LayerName:         "python-dependencies",
    			CompatibleRuntime: pulumi.StringRef("python3.12"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		// Find latest layer version compatible with ARM64 architecture
    		armLayer, err := lambda.LookupLayerVersion(ctx, &lambda.LookupLayerVersionArgs{
    			LayerName:              "optimized-libraries",
    			CompatibleArchitecture: pulumi.StringRef("arm64"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		// Use both layers in a function
    		_, err = lambda.NewFunction(ctx, "example", &lambda.FunctionArgs{
    			Code:    pulumi.NewFileArchive("function.zip"),
    			Name:    pulumi.String("multi_layer_function"),
    			Role:    pulumi.Any(lambdaRole.Arn),
    			Handler: pulumi.String("app.handler"),
    			Runtime: pulumi.String(lambda.RuntimePython3d12),
    			Architectures: pulumi.StringArray{
    				pulumi.String("arm64"),
    			},
    			Layers: pulumi.StringArray{
    				pulumi.String(pythonLayer.Arn),
    				pulumi.String(armLayer.Arn),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        // Find latest layer version compatible with Python 3.12
        var pythonLayer = Aws.Lambda.GetLayerVersion.Invoke(new()
        {
            LayerName = "python-dependencies",
            CompatibleRuntime = "python3.12",
        });
    
        // Find latest layer version compatible with ARM64 architecture
        var armLayer = Aws.Lambda.GetLayerVersion.Invoke(new()
        {
            LayerName = "optimized-libraries",
            CompatibleArchitecture = "arm64",
        });
    
        // Use both layers in a function
        var example = new Aws.Lambda.Function("example", new()
        {
            Code = new FileArchive("function.zip"),
            Name = "multi_layer_function",
            Role = lambdaRole.Arn,
            Handler = "app.handler",
            Runtime = Aws.Lambda.Runtime.Python3d12,
            Architectures = new[]
            {
                "arm64",
            },
            Layers = new[]
            {
                pythonLayer.Apply(getLayerVersionResult => getLayerVersionResult.Arn),
                armLayer.Apply(getLayerVersionResult => getLayerVersionResult.Arn),
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.lambda.LambdaFunctions;
    import com.pulumi.aws.lambda.inputs.GetLayerVersionArgs;
    import com.pulumi.aws.lambda.Function;
    import com.pulumi.aws.lambda.FunctionArgs;
    import com.pulumi.asset.FileArchive;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            // Find latest layer version compatible with Python 3.12
            final var pythonLayer = LambdaFunctions.getLayerVersion(GetLayerVersionArgs.builder()
                .layerName("python-dependencies")
                .compatibleRuntime("python3.12")
                .build());
    
            // Find latest layer version compatible with ARM64 architecture
            final var armLayer = LambdaFunctions.getLayerVersion(GetLayerVersionArgs.builder()
                .layerName("optimized-libraries")
                .compatibleArchitecture("arm64")
                .build());
    
            // Use both layers in a function
            var example = new Function("example", FunctionArgs.builder()
                .code(new FileArchive("function.zip"))
                .name("multi_layer_function")
                .role(lambdaRole.arn())
                .handler("app.handler")
                .runtime("python3.12")
                .architectures("arm64")
                .layers(            
                    pythonLayer.arn(),
                    armLayer.arn())
                .build());
    
        }
    }
    
    resources:
      # Use both layers in a function
      example:
        type: aws:lambda:Function
        properties:
          code:
            fn::FileArchive: function.zip
          name: multi_layer_function
          role: ${lambdaRole.arn}
          handler: app.handler
          runtime: python3.12
          architectures:
            - arm64
          layers:
            - ${pythonLayer.arn}
            - ${armLayer.arn}
    variables:
      # Find latest layer version compatible with Python 3.12
      pythonLayer:
        fn::invoke:
          function: aws:lambda:getLayerVersion
          arguments:
            layerName: python-dependencies
            compatibleRuntime: python3.12
      # Find latest layer version compatible with ARM64 architecture
      armLayer:
        fn::invoke:
          function: aws:lambda:getLayerVersion
          arguments:
            layerName: optimized-libraries
            compatibleArchitecture: arm64
    

    Compare Layer Versions

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    // Get latest version
    const latest = aws.lambda.getLayerVersion({
        layerName: "shared-layer",
    });
    // Get specific version for comparison
    const stable = aws.lambda.getLayerVersion({
        layerName: "shared-layer",
        version: 3,
    });
    const useLatestLayer = latest.then(latest => latest.version > 5);
    const selectedLayer = useLatestLayer ? latest.then(latest => latest.arn) : stable.then(stable => stable.arn);
    export const selectedLayerVersion = useLatestLayer ? latest.then(latest => latest.version) : stable.then(stable => stable.version);
    
    import pulumi
    import pulumi_aws as aws
    
    # Get latest version
    latest = aws.lambda.get_layer_version(layer_name="shared-layer")
    # Get specific version for comparison
    stable = aws.lambda.get_layer_version(layer_name="shared-layer",
        version=3)
    use_latest_layer = latest.version > 5
    selected_layer = latest.arn if use_latest_layer else stable.arn
    pulumi.export("selectedLayerVersion", latest.version if use_latest_layer else stable.version)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/lambda"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Get latest version
    		latest, err := lambda.LookupLayerVersion(ctx, &lambda.LookupLayerVersionArgs{
    			LayerName: "shared-layer",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		// Get specific version for comparison
    		stable, err := lambda.LookupLayerVersion(ctx, &lambda.LookupLayerVersionArgs{
    			LayerName: "shared-layer",
    			Version:   pulumi.IntRef(3),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		useLatestLayer := latest.Version > 5
    		var tmp0 *string
    		if useLatestLayer {
    			tmp0 = latest.Arn
    		} else {
    			tmp0 = stable.Arn
    		}
    		_ := tmp0
    		var tmp1 *int
    		if useLatestLayer {
    			tmp1 = latest.Version
    		} else {
    			tmp1 = stable.Version
    		}
    		ctx.Export("selectedLayerVersion", tmp1)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        // Get latest version
        var latest = Aws.Lambda.GetLayerVersion.Invoke(new()
        {
            LayerName = "shared-layer",
        });
    
        // Get specific version for comparison
        var stable = Aws.Lambda.GetLayerVersion.Invoke(new()
        {
            LayerName = "shared-layer",
            Version = 3,
        });
    
        var useLatestLayer = latest.Apply(getLayerVersionResult => getLayerVersionResult.Version) > 5;
    
        var selectedLayer = useLatestLayer ? latest.Apply(getLayerVersionResult => getLayerVersionResult.Arn) : stable.Apply(getLayerVersionResult => getLayerVersionResult.Arn);
    
        return new Dictionary<string, object?>
        {
            ["selectedLayerVersion"] = useLatestLayer ? latest.Apply(getLayerVersionResult => getLayerVersionResult.Version) : stable.Apply(getLayerVersionResult => getLayerVersionResult.Version),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.lambda.LambdaFunctions;
    import com.pulumi.aws.lambda.inputs.GetLayerVersionArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            // Get latest version
            final var latest = LambdaFunctions.getLayerVersion(GetLayerVersionArgs.builder()
                .layerName("shared-layer")
                .build());
    
            // Get specific version for comparison
            final var stable = LambdaFunctions.getLayerVersion(GetLayerVersionArgs.builder()
                .layerName("shared-layer")
                .version(3)
                .build());
    
            final var useLatestLayer = latest.version() > 5;
    
            final var selectedLayer = useLatestLayer ? latest.arn() : stable.arn();
    
            ctx.export("selectedLayerVersion", useLatestLayer ? latest.version() : stable.version());
        }
    }
    
    Example coming soon!
    

    Using getLayerVersion

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getLayerVersion(args: GetLayerVersionArgs, opts?: InvokeOptions): Promise<GetLayerVersionResult>
    function getLayerVersionOutput(args: GetLayerVersionOutputArgs, opts?: InvokeOptions): Output<GetLayerVersionResult>
    def get_layer_version(compatible_architecture: Optional[str] = None,
                          compatible_runtime: Optional[str] = None,
                          layer_name: Optional[str] = None,
                          region: Optional[str] = None,
                          version: Optional[int] = None,
                          opts: Optional[InvokeOptions] = None) -> GetLayerVersionResult
    def get_layer_version_output(compatible_architecture: Optional[pulumi.Input[str]] = None,
                          compatible_runtime: Optional[pulumi.Input[str]] = None,
                          layer_name: Optional[pulumi.Input[str]] = None,
                          region: Optional[pulumi.Input[str]] = None,
                          version: Optional[pulumi.Input[int]] = None,
                          opts: Optional[InvokeOptions] = None) -> Output[GetLayerVersionResult]
    func LookupLayerVersion(ctx *Context, args *LookupLayerVersionArgs, opts ...InvokeOption) (*LookupLayerVersionResult, error)
    func LookupLayerVersionOutput(ctx *Context, args *LookupLayerVersionOutputArgs, opts ...InvokeOption) LookupLayerVersionResultOutput

    > Note: This function is named LookupLayerVersion in the Go SDK.

    public static class GetLayerVersion 
    {
        public static Task<GetLayerVersionResult> InvokeAsync(GetLayerVersionArgs args, InvokeOptions? opts = null)
        public static Output<GetLayerVersionResult> Invoke(GetLayerVersionInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetLayerVersionResult> getLayerVersion(GetLayerVersionArgs args, InvokeOptions options)
    public static Output<GetLayerVersionResult> getLayerVersion(GetLayerVersionArgs args, InvokeOptions options)
    
    fn::invoke:
      function: aws:lambda/getLayerVersion:getLayerVersion
      arguments:
        # arguments dictionary

    The following arguments are supported:

    LayerName string

    Name of the Lambda layer.

    The following arguments are optional:

    CompatibleArchitecture string
    Specific architecture the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided architecture will be used.
    CompatibleRuntime string
    Specific runtime the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided runtime will be used.
    Region string
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    Version int
    Specific layer version. Conflicts with compatible_runtime and compatible_architecture. If omitted, the latest available layer version will be used.
    LayerName string

    Name of the Lambda layer.

    The following arguments are optional:

    CompatibleArchitecture string
    Specific architecture the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided architecture will be used.
    CompatibleRuntime string
    Specific runtime the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided runtime will be used.
    Region string
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    Version int
    Specific layer version. Conflicts with compatible_runtime and compatible_architecture. If omitted, the latest available layer version will be used.
    layerName String

    Name of the Lambda layer.

    The following arguments are optional:

    compatibleArchitecture String
    Specific architecture the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided architecture will be used.
    compatibleRuntime String
    Specific runtime the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided runtime will be used.
    region String
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    version Integer
    Specific layer version. Conflicts with compatible_runtime and compatible_architecture. If omitted, the latest available layer version will be used.
    layerName string

    Name of the Lambda layer.

    The following arguments are optional:

    compatibleArchitecture string
    Specific architecture the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided architecture will be used.
    compatibleRuntime string
    Specific runtime the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided runtime will be used.
    region string
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    version number
    Specific layer version. Conflicts with compatible_runtime and compatible_architecture. If omitted, the latest available layer version will be used.
    layer_name str

    Name of the Lambda layer.

    The following arguments are optional:

    compatible_architecture str
    Specific architecture the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided architecture will be used.
    compatible_runtime str
    Specific runtime the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided runtime will be used.
    region str
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    version int
    Specific layer version. Conflicts with compatible_runtime and compatible_architecture. If omitted, the latest available layer version will be used.
    layerName String

    Name of the Lambda layer.

    The following arguments are optional:

    compatibleArchitecture String
    Specific architecture the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided architecture will be used.
    compatibleRuntime String
    Specific runtime the layer version must support. Conflicts with version. If specified, the latest available layer version supporting the provided runtime will be used.
    region String
    Region where this resource will be managed. Defaults to the Region set in the provider configuration.
    version Number
    Specific layer version. Conflicts with compatible_runtime and compatible_architecture. If omitted, the latest available layer version will be used.

    getLayerVersion Result

    The following output properties are available:

    Arn string
    ARN of the Lambda Layer with version.
    CodeSha256 string
    Base64-encoded representation of raw SHA-256 sum of the zip file.
    CompatibleArchitectures List<string>
    List of Architectures the specific Lambda Layer version is compatible with.
    CompatibleRuntimes List<string>
    List of Runtimes the specific Lambda Layer version is compatible with.
    CreatedDate string
    Date this resource was created.
    Description string
    Description of the specific Lambda Layer version.
    Id string
    The provider-assigned unique ID for this managed resource.
    LayerArn string
    ARN of the Lambda Layer without version.
    LayerName string
    LicenseInfo string
    License info associated with the specific Lambda Layer version.
    Region string
    SigningJobArn string
    ARN of a signing job.
    SigningProfileVersionArn string
    ARN for a signing profile version.
    SourceCodeHash string
    (Deprecated use code_sha256 instead) Base64-encoded representation of raw SHA-256 sum of the zip file.

    Deprecated: source_code_hash is deprecated. Use code_sha256 instead.

    SourceCodeSize int
    Size in bytes of the function .zip file.
    Version int
    Lambda Layer version.
    CompatibleArchitecture string
    CompatibleRuntime string
    Arn string
    ARN of the Lambda Layer with version.
    CodeSha256 string
    Base64-encoded representation of raw SHA-256 sum of the zip file.
    CompatibleArchitectures []string
    List of Architectures the specific Lambda Layer version is compatible with.
    CompatibleRuntimes []string
    List of Runtimes the specific Lambda Layer version is compatible with.
    CreatedDate string
    Date this resource was created.
    Description string
    Description of the specific Lambda Layer version.
    Id string
    The provider-assigned unique ID for this managed resource.
    LayerArn string
    ARN of the Lambda Layer without version.
    LayerName string
    LicenseInfo string
    License info associated with the specific Lambda Layer version.
    Region string
    SigningJobArn string
    ARN of a signing job.
    SigningProfileVersionArn string
    ARN for a signing profile version.
    SourceCodeHash string
    (Deprecated use code_sha256 instead) Base64-encoded representation of raw SHA-256 sum of the zip file.

    Deprecated: source_code_hash is deprecated. Use code_sha256 instead.

    SourceCodeSize int
    Size in bytes of the function .zip file.
    Version int
    Lambda Layer version.
    CompatibleArchitecture string
    CompatibleRuntime string
    arn String
    ARN of the Lambda Layer with version.
    codeSha256 String
    Base64-encoded representation of raw SHA-256 sum of the zip file.
    compatibleArchitectures List<String>
    List of Architectures the specific Lambda Layer version is compatible with.
    compatibleRuntimes List<String>
    List of Runtimes the specific Lambda Layer version is compatible with.
    createdDate String
    Date this resource was created.
    description String
    Description of the specific Lambda Layer version.
    id String
    The provider-assigned unique ID for this managed resource.
    layerArn String
    ARN of the Lambda Layer without version.
    layerName String
    licenseInfo String
    License info associated with the specific Lambda Layer version.
    region String
    signingJobArn String
    ARN of a signing job.
    signingProfileVersionArn String
    ARN for a signing profile version.
    sourceCodeHash String
    (Deprecated use code_sha256 instead) Base64-encoded representation of raw SHA-256 sum of the zip file.

    Deprecated: source_code_hash is deprecated. Use code_sha256 instead.

    sourceCodeSize Integer
    Size in bytes of the function .zip file.
    version Integer
    Lambda Layer version.
    compatibleArchitecture String
    compatibleRuntime String
    arn string
    ARN of the Lambda Layer with version.
    codeSha256 string
    Base64-encoded representation of raw SHA-256 sum of the zip file.
    compatibleArchitectures string[]
    List of Architectures the specific Lambda Layer version is compatible with.
    compatibleRuntimes string[]
    List of Runtimes the specific Lambda Layer version is compatible with.
    createdDate string
    Date this resource was created.
    description string
    Description of the specific Lambda Layer version.
    id string
    The provider-assigned unique ID for this managed resource.
    layerArn string
    ARN of the Lambda Layer without version.
    layerName string
    licenseInfo string
    License info associated with the specific Lambda Layer version.
    region string
    signingJobArn string
    ARN of a signing job.
    signingProfileVersionArn string
    ARN for a signing profile version.
    sourceCodeHash string
    (Deprecated use code_sha256 instead) Base64-encoded representation of raw SHA-256 sum of the zip file.

    Deprecated: source_code_hash is deprecated. Use code_sha256 instead.

    sourceCodeSize number
    Size in bytes of the function .zip file.
    version number
    Lambda Layer version.
    compatibleArchitecture string
    compatibleRuntime string
    arn str
    ARN of the Lambda Layer with version.
    code_sha256 str
    Base64-encoded representation of raw SHA-256 sum of the zip file.
    compatible_architectures Sequence[str]
    List of Architectures the specific Lambda Layer version is compatible with.
    compatible_runtimes Sequence[str]
    List of Runtimes the specific Lambda Layer version is compatible with.
    created_date str
    Date this resource was created.
    description str
    Description of the specific Lambda Layer version.
    id str
    The provider-assigned unique ID for this managed resource.
    layer_arn str
    ARN of the Lambda Layer without version.
    layer_name str
    license_info str
    License info associated with the specific Lambda Layer version.
    region str
    signing_job_arn str
    ARN of a signing job.
    signing_profile_version_arn str
    ARN for a signing profile version.
    source_code_hash str
    (Deprecated use code_sha256 instead) Base64-encoded representation of raw SHA-256 sum of the zip file.

    Deprecated: source_code_hash is deprecated. Use code_sha256 instead.

    source_code_size int
    Size in bytes of the function .zip file.
    version int
    Lambda Layer version.
    compatible_architecture str
    compatible_runtime str
    arn String
    ARN of the Lambda Layer with version.
    codeSha256 String
    Base64-encoded representation of raw SHA-256 sum of the zip file.
    compatibleArchitectures List<String>
    List of Architectures the specific Lambda Layer version is compatible with.
    compatibleRuntimes List<String>
    List of Runtimes the specific Lambda Layer version is compatible with.
    createdDate String
    Date this resource was created.
    description String
    Description of the specific Lambda Layer version.
    id String
    The provider-assigned unique ID for this managed resource.
    layerArn String
    ARN of the Lambda Layer without version.
    layerName String
    licenseInfo String
    License info associated with the specific Lambda Layer version.
    region String
    signingJobArn String
    ARN of a signing job.
    signingProfileVersionArn String
    ARN for a signing profile version.
    sourceCodeHash String
    (Deprecated use code_sha256 instead) Base64-encoded representation of raw SHA-256 sum of the zip file.

    Deprecated: source_code_hash is deprecated. Use code_sha256 instead.

    sourceCodeSize Number
    Size in bytes of the function .zip file.
    version Number
    Lambda Layer version.
    compatibleArchitecture String
    compatibleRuntime String

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo
    AWS v7.2.0 published on Thursday, Jul 31, 2025 by Pulumi