feat: add API Gateway route testing and discovery

This commit is contained in:
Zakaria
2026-09-24 08:56:22 -04:00
parent 7e49be27f1
commit 9bbe80b5f2
10 changed files with 802 additions and 6 deletions
+30
View File
@@ -463,6 +463,34 @@ export interface ApiGatewayLambdaRouteResult {
invokeUrl: string
}
export interface ApiGatewayTestRouteInput {
path: string
method: string
stage: string
body: string
headers: Record<string, string>
query: string
}
export interface ApiGatewayTestRouteResult {
statusCode: number
headers: Record<string, string>
body: string
durationMs: number
}
export interface ApiGatewayRouteOverview {
resourceId: string
path: string
method: string
functionName: string | null
}
export interface ApiGatewayRoutesResult {
routes: ApiGatewayRouteOverview[]
stages: string[]
}
export type KmsEncryptionAlgorithm =
| 'SYMMETRIC_DEFAULT'
| 'RSAES_OAEP_SHA_1'
@@ -525,6 +553,8 @@ export interface CloudServiceAdapter {
listDatabaseOrderableInstanceClasses?(engine?: string): Promise<string[]>
invoke?(id: string, payload: string): Promise<ServerlessInvokeResult>
createApiGatewayLambdaRoute?(apiId: string, input: ApiGatewayLambdaRouteInput): Promise<ApiGatewayLambdaRouteResult>
testApiGatewayRoute?(apiId: string, input: ApiGatewayTestRouteInput): Promise<ApiGatewayTestRouteResult>
listApiGatewayRoutes?(apiId: string): Promise<ApiGatewayRoutesResult>
encrypt?(id: string, input: KmsEncryptInput): Promise<KmsEncryptResult>
decrypt?(id: string, input: KmsDecryptInput): Promise<KmsDecryptResult>
// Lifecycle verbs. Optional because most categories have no notion of them;