Cline - VS Code AI programming assistant
Configure the 58API address, key, and model in Cline to complete the first conversation and troubleshooting.
Scope of application
Cline is an AI programming assistant running in VS Code that can read code, modify files, and call terminal tools. This tutorial uses the OpenAI Compatible access method officially provided by Cline to connect to 58API.
- Official documentation:https://docs.cline.bot
- VS Code extensions:Cline(
saoudrizwan.claude-dev) - GitHub repository:https://github.com/cline/cline
Preparation before use
- Log in 58API, create an API Key in the console, and confirm that the account has available balance.
- Install the latest version Visual Studio Code。
- Confirm the model name you intend to use. The following is
gpt-6.1-solFor example (you can also useclaude-sonnet-5-5、deepseek-v4-proWait for the model listed in the console); if the model is not in your available list, replace it with the full model ID displayed by the console.
Install Cline
- In VS Code press
Ctrl+Shift+X(macOS isCommand+Shift+X) to open the extension panel. - search
@id:saoudrizwan.claude-dev。 - After confirming that the publisher and extension ID are correct, click Install/Install.
- After the installation is complete, click the Cline icon in the activity bar to open the sidebar.
Cline icon not found
You can press Ctrl+Shift+P(macOS is Command+Shift+P),enter Cline: Jump to Chat Input Open Cline and focus the input box, or search for other Cline commands. Command names may be adjusted from version to version, and the activity bar icon is always the more direct entry.
Configure 58API
Click the gear on the Cline interface to enter settings, and then complete the following configuration:
| Cline configuration items | Fill in the content |
|---|---|
| API Provider | OpenAI Compatible |
| Base URL | https://api.58api.net/v1 |
| API Key | API Key created in 58API console |
| Model ID | gpt-6.1-sol, or the full model ID actually available for the account |

The screenshot is the old version of the interface (the new version does not have Save / Cancel buttons, and the Model ID is a drop-down box).
The numbers in the figure correspond in order: ① Provider, ② Base URL, ③ API Key, ④ Model ID. API Key should be pasted with your real key; only the masked dots are shown in the image.
Specific steps:
- Switch API Provider to OpenAI Compatible, do not choose ordinary OpenAI.
- Fill in Base URL
https://api.58api.net/v1。 - Paste the 58API API Key in API Key.
- After filling in the Base URL and API Key, Cline will automatically request
https://api.58api.net/v1/models. When the list is loaded successfully, Model ID will turn into a drop-down box, and you can directly select the model available to the account (for examplegpt-6.1-sol); you can also select Use custom model ID… in the drop-down box to enter it manually. If the list is not loaded, the Model ID will be displayed as a normal input box. You can directly fill in the complete model ID and check whether the Base URL and API Key are correct. - After the settings are modified, they will be automatically saved. Click Done in the upper right corner of the settings page to return to the chat interface.
Cline 4.x will save the API Key in the local user directory in the form of a JSON file:~/.cline/data/settings/providers.json and ~/.cline/data/secrets.json(Windows is %USERPROFILE%\.cline\data\ file under the same name), the request is only sent to the Base URL you filled in. Do not write the API Key into the project file or submit it to Git, and do not synchronize, upload or share it. ~/.cline Table of contents.
How to fill in advanced parameters
It is recommended to keep the default values when connecting for the first time. If you need to adjust, expand MODEL CONFIGURATION:
- Supports Images: Check only when both the model and the 58API current interface support image input;
- Context Window Size: should be consistent with the actual model context length;
- Max Output Tokens: cannot be higher than the maximum output allowed by the model;
- Temperature: Generally left blank, the model default value is used.
Incorrectly declaring an ability can cause normal dialogue to succeed, but image input or long tasks to fail.
Image understanding
Switch Model ID to a vision-capable model (for example deepseek-v4.1-flash), click + next to the input to attach an image, then send your question.
first call
- Create a new task in Cline.
- First send a test message that will not modify the project:
请只回复“58API 已连接”,不要修改文件,也不要执行命令。- After receiving the normal reply, open the usage log of the 58API console and confirm that the corresponding request occurs.
Cline's OpenAI Compatible access will access the compatible interface based on the Base URL. Base URL only fill in /v1, do not fill in https://api.58api.net/v1/chat/completions, otherwise the client will generate an incorrect address when splicing the path again.
Start a programming task
After the connection is verified, you can open a code project and try:
阅读当前项目的 README 和目录结构,说明如何启动项目,暂时不要修改文件。After confirming that Cline understands the project correctly, let it perform modifications, tests, or terminal commands. Cline will display specific operations when you need to use a tool, just follow the interface prompts to confirm.
FAQ
No Base URL in settings
Confirm that API Provider is selected as OpenAI Compatible. Normal OpenAI providers use official fixed addresses and do not display the same custom fields.
Prompt 401 or Unauthorized
Copy the API Key from the 58API console again and make sure there are no spaces or line breaks before and after. Do not fill in VS Code login tokens, OpenAI web login information, or keys for other services.
Prompt 404 or interface not found
Base URL should be https://api.58api.net/v1. Do not add repeatedly /v1, also don’t put /chat/completions Enter the Base URL.
Tip Model Not Found
The Model ID must exactly match the actual model name available to the account, including case, hyphens, and version suffixes. First select from the Model ID drop-down box (the list comes from 58API's /v1/models); do not treat the example name as a fixed value when entering manually.
Can chat, but can't edit files or call tools
Agent operations rely on the model's tool calling capabilities. Use a normal conversation to confirm that the address and key are correct before switching to a model that explicitly supports tool calls; do not assume that the model has the capability just by checking the capability switch.
Still using the old model after modifying the configuration
Click Done to create a new task. If it still does not take effect, execute Developer: Reload Window or completely exit and restart VS Code, and then check the model displayed at the top of the current task.
official basis
- Cline: Install extension
- Cline: Configuring OpenAI Compatible API
- Cline: Configuration file and key storage location
- OpenAI Compatible configuration diagram officially released by Cline