Cline is a VS Code extension for AI-assisted coding. You can connect it to Alibaba Cloud Model Studio using Token Plan (Personal Edition), Token Plan (Team Edition), Coding Plan, or Pay-as-you-go.
Install Cline
-
Download and install VSCode.
-
Open VSCode, search for
Clinein the extension marketplace, and install it.
Configure credentials
After installation, click the Cline icon in the left sidebar to open the configuration interface. Click Bring my own API key, select OpenAI Compatible as the API Provider, and fill in the parameters for your billing plan. If you have used Cline before, click the settings icon in the upper-right corner to open the configuration interface.
Model Studio offers the following billing plans. Select the one that fits your needs:
-
Token Plan (Personal Edition): Deducts personal Credits based on token consumption.
-
Token Plan (Team Edition): Seat-based subscription. Token consumption is deducted from Credits.
-
Coding Plan: Fixed monthly subscription. Billed by number of model calls.
-
Pay-as-you-go: Post-paid based on actual usage.
Token Plan (Personal Edition)
|
Parameter |
Description |
|
API Provider |
Select OpenAI Compatible. |
|
Base URL |
|
|
API Key |
Enter the Token Plan (Personal Edition) dedicated API Key. |
|
Model ID |
Enter a Token Plan (Personal Edition) supported model, such as |
Token Plan (Team Edition)
|
Parameter |
Description |
|
API Provider |
Select OpenAI Compatible. |
|
Base URL |
|
|
API Key |
Enter the Token Plan (Team Edition) dedicated API key. |
|
Model ID |
Enter a Token Plan (Team Edition) supported model, such as |
Coding Plan
|
Parameter |
Description |
|
API Provider |
Select OpenAI Compatible. |
|
Base URL |
|
|
API Key |
Enter the Coding Plan dedicated API key. |
|
Model ID |
Enter a Coding Plan supported model, such as |
Pay-as-you-go
|
Parameter |
Description |
|
API Provider |
Select OpenAI Compatible. |
|
Base URL |
Enter the URL for your region, replace
|
|
API Key |
Enter the Model Studio API Key for the corresponding region. |
|
Model ID |
Enter a supported model. |
If you use Qwen3 (thinking mode) or the QwQ model, click MODEL CONFIGURATION in the settings interface and check Enable R1 messages format.
Use case: 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+.
-
Tell Cline to install Bailian CLI:
Please install the Alibaba Cloud Bailian CLI globally: npm install -g bailian-cli -
Go to the Bailian console to get your API Key, then tell Cline to configure it:
My API Key is: sk-xxxxxxxxxxxxx -
Describe what you need in natural language, for example:
Generate 6 Amazon e-commerce hero images for a white wireless Bluetooth headset.Generate a 30-second product demo video for a white wireless Bluetooth headset.
FAQ
Error codes
If you encounter errors during configuration, refer to the FAQ documentation for the corresponding billing plan:
-
Pay-as-you-go: Error codes
-
Coding Plan: Coding Plan FAQ
-
Token Plan (Personal Edition): Token Plan FAQ
-
Token Plan (Team Edition): Token Plan (Team Edition) FAQ
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
Click MODEL CONFIGURATION in the settings interface and check Enable R1 messages format.