Skip to content
SingularSingular

OpenAI-shaped Chat Completions

The stable data-plane contract, its supported parameters, response shape, and current compatibility boundaries.

On this page

Endpoint

http
POST https://api.impossi.build/v1/chat/completions
Authorization: Bearer <SINGULAR_API_KEY>
Content-Type: application/json

Minimal request

json
{
  "model": "auto",
  "messages": [
    {"role": "user", "content": "What makes a good fallback policy?"}
  ]
}

messages is required. model is optional and defaults to auto; set an explicit live catalog ID when reproducibility or per-call payment matters. Accepted message roles are system, user, assistant, and tool. The current product normalizer does not accept OpenAI's newer developer role.

Parameter support

FieldStatusNotes
modelSupportedOptional; defaults to auto. Use an exact live catalog ID when reproducibility matters.
messagesSupportedString content and multimodal content arrays are preserved.
streamSupportedOpenAI-style data-only SSE.
max_tokens, max_completion_tokensSupportedEither field is accepted as the completion limit. Send one.
temperatureSupportedProvider/model constraints still apply.
top_pSupportedProvider/model constraints still apply.
toolsLimitedTool definitions reach the first request, but a complete multi-turn tool loop is not fully compatible; see below.
response_formatLimitedJSON repair is best effort, not a schema-enforcement guarantee.
tool_choice, parallel_tool_callsIgnoredNot forwarded by the current product normalizer.
stream_optionsIgnoredDo not depend on a final usage-only stream chunk.
stop, n, seed, logprobs, penalties, userIgnoredAccepted upstream behavior must not be assumed.
modalities, audio, reasoning_effortIgnoredUse model-specific defaults; these controls are not part of the stable contract.

Unknown or ignored fields may not produce an error. Build against the supported subset instead of treating a successful HTTP response as proof that every field was honored.

Message normalization

Singular retains role, content, name, and tool_call_id from input messages. Multimodal content arrays can pass through when the selected backend model accepts them. Assistant tool_calls are not preserved on a later request, so the normal OpenAI assistant-tool-tool-result loop is not yet a stable compatibility surface.

Response

The non-streaming response is Chat Completions-shaped and includes choices[].message, finish_reason, and usage where the upstream supplies it.

json
{
  "id": "chatcmpl_...",
  "object": "chat.completion",
  "model": "provider/model-or-auto",
  "choices": [{
    "index": 0,
    "message": {"role": "assistant", "content": "..."},
    "finish_reason": "stop"
  }],
  "usage": {"prompt_tokens": 0, "completion_tokens": 0, "total_tokens": 0}
}

For privacy and routing abstraction, model is rewritten to the requested ID. When the request uses auto, it remains auto; the public response does not disclose the hidden upstream target.

JSON output

response_format is forwarded, and Singular may attempt to repair JSON output. This is best effort. Invalid or unrepaired output can still be returned, so applications must parse and validate the result themselves.

Calling Claude or Gemini models

Use the exact Claude or Gemini model ID from the live catalog with this OpenAI-shaped endpoint. The wire format remains Chat Completions even when the selected model family is not OpenAI.

json
{
  "model": "anthropic/<live-model-id>",
  "messages": [{"role": "user", "content": "Hello"}]
}

Do not guess a model ID from upstream documentation. Model availability and naming come from the live Singular catalog.

Updated 2026-08-10. Live model availability, rates, account state, and payment rails remain request-time data.