Skip to content

Endpoints

Model calls, the catalog, routes, usage, calls, limits, keys, browser tokens and the rest.

Applies to EngineCloud
View as Markdown
On this page
  1. Model calls
  2. Catalog and tasks
  3. Routes
  4. Usage and calls
  5. Limits, keys and access

Model calls

Method and pathDoes
POST /chat/completionsA chat call; stream: true answers Server-Sent Events
POST /embeddingsEmbeddings for up to 256 texts
POST /moderationsCheck a text with the content checks, without asking a model

Catalog and tasks

Method and pathDoes
GET /models, GET /models/{id}The catalog: inputs, tools, structured answers, context, retention, price
GET /tasksThe project’s tasks and the model of each

Routes

Method and pathDoes
GET /routesThe project’s routes, as JSON or as the TOML of the [ai] table (Accept: application/toml)
PUT /routesReplace them with a new version; a person with the owner or admin role
GET /routes/history, POST /routes/rollbackVersions, and { version } to go back

Usage and calls

Method and pathDoes
GET /usage?group_by=case&since=&until=Usage grouped by case, task, key, end_user, model or day
GET /calls?case=&status=&since=&cursor=Recent calls
GET /calls/{id}One call: route, attempts, tokens, credits, timings
GET /calls/{id}/bodyWhat was asked and answered, when the route kept it; admin, recorded

Limits, keys and access

Method and pathDoes
GET|PUT /limitsThe project’s limits
GET|POST /keys, DELETE /keys/{id}Keys
POST /browser-tokensA browser token: with the publishable key and a Sypnia Data session, or with a secret key and end_user
GET|POST /provider-keys, DELETE /provider-keys/{id}Your own provider keys Cloud
GET|POST /origins, DELETE /origins/{id}Sites allowed to use browser tokens
POST /cache/purge{ task }: empty a route’s cache
DELETE /end-users/{id}Forget a person of your app
GET /healthThe gateway and each provider

The OpenAPI document is in the gateway’s repository, at spec/openapi.yaml.

  1. Model calls
  2. Catalog and tasks
  3. Routes
  4. Usage and calls
  5. Limits, keys and access

    Search pages, sections and terms