Skip to main content
POST
/
v1
/
chat
/
completions
Create chat completion
curl --request POST \
  --url http://localhost:3000/v1/chat/completions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "ignored-by-astrolabe",
  "messages": [
    {
      "role": "user",
      "content": "Say hello in one line."
    }
  ]
}
'
{
  "id": "<string>",
  "object": "<string>",
  "created": 123,
  "choices": [
    {}
  ],
  "usage": {}
}
OpenAI-compatible chat completion endpoint routed by Astrolabe.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
messages
object[]
required
Minimum array length: 1
model
string

Accepted for compatibility. Astrolabe chooses final upstream model.

stream
boolean
default:true

If false, Astrolabe returns full JSON and can self-check/escalate.

Response

Successful response (JSON or stream)

id
string
required
object
string
required
created
integer
required
choices
object[]
required
usage
object