Calling
Calling is a base-URL change. The wire format is exactly OpenAI's on
/v1/chat/completions and exactly Anthropic's on /v1/messages, so any SDK
works without touching the rest of your code.
1https://api.aile.sh/v1
What is different from a normal provider
The catalogue is live. GET /v1/models is an aggregation over the sharers
who can serve right now, cached for 60 seconds. A model appears once a sharer's
account has passed a test of it, and disappears when nobody is sharing it.
Caller format and provider format are independent. You can ask for a Claude model through the OpenAI endpoint, or a Codex model through the Anthropic endpoint. Aile translates between wire shapes; your SDK never has to know.
You can steer the routing. Cap the price, pin a provider, require an attested account, or name one machine, per request with headers, or pinned to the key itself. See Choosing a sharer.
You pay per token (per unit on most non-chat endpoints), from a balance you fund. No seats, no minimums. See
Pricing & fees. Set max_tokens: a request that names no cap can
bill up to what the provider was allowed to write. See Spend & limits.
The five-minute version
-
Mint a key in the dashboard. It looks like
sk-aile-…. -
Fund your wallet with USDC on Solana (or USDT, SOL or $AILE, each swapped to USDC at no fee). Wallet & funding.
-
Point your SDK at
https://api.aile.sh/v1and send. Your first request.
The endpoints
| Endpoint | Format | Notes |
|---|---|---|
POST /v1/chat/completions | OpenAI Chat Completions | The default for most SDKs. |
POST /v1/messages | Anthropic Messages | Same catalogue, Anthropic's shape. |
POST /v1/responses | OpenAI Responses | |
POST /v1/embeddings | OpenAI Embeddings | Per token, at the sharer's quote. Embeddings |
POST /v1/images/generations, /v1/images/edits, /v1/images | OpenAI / OpenRouter | Per image. Images |
POST /v1/rerank, /v2/rerank | Cohere | Per search. Rerank |
POST /v1/moderations | OpenAI | Per input. Moderations |
POST /v1/ocr | Mistral | Per page. OCR |
POST /v1/search | Aile | Per query. Web search |
POST /v1/scrape | Aile | Per page. Scrape |
POST /v1/audio/speech, /transcriptions, /translations | OpenAI | Per 1,000 characters (1,000 UTF-8 bytes on Fish Audio models) or per minute. ElevenLabs and Fish Audio take their own voice ids. Audio |
POST /v1/videos, /v1/videos/generations, GET /v1/videos/{id} | OpenAI / xAI | Per second, as a job answered at once. Video |
POST /v1/music/generations | Aile | Per track. Music |
POST /v1/decisions, /v1/systemone | OpenRouter | Per token, never above list. Decisions |
POST /v1/messages/count_tokens | Anthropic | Advisory estimate. It probes no sharer and bills nothing. |
GET /v1/models | OpenAI | Public. What can be served right now. |
GET /v1/models/{id} | OpenAI | Public. Ids contain /, and that is handled. |
Every model is <provider>/<model>. The non-chat endpoints have no failover, and are buffered
except image generations and edits on models that stream, and speech with stream_format: "audio".
Where the deployment enables it, images, speech, transcription and translation, rerank, moderations, OCR, web search, scrape, one-shot music and video also take keyless x402. Video is charged when the render starts and refunded if it fails.
The full generated reference, runnable in the browser: API reference.
Where to go next
| If you want to… | Read |
|---|---|
| Send something now | Your first request |
Understand cc/claude-sonnet-5 | Model names |
| Control who serves you | Choosing a sharer |
| Stream tokens | Streaming |
| Handle failures properly | Errors |
| Know what you have spent | Spend & limits |