Skip to content
Version: Current

POST /v1/chat/completions

Part of the API reference; this page is generated from the OpenAPI document that the gateway builds from its own route tables.

  • Contract version: 1.10.0
  • Contract title: acumen gateway API
  • Source: acumen:docs/openapi/acumen-v1.openapi.json

OpenAI-compatible chat completions

The OpenAI chat door. Routes each request across the live seats for model (or an alias: auto, cheap, fast, coding, reason, vision, long), streaming SSE frames when stream:true. The request body is forwarded as a pass-through dialect body; tools requests skip seats probed without tool support.

  • Operation id: postV1ChatCompletions
  • Scope: chat
  • Exposure: public
  • Mutating: no
  • Auth: bearerAuth, apiKeyAuth

Request

  • Request body (application/json, required): ChatRequest: ChatRequest (object)
Field Type Required Notes
max_tokens integer no
messages array of object yes
model string yes
seed integer no
stream boolean no
temperature number no
tools array of object no
top_p number no

Responses

  • 200: Completion, or an SSE stream when the request sets stream:true
    • Streaming: text/event-stream
    • application/json: ChatCompletion: ChatCompletion (object)
  • 400: schema_invalid
    • application/json: OpenAIError: OpenAIError (object)
  • 401: bad_credentials
    • application/json: OpenAIError: OpenAIError (object)
  • 402: quota_exhausted (cool-down applied)
    • application/json: OpenAIError: OpenAIError (object)
  • 403: auth_scope
    • application/json: OpenAIError: OpenAIError (object)
  • 413: payload_too_large
    • application/json: OpenAIError: OpenAIError (object)
  • 429: rate_limited (RPM or concurrency)
    • application/json: OpenAIError: OpenAIError (object)
  • 502: upstream_error — every attempted seat failed
    • application/json: OpenAIError: OpenAIError (object)
  • 503: model_no_eligible_seat
    • application/json: OpenAIError: OpenAIError (object)