skillfed

aws-lambda-typing

A package that provides type hints for AWS Lambda event, context and response objects

aws-lambda-typing v2.20.0 2.6M downloads/30d#2,980 on PyPI114
Permissive license MIT DORMANT released

What it is and what it does

aws-lambda-typing is a type-hints library for AWS Lambda handlers. It provides type annotations for event and context objects that Lambda passes to your handler function, plus response types for various Lambda integrations including API Gateway, SQS, DynamoDB Streams, S3, SNS, and others. The package does not enforce types at runtime—it exists purely to enable IDE autocomplete and static type checking in your development environment.

You import event and context types, annotate your handler function signature, and gain IDE support for accessing fields on those objects. The library covers a broad range of AWS services that can trigger Lambda functions, including ALB, API Gateway (v1 and v2), AppSync, CloudFormation, CloudWatch, CodeCommit, CodePipeline, Cognito, Config, DynamoDB Streams, EventBridge, Kinesis, MQ, MSK, S3, Secrets Manager, SES, SNS, and SQS, along with WebSocket route events.

Use it for:

  • Add IDE autocomplete and type checking to Lambda handler functions without runtime overhead.
  • Catch typos and incorrect field access in event and context objects before deployment.
  • Document the expected shape of Lambda events in your codebase through type annotations.
  • Enable refactoring tools and IDE navigation to safely trace usage of event fields across serverless code.
  • Validate handler signatures against AWS Lambda's event and context contracts during development.

Worth the install?

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

Provides type hints and IDE autocomplete for AWS Lambda event, context, and response objects to enable static type checking in serverless functions.

Yes, if you are writing typed Python Lambda handlers and want IDE support and static type checking. The library is stable, has no security vulnerabilities, and carries minimal install friction. However, maintenance is dormant (last release 864 days ago), so verify that type definitions cover your specific event sources before relying on them for critical validation.

Install

aws-lambda-typing on PyPI

pip

pip install aws-lambda-typing

uv

uv add aws-lambda-typing

poetry

poetry add aws-lambda-typing

Installing aws-lambda-typing

Before you install

Low install friction with a single lightweight dependency (typing-extensions). Maintenance is dormant—last release was 864 days ago—but the package is marked Production/Stable and the repository remains active with no archival.

License in practice

MIT license permits unrestricted use, modification, and distribution with minimal restrictions, making it safe for commercial and open-source projects.

Quickstart

pip install aws-lambda-typing

from aws_lambda_typing import context as context_, events

def handler(event: events.SQSEvent, context: context_.Context) -> None:
    for record in event['Records']:
        print(record['body'])
    print(context.get_remaining_time_in_millis())

Verify before relying

  • Whether type hints remain accurate for AWS Lambda event schemas and API changes since last release 864 days ago.
  • Coverage completeness for newer Lambda event sources or response types introduced after the last release date.

Package facts

License MIT (permissive)
Python support supports the current Python release (<4.0,>=3.6)
Install friction low — pure-Python wheel
Runtime dependencies 1 — typing-extensions
Maintenance dormant — 864 days since the last release
Last repo commit
First released
Downloads 2,591,290/month — #2,980 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: aws_lambda_typing-2.20.0-py3-none-any.whl

Keywords: typing, type hints, aws, lambda, serverless, development

Development Status :: 5 - Production/StableLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9

Tags

aws lambda type hintslambda event typingserverless function typesaws lambda autocompletelambda context typestype checking lambda handlers
aws-lambdatype-hintsserverless

More Software Development packages