Back to Models

Kimi K2.7 Code

moonshotmoonshot/kimi-k2.7-code

Moonshot AI's 2026-06 coding-specialist model (1T MoE, 32B active). 256K context. +21.8% on Kimi Code Bench v2 vs K2.6, 30% fewer reasoning tokens. Open-weight (Modified MIT).

Kimi K2.7 Code is Moonshot AI's June 2026 coding-specialist member of the Kimi K2 family. It keeps the 1T-parameter Mixture-of-Experts shape with 32B active parameters per token and targets agentic software engineering workloads: multi-file edits, MCP tool invocation, repository analysis, and long-horizon implementation loops.

For TheRouter customers, the important production shape is narrower than Moonshot's own platform story: this route is cataloged as text input to text output, with 256K context and 65,536 maximum completion tokens from standard-models.yaml. Use it when coding quality and token efficiency matter more than a no-thinking fast lane; use a separate low-latency route for trivial tool dispatch or interactive chat.

Best for
  • β€’ Deep coding agents that need long-context planning, repository-scale edits, and sustained tool-calling loops
  • β€’ MCP-heavy workflows where Moonshot reports 81.1 on MCP Mark Verified and tool invocation correctness is the selection criterion
  • β€’ Cost-sensitive alternatives to frontier coding models when a 256K context window and open-weight lineage matter
Reach for something else if
  • β€’ Vision or multimodal requests on TheRouter β€” this catalog route is text-only, so route images to moonshot/kimi-k2.6 or another multimodal model
  • β€’ Cheap quick-turn tool dispatch where mandatory thinking overhead would dominate cost and latency
  • β€’ Deterministic CI output that requires tuning sampling parameters outside Moonshot's locked K2.7 Code defaults

How TheRouter serves this differently from the vendor

As the vendor operates it

Moonshot documents Kimi K2.7 Code as a Kimi-platform coding model with mandatory thinking, published pricing, and discussion of the wider K2.7 family including high-speed routing options.

On TheRouter

TheRouter currently publishes moonshot/kimi-k2.7-code as a text-to-text chat-completions route with 256K context, 65,536 max completion tokens, and TheRouter platform pricing from standard-models.yaml.

Context Length
256K
Max Output
66K
Input Priceper 1M tokens
$1.03/ 1M tokens
Output Priceper 1M tokens
$4.32/ 1M tokens

Modalities

text→text

Pricing Breakdown

TypeRate
Input$1.03 / 1M tokens
Output$4.32 / 1M tokens

Supported Parameters

temperaturemax_tokenstop_ptoolstool_choiceresponse_formatstop

Specifications

Release date2026-06-12platform.kimi.ai β†—verified
Architecture1T-total / 32B-active MoE; 384 experts, 8 routed plus 1 shared expert per forward passplatform.kimi.ai β†—verified
Context window256,000 tokensplatform.kimi.ai β†—verified
Thinking modeAlways on; non-thinking mode is not supportedplatform.kimi.ai β†—verified
Training data cutoffNot publicly disclosedunknown
LicenseModified MIT Licenseplatform.kimi.ai β†—verified

Benchmarks

BenchmarkDistributionScoreSource
Kimi Code Bench v2
Moonshot-reported score; +21.8% versus K2.6.
62.0%platform.kimi.ai β†—
Program Bench
Moonshot-reported score; +11.0% versus K2.6.
53.6%platform.kimi.ai β†—
MCP Mark Verified
Moonshot-reported MCP tool invocation benchmark.
81.1%platform.kimi.ai β†—
Kimi Claw 24/7
Moonshot-reported sustained agent benchmark; +9.3% versus K2.6.
46.9%platform.kimi.ai β†—

API Usage Examples

Use the global api.therouter.ai endpoint shown below for new integrations; the legacy China accelerated endpoint is retired.

cURL
curl https://api.therouter.ai/v1/chat/completions   -H "Content-Type: application/json"   -H "Authorization: Bearer $THE_ROUTER_API_KEY"   -d '{
    "model": "moonshot/kimi-k2.7-code",
    "messages": [
      {"role": "user", "content": "Summarize the key points from this input."}
    ]
  }'

Chat completion

Use the standard TheRouter chat-completions endpoint for coding prompts.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"moonshot/kimi-k2.7-code","messages":[{"role":"user","content":"Review this diff for regressions."}]}'

More from moonshot

Similar models

Cross-provider sibling models

News & changes

2026-06-17

Kimi K2.7 Code API: 30% Fewer Thinking Tokens and a HighSpeed Variant Change Your Routing Policy

TheRouter's June note highlighted the two routing consequences of K2.7 Code: lower reasoning-token burn for standard coding agents, and a separate HighSpeed sibling for latency-sensitive work.

re-authored by TheRouterKimi Open Platform β†—
2026-06-13

Kimi K2.7 Code API: Thinking-Only Constraint Changes How You Route Coding Agents

The launch coverage recorded the operator constraint that matters most for routing: K2.7 Code does not offer a non-thinking mode, so cost and latency models must include reasoning overhead.

re-authored by TheRouterMoonshot AI β†—

Related news

Frequently asked

Is moonshot/kimi-k2.7-code the right default for every coding request?

No. It is a strong route for deep coding-agent work, but mandatory thinking makes it inefficient for trivial tool dispatch, quick formatting, or latency-sensitive chat. Keep a cheaper non-thinking route for those turns.

Does this TheRouter route support image input?

No. standard-models.yaml lists moonshot/kimi-k2.7-code as text input to text output. If the request contains screenshots, route to a cataloged multimodal model such as moonshot/kimi-k2.6.

How is K2.7 Code priced on TheRouter?

The live pricing displayed on the model card comes from TheRouter's standard-models.yaml, not from prose in this page. At curation time the catalog lists $0.95 per million input tokens and $4.00 per million output tokens.

Fact ledger β€” every claim on this page traces here
sourceURLretrieved
Release dateplatform.kimi.ai β†—2026-08-04verified
Architectureplatform.kimi.ai β†—2026-08-04verified
Context windowplatform.kimi.ai β†—2026-08-04verified
Thinking modeplatform.kimi.ai β†—2026-08-04verified
Training data cutoffβ€”β€”unknown
Licenseplatform.kimi.ai β†—2026-08-04verified
Kimi Code Bench v2platform.kimi.ai β†—2026-08-04verified
Program Benchplatform.kimi.ai β†—2026-08-04verified
MCP Mark Verifiedplatform.kimi.ai β†—2026-08-04verified
Kimi Claw 24/7platform.kimi.ai β†—2026-08-04verified
Kimi K2.7 Code API: 30% Fewer Thinking Tokens and a HighSpeed Variant Change Your Routing PolicyKimi Open Platform β†—2026-06-17verified
Kimi K2.7 Code API: Thinking-Only Constraint Changes How You Route Coding AgentsMoonshot AI β†—2026-06-13verified
Is moonshot/kimi-k2.7-code the right default for every coding request?platform.kimi.ai β†—2026-08-04to verify
Does this TheRouter route support image input?platform.kimi.ai β†—2026-08-04to verify
How is K2.7 Code priced on TheRouter?platform.kimi.ai β†—2026-08-04to verify
Help & contact