skillfed

aws-cdk.aws-apigateway

The CDK Construct Library for AWS::ApiGateway

aws-cdk-aws-apigateway v1.204.0 159.5K downloads/30d#10,694 on PyPI12,868
Permissive license Apache-2.0 Active released

What it is and what it does

This package is the AWS CDK v1 construct library for Amazon API Gateway, a managed service for publishing and securing APIs at scale. It provides high-level Python classes to define REST APIs as infrastructure code, with built-in support for common backend integrations (Lambda functions, Step Functions state machines), authorization patterns (IAM, Lambda-based, Cognito), and operational features like access logging, CORS, and custom domains.

The library abstracts CloudFormation resource creation, allowing developers to define API hierarchies (resources and methods) programmatically and deploy them alongside other AWS infrastructure. However, the package reached end-of-support on 2023-06-01; AWS recommends migrating to AWS CDK v2 for continued updates and support.

Use it for:

  • Define a REST API backed by Lambda functions using LambdaRestApi construct for serverless application endpoints.
  • Build synchronous Step Functions workflows exposed as HTTP APIs using StepFunctionsRestApi for orchestrated backend logic.
  • Configure API authorization with Cognito User Pools, IAM roles, or custom Lambda authorizers for access control.
  • Set up custom domain names, SSL certificates, and access logging for production API deployments.
  • Break large APIs across multiple CloudFormation stacks to work around resource limits while maintaining a unified API structure.

Worth the install?

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

Provides AWS CDK constructs for defining and deploying Amazon API Gateway REST APIs, including Lambda and Step Functions integrations, authorizers, and deployment configuration.

No—this is AWS CDK v1, which reached end-of-support on 2023-06-01. While the package itself has low install friction and no known vulnerabilities, AWS explicitly recommends migration to AWS CDK v2. Install only if you are maintaining an existing v1 codebase; for new projects, use aws-cdk.aws-apigateway v2 instead.

Install

aws-cdk-aws-apigateway on PyPI

pip

pip install aws-cdk-aws-apigateway

uv

uv add aws-cdk-aws-apigateway

poetry

poetry add aws-cdk-aws-apigateway

Installing aws-cdk.aws-apigateway

Before you install

Low install friction with a wheel distribution. Package is actively maintained in the repository (last commit 2026-08-14), though it is classified as Development Status :: 7 - Inactive and reached end-of-support on 2023-06-01; users should migrate to AWS CDK v2.

License in practice

Licensed under Apache-2.0 (permissive), allowing commercial use, modification, and distribution with minimal restrictions.

Quickstart

from aws_cdk import aws_apigateway as apigateway
from aws_cdk import aws_lambda as lambda_

api = apigateway.RestApi(self, "books-api")
books = api.root.add_resource("books")
books.add_method("GET")

# Or with Lambda backend:
backend = lambda_.Function(...)
apigateway.LambdaRestApi(self, "myapi", handler=backend)

Requires AWS CDK v1 environment; package is end-of-support as of 2023-06-01 and migration to AWS CDK v2 is recommended.

Verify before relying

  • Whether existing v1 deployments remain functional despite end-of-support status and what breaking changes may occur in AWS infrastructure.
  • Performance characteristics and limits when handling high-volume API traffic through the constructs provided.

Package facts

License Apache-2.0 (permissive)
Python support supports the current Python release (~=3.7)
Install friction low — pure-Python wheel
Runtime dependencies 17 — aws-cdk.aws-certificatemanager, aws-cdk.aws-cloudwatch, aws-cdk.aws-cognito, aws-cdk.aws-ec2, aws-cdk.aws-elasticloadbalancingv2, aws-cdk.aws-iam, aws-cdk.aws-lambda, aws-cdk.aws-logs, aws-cdk.aws-s3-assets, aws-cdk.aws-s3, aws-cdk.aws-stepfunctions, aws-cdk.core, aws-cdk.cx-api, constructs, jsii, publication, typeguard
Maintenance actively maintained — 1,152 days since the last release
Last repo commit
First released
Downloads 159,503/month — #10,694 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: aws_cdk.aws_apigateway-1.204.0-py3-none-any.whl

Development Status :: 7 - InactiveFramework :: AWS CDKFramework :: AWS CDK :: 1Intended Audience :: DevelopersLicense :: OSI ApprovedOperating System :: OS IndependentProgramming Language :: JavaScriptProgramming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Typing :: Typed

Tags

api gateway cdk constructrest api infrastructure as codelambda api gateway integrationaws cdk api deploymentserverless api definitionstep functions api gatewayapi gateway authorizers cdk
aws-cdkinfrastructure-as-codeend-of-life

More Build Tools packages

packaging

Provides reusable utilities for Python…

permissive · top 100 on PyPI

tqdm

Wraps any iterable to display a real-time…

copyleft · top 100 on PyPI

pip

pip is the standard installer for Python…

permissive · top 100 on PyPI

hatchling

Hatchling is a standards-compliant Python build…

permissive · top 100 on PyPI

grpcio-tools

Generates Python gRPC service stubs and message…

permissive · top 1,000 on PyPI

pre-commit

pre-commit is a framework for installing and…

permissive · top 1,000 on PyPI

aws-cdk.aws-imagebuilder

Provides AWS CDK L1 constructs for defining and…

permissive · top 15,000 on PyPI

aws-cdk.aws-stepfunctions

Provides Python constructs for defining AWS…

permissive · top 15,000 on PyPI

aws-cdk.core

Provides the core construct classes and stack…

permissive · top 15,000 on PyPI

aws-cdk.aws-cognito

Provides AWS CDK constructs for defining Amazon…

permissive · top 15,000 on PyPI

aws-cdk.aws-sqs

Provides AWS CDK constructs for defining Amazon…

permissive · top 15,000 on PyPI

aws-cdk-lib

Provides Python APIs to define and deploy AWS…

permissive · top 5,000 on PyPI

aws-cdk.aws-location-alpha

Provides AWS CDK constructs for building…

permissive · top 15,000 on PyPI

aws-cdk.aws-sam

Provides AWS CDK v1 constructs for defining…

permissive · top 15,000 on PyPI

cdk-aurora-globaldatabase

Provides AWS CDK constructs to deploy Amazon…

permissive · top 15,000 on PyPI

aws-cdk.aws-amplify-alpha

Defines AWS Amplify hosting infrastructure as…

permissive · top 15,000 on PyPI