๐Ÿš€ Quick Start

Get your first API call to China's best AI models in under 5 minutes

๐Ÿ’ก Prerequisite: Sign up at tokencnn.com/register โ€” just an email, no phone or ID required.

Step 1: Get Your API Key

1Log in to the Console

2Click Token Management in the sidebar

3Click Add Token, enter a name (e.g. "My App"), and create

4Copy the key immediately โ€” it won't be shown again

โš ๏ธ Never commit your API key to public repositories. If compromised, revoke it immediately in the console and create a new one.

Step 2: Make Your First API Call

tokencnn.com is 100% compatible with the OpenAI SDK. You only need to change the base_url.

Python

from openai import OpenAI

client = OpenAI(
    base_url="https://www.tokencnn.com",
    api_key="sk-your-key-here"
)

# Chat with DeepSeek
response = client.chat.completions.create(
    model="deepseek-chat",
    messages=[
        {"role": "system", "content": "You are a helpful assistant."},
        {"role": "user", "content": "What's the best Chinese AI model?"}
    ]
)
print(response.choices[0].message.content)

Node.js

import OpenAI from "openai";

const client = new OpenAI({
    baseURL: "https://www.tokencnn.com",
    apiKey: "sk-your-key-here",
});

const response = await client.chat.completions.create({
    model: "deepseek-chat",
    messages: [{ role: "user", content: "Hello from Node.js!" }],
});
console.log(response.choices[0].message.content);

cURL

curl https://www.tokencnn.com/v1/chat/completions \
  -H "Authorization: Bearer sk-your-key-here" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "deepseek-chat",
    "messages": [
      {"role": "user", "content": "Hello!"}
    ]
  }'

Step 3: Try Different Models

Change the model parameter to access different AI models. Here are some popular ones:

Model IDSourceBest For
deepseek-chatDeepSeekGeneral conversation, coding
deepseek-reasonerDeepSeekComplex reasoning, math
qwen-maxAlibaba CloudCreative writing, Chinese tasks
glm-4Zhipu AIGeneral, multilingual
kimi-k2Moonshot AILong context, document analysis

Get the full list: curl https://www.tokencnn.com/v1/models -H "Authorization: Bearer sk-..."

Step 4: Top Up (Optional)

New accounts start with a small free balance. When you need more:

1Go to Wallet Management โ†’ Quota Top-up

2Choose an amount ($10 โ€“ $500)

3Pay with credit card, PayPal, or crypto

4Funds are available instantly

Next Steps