1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 | export interface APIGatewayAuthorizerResultContext {
|
8 | [name: string]: string | number | boolean | null | undefined;
|
9 | }
|
10 |
|
11 |
|
12 |
|
13 |
|
14 | export type APIGatewayEventDefaultAuthorizerContext =
|
15 | | undefined
|
16 | | null
|
17 | | {
|
18 | [name: string]: any;
|
19 | };
|
20 |
|
21 | export type APIGatewayEventRequestContext = APIGatewayEventRequestContextWithAuthorizer<
|
22 | APIGatewayEventDefaultAuthorizerContext
|
23 | >;
|
24 |
|
25 |
|
26 | export interface APIGatewayEventRequestContextWithAuthorizer<TAuthorizerContext> {
|
27 | accountId: string;
|
28 | apiId: string;
|
29 |
|
30 |
|
31 |
|
32 |
|
33 |
|
34 | authorizer: TAuthorizerContext;
|
35 | connectedAt?: number | undefined;
|
36 | connectionId?: string | undefined;
|
37 | domainName?: string | undefined;
|
38 | domainPrefix?: string | undefined;
|
39 | eventType?: string | undefined;
|
40 | extendedRequestId?: string | undefined;
|
41 | protocol: string;
|
42 | httpMethod: string;
|
43 | identity: APIGatewayEventIdentity;
|
44 | messageDirection?: string | undefined;
|
45 | messageId?: string | null | undefined;
|
46 | path: string;
|
47 | stage: string;
|
48 | requestId: string;
|
49 | requestTime?: string | undefined;
|
50 | requestTimeEpoch: number;
|
51 | resourceId: string;
|
52 | resourcePath: string;
|
53 | routeKey?: string | undefined;
|
54 | }
|
55 |
|
56 | export interface APIGatewayEventClientCertificate {
|
57 | clientCertPem: string;
|
58 | serialNumber: string;
|
59 | subjectDN: string;
|
60 | issuerDN: string;
|
61 | validity: {
|
62 | notAfter: string;
|
63 | notBefore: string;
|
64 | };
|
65 | }
|
66 |
|
67 | export interface APIGatewayEventIdentity {
|
68 | accessKey: string | null;
|
69 | accountId: string | null;
|
70 | apiKey: string | null;
|
71 | apiKeyId: string | null;
|
72 | caller: string | null;
|
73 | clientCert: APIGatewayEventClientCertificate | null;
|
74 | cognitoAuthenticationProvider: string | null;
|
75 | cognitoAuthenticationType: string | null;
|
76 | cognitoIdentityId: string | null;
|
77 | cognitoIdentityPoolId: string | null;
|
78 | principalOrgId: string | null;
|
79 | sourceIp: string;
|
80 | user: string | null;
|
81 | userAgent: string | null;
|
82 | userArn: string | null;
|
83 | }
|