Skip to main content

Powertools for AWS Lambda (Python)

Build codecov.io PythonSupport PyPI version PyPi monthly downloads OpenSSF Scorecard Discord

Powertools for AWS Lambda (Python) is a developer toolkit to implement Serverless best practices and increase developer velocity.

Also available in Java, TypeScript, and .NET.

� Doccumentation | 🐍 PyPi | 🗺️ Roadmap | 📰 Blog

hero-image

Features

Core utilities such as Tracing, Logging, Metrics, and Event Handler are available across all Powertools for AWS Lambda languages. Additional utilities are subjective to each language ecosystem and customer demand.

  • Tracing - Decorators and utilities to trace Lambda function handlers, and both synchronous and asynchronous functions
  • Logging - Structured logging made easier, and target to enrich structured logging with key Lambda context details
  • Metrics - Custom Metrics created asynchronously via CloudWatch Embedded Metric Format (EMF)
  • Event handler: AppSync - AppSync event handler for Lambda Direct Resolver and Amplify GraphQL Transformer function
  • Event handler: AppSync Events - AppSync Events handler for real-time WebSocket APIs with pub/sub pattern
  • Event handler: API Gateway, ALB, Lambda Function URL, VPC Lattice - REST/HTTP API event handler for Lambda functions invoked via Amazon API Gateway, ALB, Lambda Function URL, and VPC Lattice
  • Event handler: Agents for Amazon Bedrock - Create Agents for Amazon Bedrock, automatically generating OpenAPI schemas
  • Middleware factory - Decorator factory to create your own middleware to run logic before, and after each Lambda invocation
  • Parameters - Retrieve and cache parameter values from Parameter Store, Secrets Manager, AppConfig, or DynamoDB
  • Batch processing - Handle partial failures for AWS SQS, Kinesis Data Streams, and DynamoDB Streams batch processing
  • Typing - Static typing classes to speedup development in your IDE
  • Validation - JSON Schema validator for inbound events and responses
  • Event source data classes - Data classes describing the schema of common Lambda event triggers
  • Parser - Data parsing and deep validation using Pydantic
  • Idempotency - Convert your Lambda functions into idempotent operations which are safe to retry
  • Data Masking - Protect confidential data with easy removal or encryption
  • Feature Flags - A simple rule engine to evaluate when one or multiple features should be enabled depending on the input
  • Streaming - Streams datasets larger than the available memory as streaming data
  • Kafka - Deserialize and validate Kafka events with support for Avro, Protocol Buffers, and JSON Schema
  • JMESPath Functions - Built-in JMESPath functions to easily deserialize common encoded JSON payloads in Lambda functions

Installation

With pip installed, run: pip install aws-lambda-powertools

Tutorial and Examples

How to support Powertools for AWS Lambda (Python)?

Becoming a reference customer

Knowing which companies are using this library is important to help prioritize the project internally. If your company is using Powertools for AWS Lambda (Python), you can request to have your name and logo added to the README file by raising a Support Powertools for AWS Lambda (Python) (become a reference) issue.

The following companies, among others, use Powertools:

Sharing your work

Share what you did with Powertools for AWS Lambda (Python) 💞💞. Blog post, workshops, presentation, sample apps and others. Check out what the community has already shared about Powertools for AWS Lambda (Python) in this link.

Using Lambda Layer or SAR

This helps us understand who uses Powertools for AWS Lambda (Python) in a non-intrusive way, and helps us gain future investments for other Powertools for AWS Lambda languages. When using Layers, you can add Powertools for AWS Lambda (Python) as a dev dependency (or as part of your virtual env) to not impact the development process.

Credits

Connect

Security disclosures

If you think you’ve found a potential security issue, please do not post it in the Issues. Instead, please follow the instructions in this link or email AWS security directly.

License

This library is licensed under the MIT-0 License. See the LICENSE file.

Release files for aws-lambda-powertools 3.35.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aws-lambda-powertools 3.35.0
File Size Uploaded
aws_lambda_powertools-3.35.0.tar.gz 803.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for aws-lambda-powertools 3.35.0
File Interpreter ABI Platform
aws_lambda_powertools-3.35.0-py3-none-any.whl Python 3 none any Details

Total release size: 1.8 MB

Release files / aws_lambda_powertools-3.35.0.tar.gz

Download URL aws_lambda_powertools-3.35.0.tar.gz
Size 803.0 kB
Tags Source
SHA-256 checksum
How to use checksums
27c1c7d7920f214a68a11505dca33ce3709a38c4b79f5fbc94141ec0af92c9f8
BLAKE2b-256 checksum
How to use checksums
a95b9b36aa010e686bbe0a8bfb7367430994254a68d1e8c2383af7b3264c6ebb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 15, 2026.

