Your first serverless app (using the AWS SAM)
In the section above Your first Serverless app using AWS console, we looked at how to create, update, deploy, and test AWS Lambda functions through the AWS Console. However, when you are part of a larger team and want to make your AWS Lambda functions production-ready, you will typically be working on your AWS Lambda functions from your local development environment, using certain tools such as the AWS SAM to deploy your AWS Lambda functions to an AWS environment. For this section, we will be using Visual Studio Code (installation instructions are in Chapter 2, Development Environment, Tools, and SDKs ) to write the code for your AWS Lambda function, and the AWS SAM to test and deploy the AWS Lambda function to an AWS environment from your workstation.
Creating a function
Before we start writing code in the Visual Studio Code editor, let's create a working directory on your workstation, where we will be creating the source code files.
If you are...