API Reference
The deathaiaustralia inference API is OpenAI-compatible. If you already use the OpenAI SDK, change the base URL and swap in your API key — nothing else needs to change.
https://deathaiaustralia.com.au
Authentication
All /v1/* endpoints require a Bearer API key. Keys are issued from the dashboard.
Authorization: Bearer YOUR_API_KEY
Rate Limits
Limits reset at midnight UTC. Requests over the daily limit receive a 429 response.
| Tier | Requests/day | Models |
|---|---|---|
| free | 100 | aiaus-1 |
| pro | 10,000 | all models |
Rate limit headers are included in every response:
X-RateLimit-Limit: 100 X-RateLimit-Remaining: 87 X-RateLimit-Reset: 2024-01-15T00:00:00Z
Errors
All errors return JSON with an error field:
{ "error": "Invalid or revoked API key" }
| Code | Meaning |
|---|---|
401 | Missing or invalid API key |
403 | Key is revoked |
429 | Daily rate limit exceeded |
400 | Bad request — missing fields or invalid model |
500 | Inference backend error |
503 | Model loading or server busy |
POST /v1/chat
Stream a chat completion. Response is NDJSON server-sent events — OpenAI-compatible.
Request body
| Field | Type | Description |
|---|---|---|
| modelrequired | string | Model ID. See /v1/models for available models. |
| messagesrequired | array | Array of { role, content } objects. Roles: user, assistant, system. |
| systemoptional | string | System prompt. Prepended to messages as a system role. |
| temperatureoptional | number | Sampling temperature 0–2. Default: 0.8 |
| max_tokensoptional | integer | Max tokens to generate. Default: 512 |
| streamoptional | boolean | Whether to stream. Always treated as true for SSE. |
Example
# Streaming chat request curl -N -X POST https://deathaiaustralia.com.au/v1/chat \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "aiaus-1", "messages": [ { "role": "user", "content": "What is the VITA language?" } ], "temperature": 0.8, "max_tokens": 512 }'
Response (SSE stream)
# Each line is a server-sent event data: {"choices":[{"delta":{"content":"VITA"}}]} data: {"choices":[{"delta":{"content":" is"}}]} ... data: {"choices":[{"delta":{"content":""},"finish_reason":"stop"}],"usage":{"prompt_tokens":12,"completion_tokens":48}} data: [DONE]
JavaScript (fetch + stream)
const res = await fetch('https://deathaiaustralia.com.au/v1/chat', { method: 'POST', headers: { 'Authorization': 'Bearer YOUR_API_KEY', 'Content-Type': 'application/json' }, body: JSON.stringify({ model: 'aiaus-1', messages: [{ role: 'user', content: prompt }] }) }); const reader = res.body.getReader(); const decoder = new TextDecoder(); while (true) { const { done, value } = await reader.read(); if (done) break; const lines = decoder.decode(value).split('\n'); for (const line of lines) { if (!line.startsWith('data: ')) continue; const raw = line.slice(6); if (raw === '[DONE]') break; const delta = JSON.parse(raw).choices?.[0]?.delta?.content || ''; process.stdout.write(delta); } }
GET /v1/models
List all available models. Includes base chat and embedding models, plus the full roster of persona models — each a distinct AI character you can embed directly in your product.
Example
curl https://deathaiaustralia.com.au/v1/models \
-H "Authorization: Bearer YOUR_API_KEY"
Response
{
"object": "list",
"data": [
{ "id": "aiaus-1", "type": "chat", "persona": false },
{ "id": "aiaus-embed", "type": "embedding", "persona": false },
{ "id": "aiaus-lilly", "type": "chat", "persona": true },
{ "id": "aiaus-zomb", "type": "chat", "persona": true },
{ "id": "aiaus-sirloin", "type": "chat", "persona": true },
{ "id": "aiaus-ivan", "type": "chat", "persona": true },
{ "id": "aiaus-nightshade","type": "chat", "persona": true },
{ "id": "aiaus-demonika", "type": "chat", "persona": true },
{ "id": "aiaus-luci", "type": "chat", "persona": true },
{ "id": "aiaus-unclechop", "type": "chat", "persona": true },
{ "id": "aiaus-debbie", "type": "chat", "persona": true }
]
}
Persona models
Persona models have a locked system prompt — the character's personality is baked in. You supply the conversation; they supply the voice. Passing a system field is ignored for persona models.
| Model ID | Character |
|---|---|
aiaus-lilly | Death goddess — dark wisdom, gothic warmth |
aiaus-zomb | Undead creature — enthusiastic, lovably broken grammar |
aiaus-sirloin | Nightclub bouncer — blunt, zero patience |
aiaus-ivan | Eastern European venue operator — fatalistic, dry menace |
aiaus-nightshade | Punk witch — sharp, cynical, encyclopaedic |
aiaus-demonika | Ancient demon — sardonic, powerful, endlessly amused |
aiaus-luci | The morning star — brilliant, disdainful, never boring |
aiaus-unclechop | Outback Australian — warm, weathered, full of stories |
aiaus-debbie | Punk grandma — no filter, been to every gig since '77 |
POST /v1/embeddings
Generate text embeddings. Returns a high-dimensional vector suitable for semantic search, clustering, and RAG pipelines.
Request body
| Field | Type | Description |
|---|---|---|
| inputrequired | string | Text to embed. |
| modeloptional | string | Default: aiaus-embed |
Response
{
"embedding": [0.023, -0.154, 0.891, /* ... */],
"model": "aiaus-embed",
"tokens": 12
}
GET /v1/usage
Retrieve usage statistics for all API keys associated with your account.
Response
{
"keys": [
{
"key_id": 1,
"name": "My App",
"tier": "free",
"requests_today": 42,
"requests_total": 387,
"limit_today": 100
}
]
}
POST /api/auth/login
Authenticate with username/email and password. Returns a session cookie used for browser-based access — the rotvice community, dashboard, etc.
{ "username": "yourusername", "password": "yourpassword" }
Response: { "user": { "id", "username", "email" } } + session cookie.
GET /api/auth/me
Returns the currently authenticated user based on the active session or Bearer token.
{ "id": 1, "username": "you", "email": "..." }
Returns 401 if not authenticated.
POST /api/auth/logout
Clears the session cookie.
Returns { "ok": true }.
GET /api/api-keys
List all API keys for the authenticated user, including today's usage.
[
{
"id": 1, "name": "My App",
"tier": "free", "revoked": false,
"requests_today": 42, "created_at": "2024-01-15T..."
}
]
POST /api/api-keys
Create a new API key. The full key is returned once in the response and never stored in plaintext.
{ "name": "My App", "tier": "free" }
{ "key": "YOUR_NEW_API_KEY", "id": 1 }
DELETE /api/api-keys/:id
Revoke an API key. Immediately invalidates all requests using that key. Cannot be undone.
Returns { "ok": true } on success. Returns 404 if key not found or belongs to another user.