Runtimes & Runtime Servers API
Runtimes represent language/runtime types (Node.js, Python, Go, Java, etc.) with versions and OS-specific install/remove scripts. Runtime resources can be created on the canvas and connected to instances; connecting a runtime to a server installs that runtime on the instance via SSH. Runtime servers are HTTP/server options per runtime type (e.g. Node → Express/Nginx/Caddy, Python → Gunicorn/Nginx). All endpoints require authentication. Runtime catalog endpoints are global; runtime resource endpoints are scoped by project and environment.Runtimes catalog (global)
List runtimes
GET /api/runtimes
runtimes table (used for create-resource dropdown and runtime selection).
Query parameters:
Example:
Runtime servers (per runtime type)
List runtime servers
GET /api/runtimes/servers
node → Express, Fastify, Nginx, Caddy). Used to choose which server stack to use with a runtime. Each server has OS-specific install/remove scripts (same structure as runtimes).
Query parameters:
Example:
Runtime resources (project/environment-scoped)
Runtime resources are canvas cards that reference a runtime (name + version). They can be connected to instances; on connect, the backend installs the runtime on the instance via SSH using OS-specific install scripts. See Resource Connections for runtime → instance connection behavior.Create runtime resource
POST /api/:projectSlug/:environmentSlug/runtimes
Body:
Example:
Get runtime resource
GET /api/:projectSlug/:environmentSlug/runtimes/:id
Example:
Delete runtime resource
DELETE /api/:projectSlug/:environmentSlug/runtimes/:id
Relationship to other APIs
- Unified resources: Runtime resources appear in
GET /api/:projectSlug/:environmentSlug/resourceswithresourceType(ortype)runtime. Positions can be updated via Resource Positions. - Resource connections: Runtime → instance connections are allowed (see Resource Connections and
allowed_connectionstable). On connect, the backend installs the runtime on the instance via SSH; on disconnect, it runs the runtime’s remove script. - Seeding: Runtimes are seeded with
npm run seed:runtimes; runtime servers withnpm run seed:runtime-servers(see backendscripts/).