Table of Contents
What is TokenEase?
TokenEase is a unified API gateway for Chinese AI models. Instead of signing up for 5 different providers, you get one API key that works with:
- DeepSeek V4 - Best reasoning and coding
- GLM-5.1 - Top Chinese language model
- Qwen-Plus - Strong multilingual capabilities
- Kimi K2.6 - 2M token context window
- Doubao Pro - Fastest responses
All models use the OpenAI-compatible API format. If you've used OpenAI's API before, you already know how to use TokenEase.
Step 1: Get Your Free API Key
1. Sign up at tokenease.io
Go to tokenease.io and click "Get Started Free". Enter your email address.
2. Verify your email
Check your inbox for a verification email and click the link. Your API key will be sent to you automatically.
3. Save your API key
Your API key looks like te-xxxxxxxxxxxxxxxx. Copy it and keep it secure - you'll use it in every API request.
Step 2: Make Your First API Call
Choose your preferred language and run the code below. Replace your_api_key_here with your actual key.
Python
# Install: pip install openai
from openai import OpenAI
client = OpenAI(
base_url="https://tokenease.io/v1",
api_key="your_api_key_here"
)
response = client.chat.completions.create(
model="deepseek",
messages=[{"role": "user", "content": "Hello! What can you help me with?"}]
)
print(response.choices[0].message.content)
Node.js
// Install: npm install openai
import OpenAI from 'openai';
const client = new OpenAI({
baseURL: 'https://tokenease.io/v1',
apiKey: 'your_api_key_here'
});
const response = await client.chat.completions.create({
model: 'deepseek',
messages: [{ role: 'user', content: 'Hello! What can you help me with?' }]
});
console.log(response.choices[0].message.content);
cURL
curl https://tokenease.io/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer your_api_key_here" \
-d '{
"model": "deepseek",
"messages": [{"role": "user", "content": "Hello! What can you help me with?"}]
}'
Step 3: Try Different Models
Changing models is as simple as changing one string:
# DeepSeek for coding
response = client.chat.completions.create(
model="deepseek",
messages=[{"role": "user", "content": "Write a Python function to reverse a string"}]
)
# GLM for Chinese content
response = client.chat.completions.create(
model="zhipu",
messages=[{"role": "user", "content": "写一首关于春天的诗"}]
)
# Qwen for translation
response = client.chat.completions.create(
model="qwen",
messages=[{"role": "user", "content": "Translate 'Hello world' to Japanese, French, and German"}]
)
# Kimi for long documents
response = client.chat.completions.create(
model="kimi",
messages=[
{"role": "system", "content": "Summarize the following article:"},
{"role": "user", "content": "[paste a 50,000 word article here]"}
]
)
| Model | Best For | Speed |
|---|---|---|
deepseek | Coding, reasoning, writing | Fast |
zhipu | Chinese content, structured data | Fast |
qwen | Translation, multilingual | Fast |
kimi | Long documents, analysis | Moderate |
doubao | Quick chat, low latency | Fastest |
Step 4: Streaming Responses
For a better user experience, stream responses word by word:
stream = client.chat.completions.create(
model="deepseek",
messages=[{"role": "user", "content": "Tell me a short story"}],
stream=True
)
for chunk in stream:
if chunk.choices[0].delta.content:
print(chunk.choices[0].delta.content, end="", flush=True)
What's Next?
Now that you've made your first API call, here are some next steps:
- Build a chatbot - See our complete chatbot tutorial
- Migrate from OpenAI - Follow our migration guide
- Build multi-model apps - Learn smart model routing
- Check your usage - Monitor token consumption in your dashboard
- Upgrade your plan - When free credit runs out, choose a plan that fits your needs
Common Issues
| Issue | Solution |
|---|---|
| 401 Unauthorized | Check your API key is correct and includes the te- prefix |
| 429 Rate Limited | Wait a moment and retry, or upgrade your plan |
| Empty response | Check that messages is properly formatted as an array |
| Model not found | Use exact model names: deepseek, zhipu, qwen, kimi, doubao |
Ready to Start Building?
Get your free API key and make your first call in 60 seconds
Get Free API Key →