OpenAI-compatible · Token-based · no plans, ever

One API.
Forty-seven models.
Zero rewrites.

Obsidian X is an inference gateway that speaks fluent OpenAI — streaming, tools, JSON mode and included. It's completely token-based: grab credits from our Discord, point your SDK at us and ship.

Start building
0
models, one key
$0
paid, ever
0%
OpenAI-compatible
obsidian — zsh 200 OK · 214ms

Getting started

Authentication

Every /v1/* endpoint expects a bearer token. Keys are prefixed with obsidianx- followed by a 32-character secret. Keep it server-side — never ship it in a browser bundle.

request header
Authorization: Bearer obsidianx-<32-char-key>
Missing or bad key?

You'll get a 401 back immediately, before any tokens are billed. Rotate compromised keys right away.

Don't have a key?

Join our Discord and run /register to get your token API key instantly. It's the only place keys and credits come from — no sign-ups, no payments.

Join Discord

Quickstart

Already on the OpenAI SDK? Change two lines — the base URL and the key — and every model on the pricing table is yours.

curl https://obsidian-x-api.vercel.app/v1/chat/completions \
  -H "Authorization: Bearer $OBSIDIANX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "deepseek-v4-flash",
    "messages": [{ "role": "user", "content": "Hello" }]
  }'
POST /v1/chat/completions

OpenAI-compatible chat completion. Supports streaming via SSE, tool calling, JSON mode, deterministic seeds and reasoning tokens. Streaming responses are billed on the final aggregated usage.

Request body
request · JSON
{
  "model": "deepseek-v4-flash",
  "messages": [{ "role": "user", "content": "Hello" }],
  "stream": false,
  "temperature": 0.7,
  "max_tokens": 2048
}
response includes x_obsidian metadata 200
{
  "id": "chatcmpl-…", "choices": [ … ],
  "x_obsidian": {
    "cost": 0.0002,   // billed for this call ($)
    "balance": 9.54   // remaining balance ($)
  }
}

See how the model thinks

request
{
  "model": "mimo-v2.5",
  "messages": [{
    "role": "user",
    "content": "Explain quantum computing"
  }],
}
GET /v1/models

Lists every available model along with its per-1K-token pricing, so you can pick programmatically.

response 200
{
  "object": "list",
  "data": [
    {
      "id": "deepseek-v4-flash",
      "object": "model",
      "owned_by": "obsidian",
      "pricing": { "input_per_1k": 0.0008, "output_per_1k": 0.0012 }
    }
  ]
}
GET /balance

Check remaining token credits on your key. Also returned free on every completion inside x_obsidian. Running low? Top up in the Discord.

request
curl https://obsidian-x-api.vercel.app/balance \
  -H "Authorization: Bearer obsidianx-xxxxxxxxxxxx"
response 200
{
  "username": "alice",
  "balance": 9.54
}

Reference

Models & pricing

Prices are per 1K tokens — but they're paid in token credits, not real money. The whole API costs $0: grab credits on Discord and every model is yours. No plans, no paywalls, no model locked behind a tier.

Model Credit usage Input / 1K Output / 1K

Cost calculation

Cost is deducted from your free credit balance on each completion — never your wallet. Streaming responses are billed on the final aggregated usage, and topping up is as simple as heading back to the Discord.

the formula

cost = (input_tokens × input_price
+ output_tokens × output_price) / 1000

Estimate a request

input_tokens1,000
output_tokens500
credits used $0.001400

Error codes

Standard HTTP semantics. Anything 4xx is on the request; 5xx means retry with backoff.

Swap the base URL. That's the migration.

If your code speaks OpenAI, it already speaks Obsidian X — and it won't cost you a cent.

Copied to clipboard