ZCode - 58API configuration tutorial
Access 58API through "Create Custom Supplier" in ZCode, fill in the Base URL and add the model according to the three API formats: Anthropic Messages, Responses, and Chat Completions.
ZCode is an Agentic Development Environment (ADE) launched by Z.ai, which provides desktop, browser workspace and terminal Agent, and has been open sourced on GitHub under the Apache-2.0 protocol. This tutorial introduces how to create a custom supplier access 58API in ZCode and use models such as Claude, GLM, DeepSeek, GPT, and Gemini in the same ZCode.
Must read: Whether the Base URL should contain /v1 depends on the API format
- Chat Completions and Responses format: ZCode will not automatically complete
/v1, Base URL must be filled inhttps://api.58api.net/v1. If you only fill inhttps://58api.net, the request will be sent tohttps://58api.net/chat/completions, was redirected to the 58API official website, and the call failed. - Anthropic Messages Format: ZCode will automatically fill in
/v1,fillhttps://api.58api.netThat’s it; fill inhttps://api.58api.net/v1It can also be used normally and will not become/v1/v1。 - Do not use any format
/chat/completions、/responsesor/v1/messagesWrite the Base URL, and the interface path will be automatically spliced by ZCode according to the API format. - In the text of ZCode official configuration document, the example addresses of OpenAI and OpenRouter are not included.
/v1. Do not copy when accessing 58API, please refer to this page.
- Official website:https://zcode.z.ai/cn
- Official model configuration document:https://zcode.z.ai/cn/docs/configuration
- Open source warehouse:https://github.com/zai-org/ZCode
This article is written based on ZCode 3.14.5 desktop version. If the interface text is slightly different, please follow the path "Settings → Model Settings → Add Supplier → Create Custom Supplier".
Configuration quick check
| ZCode configuration items | Fill in the content |
|---|---|
| Entrance | Settings → Model Settings → Add Supplier → Create Custom Supplier |
| name | Modify it through "Rename" in the "..." menu in the upper right corner of the card, for example 58API、58API-GPT、58API-Chat |
| Base URL | See the table below, pay attention to whether to bring /v1 |
| API format | Each supplier can only choose one, see the table below |
| API Key | The key created on the "API Key" page of the 58API console |
| Model | Click "Add Model" and manually fill in the model ID and context window |
Base URL corresponding to the three API formats:
| API format (ZCode interface display) | Base URL | Actual request address | Recommended model |
|---|---|---|---|
| Anthropic Messages (/v1/messages) | https://api.58api.net | https://api.58api.net/v1/messages | Claude、GLM、DeepSeek、Kimi、Qwen、MiniMax、MiMo |
| Responses (/responses) | https://api.58api.net/v1 | https://api.58api.net/v1/responses | GPT |
| Chat Completions (/chat/completions) | https://api.58api.net/v1 | https://api.58api.net/v1/chat/completions | Gemini、Grok |
If you want to save trouble, you can also fill in the three formats uniformly. https://api.58api.net/v1: Anthropic Messages format has detected that the address has been /v1 It will not be appended repeatedly at the end.
Preparation before use
- Download and install the latest version of ZCode (supports macOS, Windows x64 / ARM64 and Linux).
- Register and log in to 58API console https://58api.net, confirm that the account has available balance.
- Create an API Key on the "API Key" page of the 58API console and confirm that the group it belongs to contains the model you plan to use.
- Confirm the model ID to be added from the 58API model list.
- Prepare a test project directory. ZCode can read and modify workspace files and execute commands. For the first test, it is recommended to use a project that is easy to roll back.
It is recommended to create a separate API Key for ZCode and set the quota as needed. Do not include the complete key in tutorials, screenshots, project files, or chat messages.
1. Download and install ZCode
Open ZCode official website https://zcode.z.ai/cn, download the installation package for the corresponding system and complete the installation.
When starting up for the first time, the "Connect Z.ai / BigModel to continue using" and "Use API key" provided on the welcome page are only used for Zhipu's own services (the provider of "Use API key" can only choose Z.ai or BigModel), Do not fill in the 58API key here. You can click "Use API key", then click "Skip Temporarily" at the bottom of the form to enter the main interface, and then add 58API to the model settings as follows.
2. Obtain 58API key
Go to the API Keys page of the 58API console, create or select an existing key, and copy the API Key.

