https://www.bettertoken.ai/v1, use an API Key from the GPT Key group, and select the matching model from the model list.
Prerequisites
- An n8n Cloud or self-hosted instance
- BetterToken API Key (register here)
- A GPT Key group model ID copied from the model plaza
Keep
/v1 at the end of the Base URL. Do not add /chat/completions or /responses; n8n appends the route required by the node.Setup
1
Add AI Agent and OpenAI Chat Model
Open a workflow and add an AI Agent node. At its Chat Model connector, add the OpenAI Chat Model sub-node.This guide uses OpenAI Chat Model because it supplies the model connection for n8n AI Agents, chains, and other AI workflows.
2
Create an OpenAI credential
In OpenAI Chat Model, open Credential to connect with, select Create new credential, and choose OpenAI.If your n8n version offers both OpenAI Account (ChatGPT) and API Key, choose API Key. OpenAI Account authentication is for an official account, not a BetterToken custom Base URL.
3
Enter the BetterToken credential
Use these values:
Click Save. n8n tests this credential against
/models under the configured Base URL, so the complete test URL is https://www.bettertoken.ai/v1/models.4
Select a model
Return to OpenAI Chat Model, open Model, and select the GPT Key group model ID shown in the model plaza.If the list does not update after you save the credential, reopen the node or credential and load the model list again.
5
Choose Chat Completions or Responses
For the first test, keep Use Responses API off and complete a plain conversation through the default Chat Completions mode.Turn on Use Responses API only when your workflow needs it. n8n documents built-in tools such as Web Search, File Search, and Code Interpreter for OpenAI Chat Model + AI Agent with Responses enabled. Those OpenAI-hosted tools are not automatically capabilities confirmed for BetterToken, so test them against the selected model and endpoint.
6
Run a test
Give the AI Agent a simple input:Click Execute step or run the workflow. The setup is complete when the node returns a model response.
Troubleshooting
Credential test returns 401
- Make sure the API Key is complete and has no extra spaces
- Confirm that the key belongs to the GPT Key group
- Check the key status and balance in the BetterToken Dashboard
Credential test returns 404
- The Base URL must be
https://www.bettertoken.ai/v1 - Do not use
https://www.bettertoken.ai/v1/modelsas the Base URL - Do not append
/chat/completionsor/responses
The Model list is empty
- Save the credential again, then reopen Model
- Confirm that the API Key can access
https://www.bettertoken.ai/v1/models - Copy a current model ID from the model plaza; do not use a retired or misspelled ID
Plain chat works, but Agent tool calls fail
Turn off Use Responses API and all built-in tools, then verify plain Chat Completions. Enable Agent tools one at a time to identify whether the problem is the model capability, tool arguments, or workflow configuration.The request times out
Increase Timeout under OpenAI Chat Model > Options and keep a limited Max Retries value. Do not repeatedly retry400, 401, or configuration errors.