@types/aws-lambda
Advanced tools
Comparing version 8.10.100 to 8.10.101
{ | ||
"name": "@types/aws-lambda", | ||
"version": "8.10.100", | ||
"version": "8.10.101", | ||
"description": "TypeScript definitions for AWS Lambda", | ||
@@ -228,4 +228,4 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/aws-lambda", | ||
"dependencies": {}, | ||
"typesPublisherContentHash": "8b043117ba85a1c7ed7863043e267167394cb3adf10cc69424b70611bbf76df0", | ||
"typesPublisherContentHash": "b62431ce8007d7412ae85a9bce177f526057b263b55cb490e1cda0773aa91342", | ||
"typeScriptVersion": "4.0" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
### Additional Details | ||
* Last updated: Thu, 09 Jun 2022 21:31:34 GMT | ||
* Last updated: Mon, 20 Jun 2022 13:31:36 GMT | ||
* Dependencies: none | ||
@@ -14,0 +14,0 @@ * Global values: `AWSLambda` |
@@ -26,2 +26,9 @@ import { | ||
/** | ||
* Works with HTTP API integration Payload Format version 2.0 | ||
* @see - https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-websocket-api-integration-requests.html | ||
* @see - https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-websocket-api-mapping-template-reference.html | ||
*/ | ||
export type APIGatewayProxyWebsocketHandlerV2<T = never> = Handler<APIGatewayProxyWebsocketEventV2, APIGatewayProxyResultV2<T>>; | ||
/** | ||
* Works with HTTP API integration Payload Format version 2.0 adds JWT Authroizer to RequestContext | ||
@@ -166,2 +173,22 @@ * @see - https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-lambda.html | ||
} | ||
/** | ||
* Works with Websocket API integration Payload Format version 2.0 | ||
* @see - https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-websocket-api-integration-requests.html | ||
* @see - https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-websocket-api-mapping-template-reference.html | ||
*/ | ||
export interface APIGatewayEventWebsocketRequestContextV2 { | ||
routeKey: string; | ||
messageId: string; | ||
eventType: 'CONNECT' | 'MESSAGE' | 'DISCONNECT'; | ||
extendedRequestId: string; | ||
requestTime: string; | ||
messageDirection: 'IN'; | ||
stage: string; | ||
connectedAt: number; | ||
requestTimeEpoch: number; | ||
requestId: string; | ||
domainName: string; | ||
connectionId: string; | ||
apiId: string; | ||
} | ||
@@ -187,2 +214,12 @@ /** | ||
/** | ||
* Proxy Websocket Event with adaptable requestContext for different authorizer scenarios | ||
*/ | ||
export interface APIGatewayProxyWebsocketEventV2WithRequestContext<TRequestContext> { | ||
requestContext: TRequestContext; | ||
body?: string; | ||
isBase64Encoded: boolean; | ||
stageVariables?: APIGatewayProxyEventStageVariables; | ||
} | ||
/** | ||
* Lambda Authorizer Payload | ||
@@ -224,2 +261,8 @@ */ | ||
/** | ||
* Default Websocket Proxy event with no Authorizer | ||
*/ | ||
export type APIGatewayProxyWebsocketEventV2 = | ||
APIGatewayProxyWebsocketEventV2WithRequestContext<APIGatewayEventWebsocketRequestContextV2>; | ||
/** | ||
* Works with HTTP API integration Payload Format version 2.0 | ||
@@ -226,0 +269,0 @@ * @see - https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-lambda.html |
130307
3091