Trae
Use Alibaba Cloud Model Studio models in [Trae](https://www.trae.ai/).
Quick Start
Sign in and configure it as follows.
Get the API Key for your billing plan:
- Token Plan: Token Plan API Key
- Pay-as-you-go: Model Studio API Key
- Coding Plan: Coding Plan API Key
In Trae, go to Settings > Models and click Add Model.
Token Plan
Select Custom Model and enter the following:
| Parameter | Value |
|---|---|
| API format | OpenAI-compatible |
| Request URL | https://token-plan.cn-beijing.maas.aliyuncs.com/compatible-mode/v1 |
| Model ID | Enter a text generation model supported by Personal Edition or Team Edition |
| API key | The Token Plan API Key from the previous step |
Pay-as-you-go
Select Alibaba Cloud, enter the Model Studio API Key from the previous step, and select a supported text generation model.
Coding Plan
Select Alibaba Cloud, enter the Coding Plan API Key from the previous step, and select a supported text generation model.
Select the configured model from the model list in the lower-right corner of the chat box and send a message. A reply confirms the configuration.
Error Codes
If you encounter errors during configuration, refer to the FAQ documentation for your billing plan:
- Token Plan Personal Edition: Token Plan Personal Edition FAQ
- Token Plan Team Edition: Token Plan Team Edition FAQ
- Pay-as-you-go: Error codes
- Coding Plan: Coding Plan FAQ
FAQ
401 Unauthorized when calling a model
The API Key does not match the selected plan, or the subscription has expired. Make sure the API Key type matches the selected plan, then get and enter the correct key again.
Model does not exist when calling a model
The model ID does not match the selected plan. Select a text generation model supported by the plan.