1. Packages
  2. AWS
  3. API Docs
  4. lambda
  5. getFunctions
AWS v6.54.0 published on Friday, Sep 27, 2024 by Pulumi

aws.lambda.getFunctions

Explore with Pulumi AI

aws logo
AWS v6.54.0 published on Friday, Sep 27, 2024 by Pulumi

    Data resource to get a list of Lambda Functions.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const all = aws.lambda.getFunctions({});
    
    import pulumi
    import pulumi_aws as aws
    
    all = aws.lambda.get_functions()
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/lambda"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := lambda.GetFunctions(ctx, nil, nil)
    		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 all = Aws.Lambda.GetFunctions.Invoke();
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.lambda.LambdaFunctions;
    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 all = LambdaFunctions.getFunctions();
    
        }
    }
    
    variables:
      all:
        fn::invoke:
          Function: aws:lambda:getFunctions
          Arguments: {}
    

    Using getFunctions

    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 getFunctions(opts?: InvokeOptions): Promise<GetFunctionsResult>
    function getFunctionsOutput(opts?: InvokeOptions): Output<GetFunctionsResult>
    def get_functions(opts: Optional[InvokeOptions] = None) -> GetFunctionsResult
    def get_functions_output(opts: Optional[InvokeOptions] = None) -> Output[GetFunctionsResult]
    func GetFunctions(ctx *Context, opts ...InvokeOption) (*GetFunctionsResult, error)
    func GetFunctionsOutput(ctx *Context, opts ...InvokeOption) GetFunctionsResultOutput

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

    public static class GetFunctions 
    {
        public static Task<GetFunctionsResult> InvokeAsync(InvokeOptions? opts = null)
        public static Output<GetFunctionsResult> Invoke(InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetFunctionsResult> getFunctions(InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: aws:lambda/getFunctions:getFunctions
      arguments:
        # arguments dictionary

    getFunctions Result

    The following output properties are available:

    FunctionArns List<string>
    A list of Lambda Function ARNs.
    FunctionNames List<string>
    A list of Lambda Function names.
    Id string
    The provider-assigned unique ID for this managed resource.
    FunctionArns []string
    A list of Lambda Function ARNs.
    FunctionNames []string
    A list of Lambda Function names.
    Id string
    The provider-assigned unique ID for this managed resource.
    functionArns List<String>
    A list of Lambda Function ARNs.
    functionNames List<String>
    A list of Lambda Function names.
    id String
    The provider-assigned unique ID for this managed resource.
    functionArns string[]
    A list of Lambda Function ARNs.
    functionNames string[]
    A list of Lambda Function names.
    id string
    The provider-assigned unique ID for this managed resource.
    function_arns Sequence[str]
    A list of Lambda Function ARNs.
    function_names Sequence[str]
    A list of Lambda Function names.
    id str
    The provider-assigned unique ID for this managed resource.
    functionArns List<String>
    A list of Lambda Function ARNs.
    functionNames List<String>
    A list of Lambda Function names.
    id String
    The provider-assigned unique ID for this managed resource.

    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 v6.54.0 published on Friday, Sep 27, 2024 by Pulumi