Glossary · Runtime

WASM function

A WASM function is a KERNSTACK function: a Go handler compiled to WebAssembly, declared under resources.functions, and invoked through a gateway route, a schedule, a table change stream, or a workflow step. Websocket routes must target functions.

Definition: WASM function

A WASM function is a KERNSTACK function: a Go handler compiled to WebAssembly, declared under resources.functions, and invoked through a gateway route, a schedule, a table change stream, or a workflow step. Websocket routes must target functions.

What a function is for

Functions are the request-shaped unit: an HTTP handler behind a route, a websocket handler, a scheduled job on a cron entry, or the function a table change stream invokes with batched changes. Source lives at functions/{name} by convention. Non-Go code, and work that outlives a request, belongs in container workers instead — the platform is explicit about the split rather than stretching one runtime to cover both.

How a function is priced and reviewed

Compute meters at 0.01 credits per GiB-second of actual execution; a function that is never called costs nothing. Because functions are declared in stack.json, adding one appears in the plan diff with its routes and triggers — the reviewer sees the new public surface at the same time as the code that serves it.

Frequently asked questions

Go, compiled to WebAssembly. JavaScript, TypeScript, Python, and PHP run as container workers with the nodejs, python, or php runtime — handlers in those languages never become functions, and honest stack design starts there.

Yes. A function entry can carry schedules with a cron expression; scheduled invocations meter like any other execution and appear in the plan like any other declaration.

Yes. There is no idle replica to pay for: execution bills per GiB-second while code runs, and an uncalled function contributes nothing but its declaration to the bill.

Ship your stack on the Software Lifecycle Cloud.

Closed preview on dedicated European infrastructure. Bring a repository or start from a blueprint.