Transparency log

Release files / aws_lambda_powertools-3.35.0-py3-none-any.whl

Download URL aws_lambda_powertools-3.35.0-py3-none-any.whl
Size 960.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e8fbc27d74272fb99cbec67305250e825d1630dceb2dbfdcf5908dc9c4c82dcf
BLAKE2b-256 checksum
How to use checksums
c76e2a2764dd3fef758e8bde3ec5c0fb6e2ceeace2a873ca5def30b6c69a7bcf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 15, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

3.35.0 This release

2 release files

3.34.0

2 release files

3.31.1

2 release files

3.31.0

2 release files

3.30.0

2 release files

3.28.0

2 release files

3.26.0

2 release files

3.23.0

2 release files

3.22.0

2 release files

3.19.0

2 release files

3.18.0

2 release files

3.17.0

2 release files

3.15.1

2 release files

3.15.0

2 release files

3.13.0

2 release files

3.11.0

2 release files

3.9.0

2 release files

3.8.0

2 release files

3.7.0

2 release files

3.6.0

2 release files

3.5.0

2 release files

3.4.1

2 release files

3.4.0

2 release files

3.3.0

2 release files

3.2.0

2 release files

3.1.0

2 release files

3.0.0

2 release files

2.43.1

2 release files

2.42.0

2 release files

2.41.0

2 release files

2.40.1

2 release files

2.40.0

2 release files

2.39.1

2 release files

2.39.0

2 release files

2.38.1

2 release files

2.38.0

2 release files

2.37.0

2 release files

2.36.0

2 release files

2.34.2

2 release files

2.34.1

2 release files

2.34.0

2 release files

2.32.0

2 release files

2.30.2

2 release files

2.30.1

2 release files

2.30.0

2 release files

2.29.1

2 release files

2.28.1

2 release files

2.28.0

2 release files

2.27.1

2 release files

2.27.0

2 release files

2.26.1

2 release files

2.26.0

2 release files

2.25.1

2 release files

2.25.0

2 release files

2.23.1

2 release files

2.23.0

2 release files

2.22.0

2 release files

2.21.0

2 release files

2.20.0

2 release files

2.19.0

2 release files

2.18.0

2 release files

2.17.0

2 release files

2.14.1

2 release files

2.14.0

2 release files

2.13.0

2 release files

2.11.0

2 release files

2.10.0

2 release files

2.9.1

2 release files

2.9.0

2 release files

2.8.0

2 release files

2.7.1

2 release files

2.7.0

2 release files

2.6.0

2 release files

2.5.0

2 release files

2.4.0

2 release files

2.3.1

2 release files

2.3.0

2 release files

2.2.0

2 release files

2.1.0

2 release files

2.0.0

2 release files

1.31.1

2 release files

1.31.0

2 release files

1.29.2

2 release files

1.29.1

2 release files

1.29.0

2 release files

1.28.0

2 release files

1.26.7

2 release files

1.26.6

2 release files

1.26.5

2 release files

1.26.4

2 release files

1.26.2

2 release files

1.26.0

2 release files

1.25.9

2 release files

1.25.8

2 release files

1.25.5

2 release files

1.25.4

2 release files

1.25.1

2 release files

1.24.2

2 release files

1.24.1

2 release files

1.24.0

2 release files

1.23.0

2 release files

1.22.0

2 release files

1.20.1

2 release files

1.20.0

2 release files

1.19.0

2 release files

1.18.1

2 release files

1.18.0

2 release files

1.16.1

2 release files

1.16.0

2 release files

1.15.1

2 release files

1.13.0

2 release files

1.12.0

2 release files

1.10.5

2 release files

1.10.4

2 release files

1.10.3

2 release files

1.10.1

2 release files

1.10.0

2 release files

1.9.1

2 release files

1.9.0

2 release files

1.8.0

2 release files

1.7.0

2 release files

1.6.1

2 release files

1.6.0

2 release files

1.5.0

2 release files

1.4.0

2 release files

1.3.1

2 release files

1.3.0

2 release files

1.2.0

2 release files

1.1.3

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.11.0

2 release files

0.10.1

2 release files

0.9.5

2 release files

0.9.4

2 release files

0.9.3

2 release files

0.9.2

2 release files

0.9.1

2 release files

0.9.0

2 release files

0.8.1

2 release files

0.8.0

2 release files

0.7.0

2 release files

0.6.3

2 release files

0.6.2

2 release files

0.6.1

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page