Ana içerik geç

External APIs — /api/zeq/apis/:slug*

The machine-scoped external-API registry — the APIs drawer in the Workbench, and the CLI's apis commands. The owner stores a friendly name, base URL, optional auth header, and optional schema JSON; a state contract's api_call action then references the API by name instead of hardcoding a URL or secret. Owner-gated.

Concept: State Contracts → actions. Source: shared/api-core/src/routes/apisRoutes.ts.

Endpoints

MethodPathAuthNotes
GET/api/zeq/apis/:slugBearer (owner)List registered APIs on the machine.
POST/api/zeq/apis/:slugBearer (owner)Register a new API (name, base URL, auth header, schema).
PATCH/api/zeq/apis/:slug/:idBearer (owner)Update a registered API.
DELETE/api/zeq/apis/:slug/:idBearer (owner)Remove a registered API.
POST/api/zeq/apis/:slug/:id/testBearer (owner)Test the connection / auth.

CLI equivalents: apis · apis add <name> <url> · apis test <id> · apis remove <id> (see Zeq CLI).