Troubleshooting
Start with the simplest test. If this works, your key and balance are fine, and the problem is in the tool’s config:
curl https://api.vikey.ai/v1/chat/completions \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{"model": "openai/gpt-6-luna", "max_tokens": 16, "messages": [{"role": "user", "content": "ping"}]}'Common problems
Section titled “Common problems”| Symptom | Most likely cause | Fix |
|---|---|---|
404 on every request |
Wrong base URL. The OpenAI SDK needs /v1, the Anthropic SDK and Claude Code do not. |
See Base URL |
401 Invalid API key |
Wrong key, a stray space, or a key from another account | Copy it again from API Keys |
401 although the key is right |
The tool sends the key in the wrong header, or the environment variable is not read | Check your tool’s guide under Coding agents |
402 Insufficient balance |
No balance left, or max_tokens too large for what is left |
Top up, or lower max_tokens |
403 API key is inactive |
The key is turned off | Turn it on again in API Keys |
Model '...' not found |
A typo in the model id, or the tool sends its built-in model name | Use an id from the pricing page. For Claude Code, add modelOverrides. |
ambiguous_model |
A short name matches several providers | Use the full id, such as deepseek/deepseek-v4.1-flash |
Codex: wire_api = "chat" is no longer supported |
An old Codex config | Change it to wire_api = "responses", see Codex |
opencode: Model not found: vikey/... |
The unsupported providers format, or the model is missing from models |
Use the format in opencode |
| Claude Code asks you to log in | The key is in project settings, not user settings or the shell | See Claude Code |
| Cost higher than expected | Long prompts resent without cache, or an expensive model used for light tasks | Check Usage per model and consider Vikey Auto |
| The answer stops halfway | The max_tokens limit was reached |
Raise max_tokens |
502 or 503 |
The model has a problem on the provider side | Retry shortly, or use another model |
Still stuck?
Section titled “Still stuck?”Contact us on Telegram or WhatsApp. Include:
- The
request_idfrom the error message, if any - The tool and its version, for example Claude Code 2.1.323
- The model id you used
- When it happened
Never send your API key to anyone, including support.