skillfed

aws-sam-cli

AWS SAM CLI is a CLI tool for local development and testing of Serverless applications

aws-sam-cli v1.165.0 2.3M downloads/30d#3,113 on PyPI6,728
Permissive license Apache-2.0 Active released

What it is and what it does

AWS SAM CLI is the command-line interface for the AWS Serverless Application Model, a framework that simplifies building and deploying serverless applications on AWS. It provides local development and testing environments where you can build Lambda functions, test API Gateway endpoints, and emulate AWS services in Docker containers before deploying to the cloud. The tool handles initialization of new projects from templates, compilation and packaging of functions, local execution with CloudWatch log tailing, and deployment via CloudFormation.

The package integrates with 24 runtime dependencies including boto3 for AWS API access, Docker for local Lambda emulation, Flask for local API testing, and various utilities for YAML parsing, templating, and schema validation. It targets developers building serverless applications and supports modern Python versions from 3.10 onward. The tool is actively maintained by AWS with frequent releases and a large community presence.

Use it for:

  • Initialize and scaffold new serverless projects with predefined AWS templates using sam init.
  • Build and locally test Lambda functions and API Gateway endpoints in a Docker container before cloud deployment.
  • Deploy SAM and CloudFormation templates to AWS with sam deploy for rapid iteration.
  • Sync and test incremental changes in cloud developer environments with sam sync.
  • Tail CloudWatch logs and X-Ray traces from deployed serverless applications using sam logs and sam traces.
  • Generate CI/CD pipeline templates for popular systems with sam pipeline init.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

AWS SAM CLI is a command-line tool for building, testing, and deploying serverless applications with Lambda, API Gateway, Step Functions, and related AWS services locally and to the cloud.

Yes. AWS SAM CLI is production-stable, actively maintained, has no known vulnerabilities, and low install friction. It is the standard tool for local serverless development on AWS and essential for teams building Lambda-based applications. The Apache-2.0 license poses no restrictions. Install it if you develop serverless applications on AWS.

Install

aws-sam-cli on PyPI

pip

pip install aws-sam-cli

uv

uv add aws-sam-cli

poetry

poetry add aws-sam-cli

Installing aws-sam-cli

Before you install

Low install friction with a pure-Python wheel. Actively maintained with a release 14 days ago and 6728 repository stars. Supports current Python versions (3.10–3.14) and has no known vulnerabilities.

License in practice

Apache-2.0 permissive license allows commercial and private use with minimal restrictions, making it suitable for both open-source and proprietary serverless projects.

Quickstart

pip install aws-sam-cli
sam init
sam build
sam local start-api

Requires Docker to run Lambda functions locally; AWS credentials configured for cloud deployment.

Verify before relying

  • Whether all 24 runtime dependencies are required for basic use or if some are optional for specific features.
  • Performance characteristics when testing large or complex serverless applications locally.

Package facts

License Apache-2.0 (permissive)
Python support supports the current Python release (>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 24 — chevron, click, Flask, boto3, jmespath, ruamel_yaml, PyYAML, cookiecutter, aws-sam-translator, docker, dateparser, requests, aws_lambda_builders, tomlkit, watchdog, rich, pyopenssl, jsonschema, typing_extensions, regex, tzlocal, cfn-lint, boto3-stubs, python-dotenv
Maintenance actively maintained — 14 days since the last release
Last repo commit
First released
Downloads 2,349,967/month — #3,113 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: aws_sam_cli-1.165.0-py3-none-any.whl

Keywords: AWS, SAM, CLI

Development Status :: 5 - Production/StableEnvironment :: ConsoleEnvironment :: Other EnvironmentIntended Audience :: DevelopersIntended Audience :: Information TechnologyOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: InternetTopic :: Software Development :: Build ToolsTopic :: Utilities

Tags

serverless application developmentlambda local testingAWS SAM CLIserverless build and deploycloudformation serverless templateslambda function developmentlocal serverless emulation
aws-serverlesslambda-developmentinfrastructure-as-code

More Internet packages