Skip to main content

Type Alias: CreateFunctionRequest

type CreateFunctionRequest: components["schemas"]["CreateFunctionRequest"];

Properties

PropertyTypeRequiredDescription
namestringYesFunction name (example: "process-webhook")
slugstringNoURL-friendly slug (auto-generated if not provided) (example: "process-webhook")
descriptionstringNoFunction description
codestringYesInitial source code (example: "exports.handler = async (event, ctx) => { return { statusCode: 200, body: \"Hello\" }; };")
entrypointstringNoEntrypoint function name
runtime"nodejs20" | "nodejs22"NoRuntime environment
authMode"public" | "api_key" | "signed"NoAuthentication mode
timeoutnumberNoExecution timeout in ms (1000-300000)
memorynumberNoMemory limit in MB (128-1024)
envVarsSetEnvVarRequest[]NoInitial environment variables

Defined in

4Players/cortex-typescript-sdk/src/resources/functions.ts:32