API Gateway v2
HTTP APIs, Lambda proxy integration, JWT and Lambda authorizers, CORS.
fakecloud implements 103 of 103 API Gateway v2 operations at 100% conformance (HTTP APIs). REST APIs are covered separately on the API Gateway v1 page.
Supported features
- HTTP APIs — CreateApi, UpdateApi, DeleteApi, GetApis
- WebSocket APIs — CreateApi with
protocolType=WEBSOCKET, live data plane upgrade endpoint,$connect/$disconnect/$defaultroute dispatch to Lambda - Routes — path parameters, wildcards, HTTP method routing; stage variable substitution in integration URIs and route keys
- Integrations — Lambda proxy (v2.0 format), HTTP proxy, Mock integration, AWS service integrations dispatched in-process
- Stages — CRUD, deployments, default stage; stage variables exposed to integrations and access logs
- Authorizers — JWT validated with real RS256 verification against the issuer's JWKS (audience, expiry, scope); REQUEST Lambda authorizers invoke real functions and cache by
identitySource - Custom domain names + API mappings —
ApiMappingresolves host header to the right API + stage at request time - CORS — configuration on routes and globally
- Access logs — per-stage
accessLogSettingsdeliver formatted log events to the configured CloudWatch Logs log group - Request history — every request served is recorded for introspection
- Deployments — CreateDeployment, GetDeployments
- Management API —
apigatewaymanagementapiops (PostToConnection, GetConnection, DeleteConnection) at/@connections/{id}and/{stage}/@connections/{id}
Protocol
REST for management, path-based routing for the executed API. WebSocket APIs upgrade at /_fakecloud/apigatewayv2/ws/{api_id} and the management API is served on the same host:port — point the AWS SDK's apigatewaymanagementapi client at the fakecloud endpoint URL.
Introspection
GET /_fakecloud/apigatewayv2/requests— list all HTTP API requests received (method, path, headers, query params, status code, integration response)GET /_fakecloud/apigatewayv2/connections— list live WebSocket connections withconnectionId,apiId,stage,connectedAt,lastActiveAt,sourceIp
Cross-service delivery
- API Gateway v2 -> Lambda — HTTP API routes invoke Lambda functions with proxy integration v2.0 event format
- API Gateway v2 -> Lambda (authorizers) — REQUEST (Lambda) authorizers invoke real functions; policy + context returned drive the request decision
- API Gateway v2 -> JWT issuers — JWT authorizers fetch the configured issuer's JWKS and verify caller tokens (RS256 signature, expiry, audience, scope)
- API Gateway v2 -> CloudWatch Logs — stage access logs delivered to the configured log group with the formatted access log line
- API Gateway v2 -> AWS services — AWS service integrations dispatch to in-process service handlers
Why this matters
LocalStack paywalls API Gateway v2. fakecloud implements the full HTTP API surface free, with real route matching, real Lambda proxy integration, and full request introspection. Webhook testing for event-driven applications is fully supported.