Developer API
Reach Angerona from your own code through the standard OpenAI SDK, with keys tied to your wallet, usage billing and a free daily allowance for holders.
The API speaks OpenAI. Aim any OpenAI SDK or tool at https://api.angerona.chat/v1, swap in an Angerona key, and chat completions, streaming, images and video run with no code changes.
- Keys tied to a wallet: sign in on angerona.chat and make them there, with no email or account step. See API keys.
- Usage billing: the owning wallet covers each call, holders' free credits first and paid credits after. See API billing.
- Anonymous mode: a secondary compute market of trusted providers serves requests and never learns the sender, though it reads the prompt. TEE stays in the app, outside API keys. See API models.
A first answer starts with a key
On angerona.chat, open Developers, sign in and press Create key. You get something like ang_live_…, displayed one time, so save it right away.
export ANGERONA_API_KEY="ang_live_..."
Call it with the OpenAI SDK
JavaScript or TypeScript:
import OpenAI from "openai";
const client = new OpenAI({
apiKey: process.env.ANGERONA_API_KEY,
baseURL: "https://api.angerona.chat/v1",
});
const r = await client.chat.completions.create({
model: "deepseek-v4.1-flash",
messages: [{ role: "user", content: "Write a haiku about silence." }],
});
console.log(r.choices[0].message.content);
Python:
import os
from openai import OpenAI
client = OpenAI(api_key=os.environ["ANGERONA_API_KEY"], base_url="https://api.angerona.chat/v1")
r = client.chat.completions.create(
model="claude-sonnet-5.5",
messages=[{"role": "user", "content": "Explain zero-knowledge proofs in two sentences."}],
)
print(r.choices[0].message.content)
curl:
curl https://api.angerona.chat/v1/chat/completions \
-H "Authorization: Bearer $ANGERONA_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"gpt-4o-mini","messages":[{"role":"user","content":"Hello!"}]}'
Stream the answer
const stream = await client.chat.completions.create({
model: "claude-sonnet-5.5",
stream: true,
messages: [{ role: "user", content: "Tell me a short story." }],
});
for await (const chunk of stream) process.stdout.write(chunk.choices[0]?.delta?.content ?? "");
The final chunk reports usage: prompt tokens and completion tokens.
Images and video use the same client
const img = await client.images.generate({ model: "seedream-4.5", prompt: "a lighthouse at dusk, oil painting", size: "1024x1024" });
console.log(img.data[0].url); // temporary link, valid about 20 minutes
const job = await client.videos.create({ model: "your-video-model-id", prompt: "a paper boat on a rainy street", seconds: "6" });
// poll client.videos.retrieve(job.id) until status is "completed", then client.videos.downloadContent(job.id)
A safety check screens media prompts ahead of generation and refuses clearly illegal content. Video is a beta feature.
Retrying images safely: put an id of your choice in the X-Angerona-Request-Id header (8–64 characters of letters, digits, _ or -), for example client.images.generate(params, { headers: { "X-Angerona-Request-Id": id } }). After a dropped connection, GET /media/by-request/{id} hands back the images, and sending the same id again can't generate or bill a second time. Billing happens at delivery, and an undelivered image refunds itself.
The API has eight endpoints
| Method | Path | OpenAI SDK |
|---|---|---|
| GET | /v1/models | client.models.list() |
| POST | /v1/chat/completions | client.chat.completions.create() |
| POST | /v1/images/generations | client.images.generate() |
| GET | /media/by-request/{id} | Recovers an image request by its X-Angerona-Request-Id |
| POST | /v1/videos | client.videos.create() |
| GET | /v1/videos/{id} | client.videos.retrieve() |
| GET | /v1/videos/{id}/content | client.videos.downloadContent() |
| DELETE | /v1/videos/{id} | client.videos.delete() (cancels the job) |
The API keeps as little as the app
- A hash is all we hold of a key. Request logs, prompts, replies and IP addresses never get saved.
- A key's record is its name, creation date, optional spend cap and spend so far this month.
- Generated files lose GPS and device metadata and keep AI-provenance labels.
More on Data handling.