Quickstart
Get your first API call running in under 2 minutes.
1
Create your account
Sign up at theconflux.com/signup. You get 500 free credits immediately — no credit card required.
json
1
2
3
4
5
6
{
"user_id": "usr_a1b2c3d4",
"email": "you@example.com",
"credits_balance": "docs-token-number">500,
"plan": "free"
}2
Generate an API key
Go to your dashboard and generate a key, or use the API directly:
bash
1
2
3
4
5
6
# After signing in, generate a key from your dashboard
# Or use the API:
"docs-token-command">curl https://theconflux.com/v1/keys/generate \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name": "My App Key"}'json
1
2
3
4
5
6
7
{
"id": "key_abc123",
"api_key": "cf_live_x7k9m2p4q8r1s5t6",
"key_prefix": "cf_live_x7k9m2",
"name": "My App Key",
"warning": "Save this key now. It cannot be retrieved later."
}3
Call the API
Use curl, the OpenAI SDK, or any OpenAI-compatible client:
bash
1
2
3
4
5
6
7
8
9
"docs-token-command">curl https://theconflux.com/v1/chat/completions \
-H "Authorization: Bearer cf_live_x7k9m2p4q8r1s5t6" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-4o-mini",
"messages": [
{"role": "user", "content": "Explain quantum computing in one sentence."}
]
}'json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
{
"id": "chatcmpl-abc123",
"object": "chat.completion",
"created": "docs-token-number">1711660800,
"model": "gpt-4o-mini",
"choices": [
{
"index": "docs-token-number">0,
"message": {
"role": "assistant",
"content": "Quantum computing harnesses quantum mechanical phenomena like superposition and entanglement to process information in fundamentally new ways."
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": "docs-token-number">14,
"completion_tokens": "docs-token-number">28,
"total_tokens": "docs-token-number">42
}
}