Set up Kimi Code
Copy your I Code Easy key from API keys and choose an available endpoint for the model family in Endpoint selection. This guide uses k3.1-pro.
Kimi Code
Merge this configuration into ~/.kimi-code/config.toml. Place default_model before the first TOML table. Set ICODEEASY_API_KEY in your current terminal to your I Code Easy key, run kimi, and use /model to check that Kimi K3.1 Pro is selected.
default_model = "icodeeasy/k3.1-pro"
[providers.icodeeasy]
type = "kimi"
base_url = "https://api.icodeeasy.cc/v1"
api_key_env = "ICODEEASY_API_KEY"
[models."icodeeasy/k3.1-pro"]
provider = "icodeeasy"
model = "k3.1-pro"
display_name = "Kimi K3.1 Pro (I Code Easy)"
max_context_size = 1048576
capabilities = ["thinking", "always_thinking", "tool_use"]
Verify your first request
Send a short text prompt in a new session and check the model and status in Request logs. For a 401, check your key. For model or access errors, check the model ID and selected endpoint. For connection issues, try https://jp.icodeeasy.cc or https://sg.icodeeasy.cc with the same path.
Official client documentation
Related guides
Kimi Code Setup: API Key, K3.1 Pro, and Claude Code
Set up Kimi Code CLI or Claude Code with K3.1 Pro. Compare persistent and temporary settings, verify your first call, and fix 401, model, and URL errors.
Chat Completions
Send a conversation using the OpenAI Chat format. Check that your model and selected endpoint support the Chat protocol before sending the request.
How do I troubleshoot slow connections or failed requests?
Match 401, 403, 429, timeouts, and Gemini path errors before changing hosts. Switch to the jp or sg backup domain only after the network is the problem.