Use the AWS Serverless Application Model Command Line Interface (AWS SAM CLI) within your Terraform projects to perform local debugging and testing of your AWS Lambda functions and layers.
Topics
Local debugging and testing with AWS SAM CLI
How the AWS SAM CLI interacts with your Terraform projects
Benefits of AWS SAM CLI Terraform support