Overview
The Functions API provides endpoints for invoking and managing serverless functions. In cloud environments, functions run on Deno Subhosting at the edge. In self-hosted (Docker) environments, functions run in a local Deno runtime.Headers
Invoke Function
Execute a deployed function using any HTTP method (GET, POST, PUT, PATCH, DELETE, etc.). The server preserves and forwards the caller’s original method to the function runtime.Note: Function invocation uses
/functions/{slug} (without /api prefix), not /api/functions/{slug}.Path Parameters
Request Body
Any JSON payload that the function expects.Example
Response
The response depends on what the function returns:Admin Endpoints
These endpoints require admin authentication.List All Functions
Example
Response
Get Function Details
Example
Response
Create Function
Currently, InsForge only supports JavaScript/TypeScript functions running in a Deno environment.
Request Body
Example
Response
Update Function
Request Body
Example
Response
Delete Function
Example
Response
Function Code Structure
Functions must export a default async function that receives aRequest object and returns a Response: