Agentic.LLM.Provider.KimiCoding (agentic v0.4.0)

Copy Markdown

Kimi For Coding — Moonshot's Anthropic-compatible coding API.

This is the coding-plan path to Kimi, distinct from the OpenAI-compatible direct API (Agentic.LLM.Provider.Moonshot) and the CLI/ACP wrapper (Agentic.LLM.Provider.Kimi). The endpoint speaks the Anthropic Messages wire format, so this reuses the Anthropic Messages transport with a different base URL and a mandatory User-Agent header.

Endpoint

Base:  https://api.kimi.com/coding/v1
POST:  .../messages        (assembled by the Anthropic transport)

Auth: KIMI_API_KEY (sent as x-api-key by the Anthropic transport).

Mandatory header

Moonshot's coding gateway checks the client identity, so every request carries User-Agent: KimiCLI/1.5 (set in request_headers/1). Without it the gateway rejects requests as not coming from the official client.

Models

All models are reachable on the coding plan (flat subscription), so per-token costs are zero here. k3-256k is the Kimi K3 256k coding model (the coding seat since 2026-09-04); kimi-for-coding is the plan alias; k2p7 is the dated alias for Kimi K2.7 Code.

Quirks

  • Reasoning/thinking is always-on; do not try to disable it.
  • Anthropic Messages format: system prompt, tool definitions, and tool results all follow the Anthropic shape (handled by the transport).