Reference

Unchain API reference

The full description of the OpenAI-compatible API: endpoints, parameters, request and response schemas, error codes. The base URL is https://unchain-ai.com/v1; requests are authorized with the Authorization: Bearer header and a token from the bot.

Endpoints

  • GET /models — List models. Returns the only model the API serves. Checks the token.
  • GET /me — Balance and usage. The token owner's balance, whether requests can be sent right now, the model, limits and usage over the last 24 hours and 30 days. Only charged requests count. Free.
  • POST /chat/completions — Model response. OpenAI Chat Completions format. Streaming (stream: true, Server-Sent Events) and tool calls (tools) are supported. When streaming, the last chunk before data: [DONE] carries usage. A user can run a limited number of requests at once; extra ones get 429 with a Retry-After header.

How to issue a token and send your first request is covered in the API docs. The OpenAPI document: openapi.json.