The API Key should only be pasted into ZCode's vendor configuration and not saved to the project repository.
3. Open the model settings and create a custom supplier
- Open ZCode's "Settings → Model Settings". You can also click the current model name in the chat input box and select "Manage Model" to enter the same page.
- Click "Add Supplier" at the bottom of the supplier list on the left.
- Click "Create Custom Supplier" in the "Other" group on the "Add Supplier" page. Do not choose preset templates such as OpenAI, Anthropic, DeepSeek, etc., as they are pre-filled with the official addresses of each company. ZCode will immediately create a supplier named "New Supplier" and open its configuration card.
- Click the "..." menu in the upper right corner of the card, select "Rename", and change the name to
58API。 - Complete the following table for your first supplier (Anthropic Messages format):
| Field | Fill in the value | illustrate |
|---|---|---|
| Base URL | https://api.58api.net | ZCode will automatically add /v1,fill https://api.58api.net/v1 OK |
| API format | Anthropic Messages (/v1/messages) | The default format for creating a new custom supplier is this format, which is suitable for Claude and domestic models. |
| API Key | Your 58API API Key | Paste the complete key without spaces before and after it |
- Click "Add Model" under "Model List" and fill in the model ID and context window. See the recommended list in the next section for model IDs.
- Confirm that the supplier's enable switch in the upper right corner of the card is turned on.
Note the following points:
- Supplier cards do not have a separate "Save" button. The name, Base URL, API format, and API Key will be automatically saved after the input box is out of focus or input stops, and a "save successfully" message will be displayed.
- The newly created custom supplier does not have any models, and the model list will not be automatically pulled. You need to click "Add Model" one by one to fill it in manually; you can only select it in the chat after adding at least one model.
- The context window must be a positive integer. If the Add Model window prompts "Matched to Intelligent Configuration", the context window can be left blank and directly use the recommended value shown in gray in the input box; otherwise, please fill it in according to the actual capabilities of the model. If you are not sure, fill in a conservative value first, for example
128000。 - When ZCode saves, it will only remove the
/, will not delete redundant interface paths for you. The placeholder for the Base URL input box also has/v1ofhttps://api.example.com/v1。
4. Recommended configuration: Create one supplier for each API format
Each ZCode provider can only choose one API format. Different models of 58API support different protocols. It is recommended to set up three suppliers as follows. They can use the same 58API API Key.
Only add models that are actually available to the account
The following model IDs are from the 58API current model list. Please only add models that are actually available in the group your API Key belongs to. The model ID must be filled in exactly as it is, including upper and lower case, periods, and hyphens. Do not add videos, raw images, or speech models (e.g. veo-3.1、gpt-image-2、gemini-3.1-flash-tts), they cannot be used for ZCode's conversational and programming tasks.
Supplier 1: Anthropic Messages (Claude and domestic models)
| Field | Fill in the value |
|---|---|
| name | 58API |
| Base URL | https://api.58api.net |
| API format | Anthropic Messages (/v1/messages) |
Recommended model:
| Model ID | illustrate |
|---|---|
claude-sonnet-5-5 | Claude, daily programming main force |
claude-opus-5-5 | Claude, for complex tasks |
claude-haiku-5-5 | Claude, lightweight and fast |
glm-5.3 | GLM |
deepseek-v4-pro | DeepSeek |
deepseek-v4.1-flash | DeepSeek, lightweight and fast |
kimi-k3 | Kimi |
qwen3.8-max | Qwen |
MiniMax-M3 | MiniMax, pay attention to capitalization |
mimo-v2.6-pro | Xiaomi MiMo |
Supplier 2: Responses (GPT)
| Field | Fill in the value |
|---|---|
| name | 58API-GPT |
| Base URL | https://api.58api.net/v1(Must bring /v1) |
| API format | Responses (/responses) |
Recommended model:
| Model ID | illustrate |
|---|---|
gpt-6.1-sol | GPT, the latest programming powerhouse |
gpt-6-astra | GPT flagship, suitable for complex tasks |
Vendor Three: Chat Completions (Gemini and Grok)
Gemini and Grok models do not support the Anthropic protocol on 58API, and a separate provider of Chat Completions format needs to be built.
| Field | Fill in the value |
|---|---|
| name | 58API-Chat |
| Base URL | https://api.58api.net/v1(Must bring /v1) |
| API format | Chat Completions (/chat/completions) |
Recommended model:
| Model ID | illustrate |
|---|---|
gemini-3.1-pro-preview | Gemini, suitable for complex tasks |
gemini-3.8-flash | Gemini, lightweight and fast |
grok-4.7 | Grok |
After all three suppliers are created, confirm that their enable switches are turned on.
5. Select a model and test it
- Open or create a new session and select the project directory you want to test.
- Click the model name in the chat input box.
58API、58API-GPTor58API-ChatSelect a model below. - First send a read-only task:
请概括当前项目的目录结构,先不要修改文件,也不要运行安装命令。After confirming that it can be restored normally, test a modification task with a clear scope and easy rollback. It is recommended that each of the three suppliers select a model and test it once to confirm that the Base URL of each API format is filled in correctly.
In the model list of "Settings → Model Settings", there is a "Test Model" button on the right side of each model, which can be used to quickly check the connection; the corresponding provider needs to be enabled before testing.
6. Verify the request on 58API
Open the 58API console, enter "Usage Log", and confirm that the request record just now appears.

