Cline
Use Alibaba Cloud Model Studio models in Cline.
Quick Start
- 1
Get an API Key
Obtain an API Key for your billing plan:
- Token Plan Personal Edition: Create or view API Key
- Token Plan Team Edition: Assign a seat and get the API Key
- Pay-as-you-go: Model Studio API Key
- Coding Plan: Coding Plan API Key
- 2
Configure the model
Open the Cline panel, click Bring my own API key, set API Provider to OpenAI Compatible, and enter the values for your billing plan. If Cline has been configured before, click the settings icon in the upper-right corner to open the configuration interface.
Token Plan
Item Value Base URL https://token-plan.cn-beijing.maas.aliyuncs.com/compatible-mode/v1API Key Token Plan API Key Model ID Enter a text generation model supported by Personal Edition or Team Edition Pay-as-you-go
Replace
{WorkspaceId}with your actual Workspace ID.Item Value Base URL https://{WorkspaceId}.cn-beijing.maas.aliyuncs.com/compatible-mode/v1API Key Alibaba Cloud Model Studio API Key Model ID For example, qwen3.8-maxorqwen3.8-flashCoding Plan
Item Value Base URL https://coding.dashscope.aliyuncs.com/v1API Key Coding Plan API Key Model ID Enter a supported text generation model - 3
Verify
Send a message in the Cline chat panel. A normal response confirms the configuration.
Integrate Bailian CLI
Bailian CLI registers a Skill at ~/.cline/skills/bailian-cli/ during installation, allowing Cline to invoke Bailian capabilities through conversation. For the full capability list, see the Bailian CLI console. Prerequisite: Node.js 18+.
- 1
Install Bailian CLI
In the Cline chat, run:
Please install the Alibaba Cloud Bailian CLI globally: npm install -g bailian-cli - 2
Configure the API Key
Obtain an API Key, then ask Cline to configure it in the chat.
Error Codes
If you encounter errors during configuration, refer to the FAQ for your billing plan:
- Token Plan: Personal Edition FAQ · Team Edition FAQ
- Pay-as-you-go: Error codes
- Coding Plan: Coding Plan FAQ
FAQ
How do I use savings plans and resource plans with pay-as-you-go?
The pay-as-you-go setup remains the same: use your general Model Studio API key and Base URL. After you purchase a savings plan or resource plan, it takes effect automatically and eligible usage is deducted automatically. See Savings plans and resource plans.
Error: 401 Incorrect API key provided
Possible causes:
- The API Key does not match the Base URL. API Keys are not interchangeable across billing plans. Verify that the API Key and Base URL belong to the same plan.
- For Pay-as-you-go, the API Key region does not match the Base URL region. Verify that both correspond to the same region.
Error: 400 InternalError.Algo.InvalidParameter
When using Qwen3 thinking mode or the QwQ model, click MODEL CONFIGURATION in the settings interface and check Enable R1 messages format.