Zum Inhalt springen
#0925
ExecContainers

Every white-label tenant's API reference regenerates from their folder

Forty white-label tenants, one exec. Each tenant's custom endpoints live under scripts/{subdomain}/{execId}/, so acme's api/orders.ts and globex's api/orders.ts are different files behind different hostnames.

The Docs link in acme's admin panel points at /api/v1/exec/user-openapi/spec?format=yaml. Exec scans the script directory, and when subdomain is omitted it takes the Host header, so acme's spec lists acme's routes, with input and output types for every script that declares a schema, and nothing of globex's. Add a script and the spec changes on the next GET. Nobody regenerates anything.

You used to ship one OpenAPI file for the product and a footnote saying custom endpoints aren't documented here. Now every tenant has the reference their integrators expect, exactly as current as their code.

The API docs are a GET on the folder, and the hostname picks the folder.