5-minute quickstart
Make your first API call in 5 minutes
One API key. One OpenAI-compatible endpoint. GPT-4o, Claude, Gemini, DeepSeek and Kimi K2 — switch models by changing a single string.
Drop-in for the OpenAI SDK — just change the base URL
Email-first signup, no credit card to start
Top up with USDT (TRC-20 / ERC-20)
Do you already have a Taotok API key?
Yes, I have a key
Skip to the code — 2 minutes
No, I need one
Sign up and create a key — 5 minutes
1
Get your API key
skip if you already have one
Pick an option above and this step adapts. Or read both:
Already have a key
Export it in your shell: export TAOTOK_KEY="sk-…"
Never commit it. Use an env var or a secret manager.
Open dashboard
Need a key
Sign up with your email — about 30 seconds.
Go to API Keys → Create new key.
Copy it once and save it in a password manager.
Create account & key
Already have a key
Export it in your shell: export TAOTOK_KEY="sk-…"
Never commit it. Use an env var or a secret manager.
Lost it? Create a new one — old keys can be disabled instantly.
Create an account and generate a key
Sign up with your email — about 30 seconds.
Go to API Keys → Create new key.
Copy it once and save it in a password manager.
2
Pick a model and copy the snippet
Choose a model and a language, then hit Copy. Everything is pre-filled — the only thing you supply is your key.
Model
Base URL
https://api.taotok.io/v1
⧉
cURL
Python
Node.js
Copy
Model IDs are case-sensitive and must match your dashboard's Models list exactly. Not sure? Run: curl https://api.taotok.io/v1/models -H "Authorization: Bearer $TAOTOK_KEY"
curl https://api.taotok.io/v1/chat/completions \
-H "Authorization: Bearer $TAOTOK_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-4o",
"messages": [
{ "role": "user", "content": "Reply with one short sentence." }
],
"max_tokens": 64
}'
3
Run it and read the response
Paste it into your terminal, or run the script. A 200 with text inside choices[0].message.content means you are live.
It worked — show me what's next
It failed — help me fix it
✓
You're live. Three things worth doing next
Most people stop at the first successful call. These three steps are what turn a first call into a habit.
Swap the model
Same code, different string. Try DeepSeek V3 for the cheapest tokens, Claude for long documents, Kimi K2 for agentic runs.
Compare models & prices →
Watch your usage
Open Usage to see tokens, spend and remaining balance. Set a monthly budget so a run never surprises you.
Open usage →
Join the Discord
Ask about models, report a failing endpoint, or request a rate-limit bump. Real devs answer fast.
Join Discord →
?
If the call fails
Almost every first-call failure is one of these four. Work top to bottom — about two minutes.
401 — invalid api key auth
Echo the variable: echo $TAOTOK_KEY. Empty means your shell never exported it.
Check the header literally: Authorization: Bearer YOUR_KEY — one space after Bearer, no quotes around the key.
Re-copy the key. A trailing space or line break pasted from the dashboard is the #1 cause.
Confirm the base URL is https://api.taotok.io/v1 — not http, no double /v1/v1.
Still stuck? Disable the key in the dashboard and issue a fresh one, then retry immediately.
429 — rate limited limits
Read the Retry-After response header and sleep that long, then retry.
Add exponential backoff: 1s, 2s, 4s, 8s with a bit of jitter.
Lower max_tokens and shorten the prompt — you are billed on tokens, and limits follow tokens.
Check your RPM/TPM tier on the Usage page; request a bump in Discord with your use case.
Bursty first tests (loops of 50 calls) trip limits that real traffic never will. Test with 1 call first.
404 / model not found — or a weird model name model
List what you can actually call: curl https://api.taotok.io/v1/models -H "Authorization: Bearer $TAOTOK_KEY"
IDs are case-sensitive. gpt-4o and GPT-4O are not the same thing.
Use the gateway ID, not the vendor's marketing name ("DeepSeek V3" → deepseek-chat).
Some models are plan-gated. If it is missing from /v1/models, ask in Discord to have it enabled.
Sanity check in the browser first: run the same prompt in the Playground to isolate gateway issues from your code.
402 / insufficient balance or quota billing
A first test call costs a fraction of a cent — if it fails on balance, the account simply has zero credit.
Open Usage to confirm the remaining balance before topping up.
Top up in USDT. TRC-20 is usually the cheapest and fastest to confirm.
Wait for the required confirmations; credit lands after the network confirms, not the moment you send.
Set a low-balance alert so this never stops a production job.
Timeout, TLS error, or nothing comes back network
Use https://. Plain http is not served.
Behind a corporate proxy or VPN? Retry from a different network to rule it out.
Add -v to curl to see the real status code and headers.
Confirm the path is /v1/chat/completions — a missing /v1 returns HTML or 404.
Cross-check in the Playground. Works there but not in your code? It is your request body, not the gateway.
Keep building — you've done the hard part
The first call is the whole battle. From here it is just swapping model strings and watching spend.
Availability varies by region. Taotok does not provide services to users in mainland China. Please make sure your use complies with your local laws and our Terms.
Email-first signup; no credit card is required to start. Additional verification may be required for higher limits, depending on usage and region.
© Taotok · API base : https://api.taotok.io/v1