Quickstart Guide
Attenval is an OpenAI-compatible API. Reserve access now. When you are invited, spend credits with standard OpenAI client libraries.
1. Reserve access
- Reserve access at /reserve. We’ll email you when Attenval opens.
- When you are invited, use the API with the key we send you:
- Live key format:
atv_live_YOUR_KEY - Test key format:
atv_test_...
- Live key format:
Security Note: The full key is shown only once. Store it yourself. Do not submit secrets in prompts. The steps below apply after you are invited.
2. Earn credits
Watch a verified spotlight in the app to earn 5,000 credits. You can complete up to 5 per day. Earned credits have a 30-day rolling expiry.
You can inspect your balance:
curl https://api.attenval.com/v1/credits \
-H "Authorization: Bearer atv_live_YOUR_KEY"
Example Response
{
"earned_available": 15000,
"earned_expires_at": "2026-09-16T12:00:00Z",
"purchased_available": 0,
"total_available": 15000
}
3. Make Your First Chat Completion
Set the baseURL to https://api.attenval.com/v1 and use an alias: attenval-auto (Auto), attenval-fast (Fast), attenval-code (Code), or attenval-smart (Smart). The amount a request uses depends on the alias.
cURL
curl https://api.attenval.com/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer atv_live_YOUR_KEY" \
-d '{
"model": "attenval-auto",
"messages": [
{ "role": "system", "content": "You are a concise technical assistant." },
{ "role": "user", "content": "Summarize how Attenval aliases work." }
],
"temperature": 0.7,
"max_tokens": 300
}'
Python (OpenAI SDK)
from openai import OpenAI
client = OpenAI(
api_key="atv_live_YOUR_KEY",
base_url="https://api.attenval.com/v1"
)
response = client.chat.completions.create(
model="attenval-auto",
messages=[
{"role": "system", "content": "You are a concise technical assistant."},
{"role": "user", "content": "Summarize how Attenval aliases work."}
],
temperature=0.7,
max_tokens=300
)
print(response.choices[0].message.content)
Node.js / TypeScript (OpenAI SDK)
import OpenAI from 'openai';
const client = new OpenAI({
apiKey: 'atv_live_YOUR_KEY',
baseURL: 'https://api.attenval.com/v1',
});
async function main() {
const completion = await client.chat.completions.create({
model: 'attenval-auto',
messages: [
{ role: 'system', content: 'You are a concise technical assistant.' },
{ role: 'user', content: 'Summarize how Attenval aliases work.' },
],
max_tokens: 300,
});
console.log(completion.choices[0]?.message.content);
}
main();
4. Response metadata
Successful completions include standard OpenAI fields plus an attenval object:
{
"id": "chatcmpl-atv-9f8a3d12bc",
"object": "chat.completion",
"created": 1786845600,
"model": "attenval-auto",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Pick Auto, Fast, Code, or Smart. The amount a request uses depends on the alias."
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 28,
"completion_tokens": 84,
"total_tokens": 112
},
"attenval": {
"requested_model": "attenval-auto",
"credits_used": 18,
"balance_remaining": 145932
}
}
attenval contains only requested_model, credits_used, and balance_remaining.
Next Steps
- Explore Model aliases
- Review the API Reference
- Handle Errors
- Read How you get credits