> For the complete documentation index, see [llms.txt](https://docs.cherryai.com.cn/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cherryai.com.cn/docs/zhong-wen-fan-ti/pre-basic/providers/newapi.md).

# NewAPI

Cherry Studio 已經內置 New API 服務供應商。一個 New API 地址可以同時連接 OpenAI Chat、OpenAI Responses、Anthropic Messages 同 Gemini 協議，唔需要為每種協議分別加服務供應商。

## 配置步驟

1. 喺 New API 管理後台建立同複製令牌；
2. 打開 Cherry Studio【設定】→【模型服務】→【New API】；
3. 填寫【API 密鑰】；
4. 喺【API 地址】填寫 New API 嘅根地址，例如 `https://api.example.com`；
5. 取得或者手動加入模型，完成【檢測】後打開右上角啟用開關。

Cherry Studio 會按所選協議自動使用對應版本路徑，例如 `/v1` 或者 `/v1beta`。通常只需要填一次根地址，唔好將 `/chat/completions` 等完整接口路徑貼入去。

{% hint style="warning" %}
如果曾經用過測試版，並且喺其他協議地址中保留咗 `localhost:3000` 等舊值，請入去 New API 設定，把非預設協議嘅舊地址清空一次，再重新檢測。否則部分模型可能仍然會請求舊地址。
{% endhint %}

<details>

<summary>中轉站使用無版本路徑點算？</summary>

只有當中轉站明確要求使用唔帶 `/v1` 或者 `/v1beta` 的路徑時，先喺對應 API 地址末尾加 `#`。`#` 表示唔再自動拼接版本路徑；普通 New API 部署唔好用。

</details>

{% hint style="info" %}
地址必須保留正確嘅 `http://` 或者 `https://`。使用 IP 同端口時，可以填寫類似 `http://127.0.0.1:3000` 嘅根地址。
{% endhint %}

***

### 取得幫助同提交意見

如果你喺配置或者使用過程中遇到任何疑問、Bug 或者有功能改善建議，請參考 [意見同建議](/docs/zhong-wen-fan-ti/question-contact/suggestions.md) 入面提供嘅官方渠道。


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.cherryai.com.cn/docs/zhong-wen-fan-ti/pre-basic/providers/newapi.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
