Skip to content

Other tools and compatibility

Which coding agents and editors can use a custom OpenAI or Anthropic endpoint like Tokens, which cannot, and a generic recipe for connecting any OpenAI-compatible tool.

Works withAny OpenAI-compatible toolAny Anthropic-compatible tool
On this page

Tokens can serve any tool that lets you set a custom OpenAI-compatible or Anthropic-compatible endpoint. This page lists which coding agents and editors can and can't, and gives a generic recipe for tools without their own guide.

Compatibility table#

Based on each tool's official documentation, checked October 2026. "Partial" means some features use Tokens and others don't.

ToolCustom endpoint?Protocol to use with TokensGuide
Claude CodeYesAnthropic Messages, base https://tokens.bdClaude Code
Codex CLIYes, with a caveatResponses API only; works if the model's upstream supports /v1/responsesCodex CLI
OpenCodeYesChat CompletionsOpenCode
OpenClawYesChat Completions or Anthropic MessagesOpenClaw
Hermes AgentYesChat CompletionsHermes Agent
CrushYesChat Completions (openai-compat)Crush
AiderYesChat Completions, openai/ model prefixAider
GooseYesChat Completions, full endpoint URLGoose
Qwen CodeYesChat CompletionsQwen Code
Kimi Code CLIYesChat Completions or Anthropic MessagesKimi Code
Factory DroidYesChat Completions or Anthropic MessagesFactory Droid
ClineYesChat CompletionsCline
Kilo CodeYesChat CompletionsKilo Code
Roo CodeYes, but archivedChat Completions; repo archived 2026-05-15Roo Code
ContinueYesChat CompletionsContinue
ZedYesChat Completions or Anthropic MessagesZed
GitHub Copilot (VS Code)PartialChat only; inline suggestions and embeddings stay on GitHubGitHub Copilot
CursorPartial, undocumentedBase URL override not in Cursor's official docs; Tab never uses itCursor
WarpPartialChat Completions; not used by Auto models or Cloud AgentsWarp
AmpPartialOnly models in Amp's own catalog can be routedAmp
Gemini CLINoOnly accepts Gemini or Vertex wire formatUse Qwen Code
Kimi CLI (Python)NoArchived; existing installs will stop workingUse Kimi Code CLI

Why Gemini CLI can't use Tokens#

Gemini CLI's only base URL overrides, GOOGLE_GEMINI_BASE_URL and GOOGLE_VERTEX_BASE_URL, expect the Gemini or Vertex request format. Tokens doesn't serve that format, so no setting makes it work. Qwen Code, originally a Gemini CLI fork, supports OpenAI-compatible endpoints.

Connect any OpenAI-compatible tool#

If your tool isn't listed, look for a setting called "OpenAI compatible", "custom provider", "API base" or "base URL". Then you need four things.

1. Base URL#

Your tool speaksBase URLThe tool then calls
OpenAI Chat Completionshttps://tokens.bd/v1/v1/chat/completions
Anthropic Messageshttps://tokens.bd/v1/messages

Some tools, such as Goose's custom provider file, want the full endpoint https://tokens.bd/v1/chat/completions. If the tool's own example ends in /chat/completions, copy that shape. A 404 on the first request almost always means /v1 is missing or doubled.

2. API key#

Tokens reads the key from Authorization: Bearer <key> or x-api-key: <key>, so OpenAI-style and Anthropic-style tools both work without extra headers. Where the tool reads environment variables, use export TOKENS_API_KEY=tok_live_your_key and keep the key out of config files you might commit. One key per tool makes usage easy to read and revocation painless; see API keys.

3. Model ID#

Use the exact Tokens ID, including the provider prefix: deepseek/deepseek-v4.1-flash, not deepseek-v4.1-flash. Get IDs from the model catalog or from the API, which returns only models your key can use:

bash
curl -s https://tokens.bd/v1/models -H "Authorization: Bearer $TOKENS_API_KEY"

Tools that reference models as <provider>/<model> end up with two slashes, such as tokens/deepseek/deepseek-v4.1-flash. Not every tool documents how it splits that, so check there first if the model isn't found. LiteLLM-based tools such as Aider want an openai/ prefix, which they strip before sending.

4. Context window and output limit#

Many tools can't read a model's limits from the endpoint, so they ask you or assume a default. Use the values from the catalog. A wrong context window breaks automatic compaction: too high and long conversations get rejected upstream, too low and history is trimmed early.

Also check:

  • Tool calling. Agents that edit files need a model with function calling.
  • Streaming. For a usage chunk at the end of an OpenAI-style stream, the client must send stream_options: {"include_usage": true}.
  • Unsupported endpoints. Images, audio, files, batches, assistants, fine-tuning and moderations return 404 unsupported_endpoint. Embeddings work only for embedding models, so keep a tool's embedding features on their current provider.
  • Browser-only tools. Tokens sends no CORS headers, so calls straight from a web page fail. Use a server, CLI or editor extension.

Test the connection#

Before you debug a tool's settings, confirm the key and model work. The tester below sends a short request with your key and the model you pick. Or run the curl that follows from your machine.

Live connection test

Check latency and token generation before you start coding.

POST /v1/chat/completions
Create a key
bash
curl -s https://tokens.bd/v1/chat/completions \
  -H "Authorization: Bearer $TOKENS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "deepseek/deepseek-v4.1-flash", "max_tokens": 16, "messages": [{"role": "user", "content": "Reply with OK"}]}'

If that succeeds and the tool still fails, the problem is in the tool's settings. Connect Your Agent also runs a live test and has snippets for common agents.

Troubleshooting#

Status and codeUsual cause in a new tool
404 on the first requestBase URL missing /v1, or path doubled
401 missing_api_keyEnv var not set where the tool runs
404 model_not_foundModel ID missing the provider prefix
429 rate_limitedAgent burst past the per-minute limit; wait for Retry-After

Every code is in Troubleshooting; formats are in Chat Completions and Messages. The Tokens CLI can configure OpenCode, Claude Code, Codex CLI and Crush for you.

Sources: Gemini CLI configuration reference, MoonshotAI/kimi-cli archive notice, plus the official docs linked from each tool's guide, checked October 2026.

Was this page helpful?

Still stuck? Open a support ticket

Need help configuring your agent?

Test your connection with the connection tester, or create an API key.