Skip to content

HttpApiLambdaMultiRoute

Open in ChatGPTOpen in Claude

Defined in: packages/core/src/types/lambda.ts:330

Multi-route (“fat lambda”) HTTP API v2 config — one warm fn, N routes (D1/D8).

optional architecture?: LambdaArchitecture

Defined in: packages/core/src/types/lambda.ts:130

CPU architecture. Defaults to arm64 (Graviton — cheaper + faster for most workloads). Lambda@Edge MUST use x86_64.

BaseLambdaConfig.architecture


optional authorizer?: HttpApiAuthorizer

Defined in: packages/core/src/types/lambda.ts:335

Optional fallback authorizer for routes that omit their own (D4).


optional basePath?: string

Defined in: packages/core/src/types/lambda.ts:337

Optional path prefix; routes are relative when set (D9). Must start with ”/“.


optional bundling?: NodejsBundlingConfig | PythonBundlingConfig | GoBundlingConfig

Defined in: packages/core/src/types/lambda.ts:191

Runtime-specific bundling config

BaseLambdaConfig.bundling


optional constructId?: string

Defined in: packages/core/src/types/lambda.ts:145

CloudFormation logical ID override. Use when migrating existing lambdas to preserve physical resource IDs.

BaseLambdaConfig.constructId


optional customFunctionName?: (appName, stageName) => string

Defined in: packages/core/src/types/lambda.ts:151

Custom function name factory. If omitted, the framework generates: ${appName}-${name}-${stageName}

string

string

string

BaseLambdaConfig.customFunctionName


description: string

Defined in: packages/core/src/types/lambda.ts:133

Human-readable description (shows in AWS console)

BaseLambdaConfig.description


optional enableTracing?: boolean

Defined in: packages/core/src/types/lambda.ts:157

Enable X-Ray tracing. Default: true. Not supported on Lambda@Edge.

BaseLambdaConfig.enableTracing


entry: string

Defined in: packages/core/src/types/lambda.ts:112

Handler entry point, relative to the project root. Node.js: path to .ts file (e.g. “lambdas/modules/url/api/create/index.ts”) Python: path to .py file (e.g. “lambdas/url/create.py”) Go: path to package (e.g. “lambdas/url/create”)

BaseLambdaConfig.entry


optional environment?: Record<string, string>

Defined in: packages/core/src/types/lambda.ts:182

Environment variables. Supports {{token}} syntax for registry values and ${ssm:/path} for SSM parameters.

Note: Lambda@Edge does not support environment variables. For edge lambdas, use bundling.define instead.

BaseLambdaConfig.environment


kind: "httpapi"

Defined in: packages/core/src/types/lambda.ts:331

Execution context.

BaseLambdaConfig.kind


optional logLevel?: "ERROR" | "DEBUG" | "INFO" | "WARN" | "SILENT"

Defined in: packages/core/src/types/lambda.ts:154

Powertools log level. Default: INFO

BaseLambdaConfig.logLevel


optional logRetentionDays?: number

Defined in: packages/core/src/types/lambda.ts:173

CloudWatch log group retention in days for this lambda. Overrides the project-wide default from lambdaDefaults.logRetentionDays.

Framework defaults (when not set here or in lambdaDefaults):

  • dev: 30 days
  • prod: 90 days

Set to 0 to disable retention (logs kept forever — not recommended in prod). Not supported on Lambda@Edge (edge functions use CloudFront logging).

BaseLambdaConfig.logRetentionDays


optional logSensitive?: "true" | "false"

Defined in: packages/core/src/types/lambda.ts:160

Set to “true” to include sensitive fields in logs (non-prod only)

BaseLambdaConfig.logSensitive


optional memorySize?: number

Defined in: packages/core/src/types/lambda.ts:136

Memory in MB. Default: 512

BaseLambdaConfig.memorySize


optional method?: never

Defined in: packages/core/src/types/lambda.ts:338


name: string

Defined in: packages/core/src/types/lambda.ts:99

Unique name for this lambda. Used in function names and logical IDs. Convention: kebab-case, e.g. “create-url”, “process-payment”

BaseLambdaConfig.name


optional path?: never

Defined in: packages/core/src/types/lambda.ts:339


optional permissionsSpec?: PermissionSpec[]

Defined in: packages/core/src/types/lambda.ts:188

Declarative IAM permissions. The constructs package translates these into PolicyStatements.

BaseLambdaConfig.permissionsSpec


routes: HttpApiRoute[]

Defined in: packages/core/src/types/lambda.ts:333

One or more routes attached to a single warm function. Must be non-empty.


optional runtime?: LambdaRuntime

Defined in: packages/core/src/types/lambda.ts:124

Lambda runtime. Defaults to nodejs24 (latest LTS).

Examples: “nodejs24” → Node.js 24.x (latest) “nodejs22” → Node.js 22.x (LTS — EOL April 2027) “python312” → Python 3.12 “python311” → Python 3.11 “go” → Go on provided.al2023

BaseLambdaConfig.runtime


optional timeoutSeconds?: number

Defined in: packages/core/src/types/lambda.ts:139

Timeout in seconds. Default: 10

BaseLambdaConfig.timeoutSeconds

© 2026 Axis Tech. Powered by axis-tech.co.