Use ApexApi in Kimi Code
Kimi Code is a terminal coding agent that accepts any OpenAI compatible provider. Register ApexApi once and run models from our catalog on one balance.
1. Get your API key
Create a key in your dashboard. It starts with ak-.
2. Register ApexApi as a provider
Edit ~/.kimi-code/config.toml and add:
[providers.apexapi]
type = "openai"
api_key = "ak-your-key-here"
base_url = "https://api.apexapi.dev/v1"3. Reference models with the provider prefix
Models are addressed as apexapi/<catalog-id>, for example apexapi/anthropic/claude-sonnet-4.6 or apexapi/deepseek/deepseek-v4-pro.
The ID must match the catalog exactly, in provider/model format. Browse all IDs on the models page.
4. Run it
Start Kimi Code and pick the ApexApi model; the interactive /provider command also lists the registered provider.
Troubleshooting
- 401 Unauthorized: the key wasn't pasted correctly or has been revoked.
- Model not found: the model ID doesn't match a catalog ID. Copy it verbatim from the models page.
- Connection fails: make sure the base URL is exactly
https://api.apexapi.dev/v1(no trailing slash after v1) and your balance is positive. - Anything else: check the error codes reference; streaming and tool calling are fully supported on
/v1/chat/completions.