AWS API Gateway V2 Event
AWS API Gateway v2 HTTP event with simplified routing and request context.
aws
Install
$ npx shadcn@latest add @open-types/aws-api-gateway-v2-event
Source
export interface AWSAPIGatewayV2Http {
method: string;
path: string;
protocol: string;
sourceIp: string;
userAgent: string;
}
export interface AWSAPIGatewayV2RequestContext {
accountId: string;
apiId: string;
domainName: string;
domainPrefix: string;
http: AWSAPIGatewayV2Http;
requestId: string;
routeKey: string;
stage: string;
time: string;
timeEpoch: number;
}
export interface AWSAPIGatewayV2Event {
version: "2.0";
routeKey: string;
rawPath: string;
rawQueryString: string;
headers: Record<string, string>;
queryStringParameters?: Record<string, string>;
pathParameters?: Record<string, string>;
body?: string | null;
isBase64Encoded: boolean;
requestContext: AWSAPIGatewayV2RequestContext;
}
export interface AWSAPIGatewayV2Http {
method: string;
path: string;
protocol: string;
sourceIp: string;
userAgent: string;
}
export interface AWSAPIGatewayV2RequestContext {
accountId: string;
apiId: string;
domainName: string;
domainPrefix: string;
http: AWSAPIGatewayV2Http;
requestId: string;
routeKey: string;
stage: string;
time: string;
timeEpoch: number;
}
export interface AWSAPIGatewayV2Event {
version: "2.0";
routeKey: string;
rawPath: string;
rawQueryString: string;
headers: Record<string, string>;
queryStringParameters?: Record<string, string>;
pathParameters?: Record<string, string>;
body?: string | null;
isBase64Encoded: boolean;
requestContext: AWSAPIGatewayV2RequestContext;
}