API reference

API reference · Playground

A chat turn billed to the signed in account

POST/api/chat/turnSigned in session

What the free console will not carry: a turn past its prompt limit (documents of up to 60000 characters ride inside the message) or one with search: true, which asks the configured provider first and charges the query as its own ledger line (ref search:<provider>). Streams the chat wire; a searched turn opens with one frame { object: "antimatter.sources", sources, search_cost_micros }. Billed to the signed in account the way a key is: its free allowance while it never deposited, else a hold and settlement on its balance; the house breaker, the account's monthly cap and an operator freeze apply. Same origin only.

Request body

application/json, required

Request body fields
FieldTypeWhat it is
modelrequiredstring
messagesrequiredarray of object
temperaturenumber
searchboolean

Example

{
  "model": "antimatter/auto",
  "messages": [
    {}
  ],
  "temperature": 0,
  "search": false
}

Answer 200

The reply, as server sent events.

The answer's fields are not named in the document.

Errors

  • 400OpenAI shaped error.
  • 401OpenAI shaped error.
  • 402OpenAI shaped error.
  • 403OpenAI shaped error.
  • 429OpenAI shaped error.
  • 502OpenAI shaped error.
  • 503OpenAI shaped error.

Every error answers in one shape, with its type, code and the field it names. The whole list is in the docs' Errors section.

Antimatter