Cline integration

Use Cline with Chinese AI models through ChinaAPI.

Configure Cline's OpenAI Compatible provider once, then run agentic VS Code workflows on official-price Chinese models with one ChinaAPI key.

Prerequisites

What you need.

Cline extension

Install Cline in VS Code and open the Cline panel.

ChinaAPI token

Register, then go to Dashboard -> Console -> Tokens and copy an sk-... key.

Setup

Configure the OpenAI Compatible provider.

  1. Open the Cline settings panel from the gear icon or the API Provider dropdown below the chat area.
  2. Set API Provider to OpenAI Compatible.
  3. Set Base URL to https://dash.chinaapi.ai/v1.
  4. Paste your ChinaAPI token into API Key.
  5. Set Model or Model ID to an exact live ID such as kimi-k2.7-code or deepseek-v4-pro.
  6. Click Verify if your Cline version exposes that button, then send a short test message.

Copy-paste test

Test with a tiny Cline prompt.

After saving the provider, ask Cline:

Create a minimal Node.js function called summarizeFiles(paths) that returns file names and byte sizes. Do not modify files yet.

For a direct API smoke test, use:

curl https://dash.chinaapi.ai/v1/chat/completions \
  -H "Authorization: Bearer sk-..." \
  -H "Content-Type: application/json" \
  -d '{"model":"kimi-k2.7-code","messages":[{"role":"user","content":"Say Cline is connected."}],"stream":true}'

Recommended models

Good Cline defaults.

kimi-k2.7-code

Coding-focused default for repo work, planning, and edits.

deepseek-v4-pro

Use for harder debugging, refactors, and reasoning-heavy coding tasks.

qwen3.7-max

Flagship Qwen option for demanding analysis and agent workflows.

glm-5.2

Strong long-context choice for larger codebase understanding.

deepseek-v4-flash

Fast option for quick iterations and lighter Cline tasks.

Troubleshooting

Common Cline issues.

Thinking models such as qwen3.7-max can spend time generating reasoning tokens before answering. Enable streaming or raise the request timeout if Cline stops before the answer arrives.

Model not found: copy the exact ID from live pricing. Do not use display names like "DeepSeek V4" unless the pricing page shows that exact ID.

401: make sure the key starts with sk- and is in the API Key field for the OpenAI Compatible provider, not another provider profile.

Pricing and signup

Start with $1 free credit.

ChinaAPI bills in USD at official China list prices. Check live pricing before production use.