OpenAI-Compatible Setup Guide
Use CherryIN with Cline, Dify, n8n, Chatbox, CherryStudio, and other OpenAI-compatible tools
Who is this for?
If your tool supports any of the following setup styles, you can use this guide directly:
- OpenAI
- OpenAI Compatible
- Custom OpenAI
- A manual
Base URL+API Keysetup
Typical examples include Cline, Dify, n8n, CherryStudio, Chatbox, and most AI clients or workflow tools that support the OpenAI protocol.
You only need 3 values
| Field | What to enter | Example |
|---|---|---|
Base URL | CherryIN's OpenAI-compatible endpoint | https://open.cherryin.net/v1 |
API Key | The token you created in the CherryIN console | sk-xxxxxxxx |
Model ID | Full model name in provider/model format | anthropic/claude-sonnet-4.5 |
Token Group Tip
For most users, a default group token is the easiest option because it can access more models directly. If you want discounted models from a promotional group, make sure the token and model group match. See Quick Start.
What these fields are usually called in tools
| Tool field name | What you should enter |
|---|---|
API Provider / Provider | Select OpenAI, OpenAI Compatible, or Custom OpenAI |
Base URL / API Base URL / Endpoint | https://open.cherryin.net/v1 |
API Key / Bearer Token | Your CherryIN API key |
Model / Model ID | For example anthropic/claude-sonnet-4.5 |
Organization ID | Usually leave blank |
Universal setup template
- Choose an
OpenAIorOpenAI Compatibleprovider in your tool. - Set
Base URLtohttps://open.cherryin.net/v1. - Paste your CherryIN key into
API Key. - Enter a full model ID such as
anthropic/claude-sonnet-4.5. - Save, test, or send a message to verify the setup.
Model Name Format
CherryIN model IDs must use the full provider/model format. For example, use anthropic/claude-sonnet-4.5, not just claude-sonnet-4.5.
When should you use Chat Completions vs Responses?
| Scenario | Recommended API |
|---|---|
| Most chat tools, IDE assistants, and workflow nodes | Chat Completions |
| A tool lets you choose the raw API mode and you want to use a GPT-5.x model | Responses API |
GPT-5.x Compatibility
For GPT-5.x models such as openai/gpt-5.2-chat, prefer the Responses API instead of Chat Completions.
Chat Completions example
curl https://open.cherryin.net/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer sk-xxxxxxxx" \
-d '{
"model": "anthropic/claude-sonnet-4.5",
"messages": [
{"role": "user", "content": "Hello, introduce yourself in one sentence."}
]
}'Responses API example
curl https://open.cherryin.net/v1/responses \
-H "Content-Type: application/json" \
-H "Authorization: Bearer sk-xxxxxxxx" \
-d '{
"model": "openai/gpt-5.2-chat",
"input": "Summarize CherryIN setup in 3 bullet points."
}'Common issues
1. 401 Unauthorized
Usually caused by one of these:
- The API key was copied incorrectly
- There is an extra space or newline in the key
- The tool isn't sending the key as a Bearer token
2. Model not found
Make sure you're using the full model ID, for example:
- Correct:
anthropic/claude-sonnet-4.5 - Incorrect:
claude-sonnet-4.5
3. The tool only says OpenAI, not OpenAI Compatible
That can still work if the tool lets you manually set a custom Base URL. If it doesn't allow a custom endpoint at all, it usually can't connect to CherryIN directly.
4. GPT-5.x request fails
Check whether the tool is hardcoded to /chat/completions. If so, switch to a setup that supports the Responses API, or test with a non-GPT-5.x model first.
Next steps
- For IDE coding workflows: see Cline Setup Guide
- For app orchestration: see Dify Setup Guide
- For workflow automation: see n8n Setup Guide
- For direct code examples: see Code Tutorial
CherryIN