Search code examples
amazon-web-servicesamazon-s3aws-lambdas3-bucket

AWS- AWS command to view lambda function in Command Line


My Lambda function code can't be viewed in the AWS Console due to an error with the file being too large. Is there an AWS command to pull the Lambda function code and view it in the command line?

Or, can I push my lambda code onto an S3 bucket, then download it from there to view it? Is there a command for that?


Solution

  • Download the Lambda function code from the AWS console, or use the AWSCLI as follows:

    aws lambda get-function --function-name xyz --region <region>
    

    This will return a presigned URL link to the .zip file containing your Lambda function.