Skip to content

API reference

OneNexus’s OpenAI-compatible chat-completions API works only when a request’s base URL and model value belong to the same serving surface, and its API key is authorized for it.

For a guided first request, use the Platform quickstart or Call a self-hosted model endpoint.

SurfaceBase URLAPI keyRequest model
Hosted Platform cataloghttps://catalog.onenexus-do.cloud/v1PlatformExact model value in the expanded row’s cURL request
Tenant self-hosted modelsCopy the tenant Endpoint shown on a model detail page and append /v1Inference authorizing the selected model’s Served Model NameExact Served Model Name configured on that model

Do not mix a host and model value from different rows; a valid key sent to a host it cannot access can still be refused.

Send the key as a bearer token on every request:

Authorization: Bearer <your-api-key>

Create keys in API KeysGenerate API key.

Key typeScope
PlatformEvery published Platform catalog model, including models added later. It cannot call tenant self-hosted models and cannot be narrowed to one model.
InferenceThe Served Model Names of the models selected when the key was created. A replacement in the same tenant that continues using one of those Served Model Names shares access. Other Served Model Names and the shared catalog are refused.

Use a Platform key for the shared catalog and an Inference key scoped to the required Served Model Names for self-hosted models. Deleting a model does not revoke a key; revoke the credential explicitly when its Served Model Names should no longer be authorized.

The secret is shown only once, so give each application and environment its own expiring key, keep it in a server-side secret store or protected environment variable, and never send it to support.

Revocation is immediate and cannot be undone. Rotate: create a replacement, update the application’s secret configuration, verify a non-sensitive request, then revoke the old key.

The Console is the authority for the string sent as model:

  • Platform catalog: open Platform models, expand a row, and copy the JSON model value from its cURL request. Do not substitute the Public model ID column; that is the catalog and billing identity, while routing uses the generated request’s model value.
  • Self-hosted model: open the model and copy its Served Model Name. The Copy as cURL tab combines it with the correct endpoint and path.

The catalog host does not currently expose GET /v1/models; that path returns 404. Discover Platform models in the Console instead.

Send POST /v1/chat/completions relative to the selected base URL:

{
"model": "<model-value-from-generated-curl>",
"messages": [
{ "role": "user", "content": "Hello" }
],
"max_tokens": 512,
"temperature": 0.7,
"stream": false
}

A non-streaming Chat Completions response contains a choices array; read final text, when present, from choices[0].message.content:

{
"choices": [
{
"message": {
"role": "assistant",
"content": "Hello!"
}
}
]
}

A 2xx response can have empty final text when the model returns reasoning without a final answer; treat transport/API success separately from application-level final-answer success, and inspect the complete response before deciding to retry. Other response fields can vary by model and serving engine; do not make application logic depend on an undocumented field.

Set stream to true for a server-sent event stream. If a stream has emitted data and then fails, do not automatically replay the whole request; a replay can duplicate work or output.

StatusMeaningAction
Validation 4xxThe request body contains unsupported or malformed dataFix the request; do not retry unchanged
401No credential was presented, or the Authorization header is malformedSend Authorization: Bearer <key>
403The credential was refused because of its type, tenant, expiry, revocation state, Served Model Name scope, host, or model nameRecheck the full base URL + key type + model tuple; do not retry unchanged
404The URL or route does not existCorrect the URL or path; do not treat it as a transient model error
429The authenticated request-rate ceiling was reachedRetry a bounded number of times with exponential backoff and jitter
503The serving path is temporarily unavailableRetry a bounded number of times; inspect the model’s health if it persists

GPU quota shown under Quotas is a control-plane admission limit for GPU-backed resources. A data-plane 429 is a separate request-rate response; it is not evidence that you need more GPU quota.

When escalating, include the serving surface, endpoint, model name, UTC timestamp, HTTP status, and request identifier if the response provides one. Never include an API key or sensitive prompt content.