Key points to check:
- The request uses the model just selected;
- Status successful, no continuous retries;
- The token and fee are consistent with the scale of the test task;
- The request time is consistent with the ZCode test time.
Verification Checklist
- The 58API supplier has been added through "Create Custom Supplier" and the enable switch has been turned on;
- The Anthropic Messages vendor's Base URL is
https://api.58api.net(orhttps://api.58api.net/v1); - The Base URL for the Responses and Chat Completions provider is
https://api.58api.net/v1; - Each vendor has added at least one model, and the model ID is exactly the same as the 58API model list;
- The 58API model can be seen and selected in the model selector of the chat input box;
- Simple read-only tasks can be restored normally;
- 58Corresponding requests appear in API usage logs.
FAQ
Return 404, 301, or the error content is a piece of webpage HTML
The Base URL is almost always filled in incorrectly. Check each item by API format:
- Chat Completions and Responses Format: Base URL must be
https://api.58api.net/v1. omission/v1, the request will be sent tohttps://58api.net/chat/completionsorhttps://58api.net/responses, was redirected to the 58API official website by 301, and the web page was returned instead of the interface data. - Anthropic Messages Format: Fill in
https://api.58api.netorhttps://api.58api.net/v1It will be all right. - Do not add after the Base URL
/chat/completions、/responsesor/v1/messages. ZCode will not automatically delete these paths and will spell them into something likehttps://api.58api.net/v1/chat/completions/chat/completionswrong address.
The OpenAI example in the official ZCode document is written as https://api.openai.com, OpenRouter writes https://openrouter.ai/api, not even brought /v1; But both OpenAI formats actually need to bring /v1. To access 58API, please fill in this page.
Prompt model not found or model does not exist
ZCode's custom provider does not automatically pull the model list, and the model ID needs to be filled in manually. Please go back to the 58API model list and copy the model ID as it is. The case, period and hyphen cannot be changed. For example MiniMax-M3 cannot be written as minimax-m3. Do not fill in a numeric ID, Chinese display name, or self-made alias.
Also make sure the model is placed under the correct format provider: for example Gemini and Grok models cannot be added to the Anthropic Messages format provider.
Prompt that there are no available channels under the current group
The group to which the API Key belongs must contain the group to which the model belongs. Go to the "API Keys" page of the 58API console to check the grouping settings for this key; if necessary, create a separate key for ZCode with the appropriate grouping, or use a model available for the current grouping instead.
Prompt 401 or authentication failed
Copy the API Key from the 58API console again, check whether there are spaces or newlines before and after, and confirm that the key is not disabled and the quota is available. The three suppliers need to fill in the API Key respectively, and modifying one of them will not be synchronized to the other suppliers.
DeepSeek returns 400 after selecting the highest thinking intensity
ZCode displays the optional thinking intensity by model. If you select the highest gear for the DeepSeek model (e.g. max) and return 400 parameter error, change the thinking intensity to high Try again.
The 58API model cannot be seen in the model selector
Go back to "Settings → Model Settings" and check item by item: the enable switch of the corresponding supplier is turned on; at least one model has been added to the supplier's "Model List", and the model itself has not been disabled. The newly created custom supplier does not have any model by default. You need to click "Add Model" first to fill in the model ID and context window.
Need to access the network through a proxy
ZCode does not read system data by default HTTP_PROXY / HTTPS_PROXY environment variables. If your network requires a proxy to access https://api.58api.net, please fill in the proxy address in "HTTP Proxy" in ZCode settings (for example http://127.0.0.1:7890), the modification will take effect only after restarting ZCode.
DeepSeek Harness - 58API Configuration Tutorial
Add 58API custom provider in DeepSeek Harness Web UI, configure Responses protocol and DeepSeek model
WorkBuddy - 58API configuration tutorial
Add the 58API model through the "custom" supplier in Tencent WorkBuddy, and fill in the interface address https://58API.net/v1