Kimi K2.7 Code
Moonshot AIReleased Jun 12, 2026
MoonshotAI: Kimi K2.7 Code is a coding-focused model in Moonshot AI's Kimi K2 family, built to complete end-to-end programming tasks reliably over long contexts. It uses a native multimodal mixture-of-experts...
- Context window
- 262K tokens
- Max output
- 16K tokens
- Input
- text, image
- Output
- text
- Tokenizer
- Other
- Released
- Jun 12, 2026
- Reasoning
- always on
Pricing
Per 1M tokens. The provider price and our flat 3% fee are separate columns — what you pay is their sum.
| Per 1M tokens | Provider | + 3% fee | You pay |
|---|---|---|---|
| Input | $0.740 | $0.022 | $0.762 |
| Output | $3.50 | $0.105 | $3.60 |
| Cache read | $0.150 | $0.0045 | $0.154 |
Benchmarks
Artificial Analysis
- Intelligence index
- 41.9
- Coding index
- 60.8
- Agentic index
- 29.6
Design Arena
| Category | Elo | Win rate | Rank |
|---|---|---|---|
| androidnativeagents | 1221 | 52.3% | #10 |
| Full-stackagents | 1234 | 53.9% | #7 |
| htmlslidesagents | 1215 | 53.8% | #5 |
| Mobile appsagents | 1217 | 49.1% | #12 |
| Web appsagents | 1247 | 50.8% | #8 |
| 3Dmodels | 1317 | 57.8% | #12 |
| Codemodels | 1307 | 55.6% | #11 |
| Data vizmodels | 1262 | 52.2% | #24 |
| Game devmodels | 1282 | 51.7% | #21 |
| UI componentsmodels | 1294 | 54.1% | #17 |
| Websitesmodels | 1319 | 57.4% | #6 |
Head-to-head preference voting. How we filter and rank
Supported parameters
- frequency_penalty
- include_reasoning
- logit_bias
- logprobs
- max_tokens
- min_p
- parallel_tool_calls
- presence_penalty
- reasoning
- reasoning_effort
- repetition_penalty
- response_format
- seed
- stop
- structured_outputs
- temperature
- tool_choice
- tools
- top_k
- top_logprobs
- top_p
Call it
OpenAI-compatible: point your SDK at api.openkey.ai/v1 and use model moonshotai/kimi-k2.7-code.
curl https://api.openkey.ai/v1/chat/completions \
-H "Authorization: Bearer $OPENKEY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "moonshotai/kimi-k2.7-code",
"messages": [{"role": "user", "content": "Hello"}]
}'import os
from openai import OpenAI
client = OpenAI(
base_url="https://api.openkey.ai/v1",
api_key=os.environ["OPENKEY_API_KEY"],
)
completion = client.chat.completions.create(
model="moonshotai/kimi-k2.7-code",
messages=[{"role": "user", "content": "Hello"}],
)
print(completion.choices[0].message.content)import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://api.openkey.ai/v1",
apiKey: process.env.OPENKEY_API_KEY,
});
const completion = await client.chat.completions.create({
model: "moonshotai/kimi-k2.7-code",
messages: [{ role: "user", content: "Hello" }],
});
console.log(completion.choices[0].message.content);Questions
- How much does Kimi K2.7 Code cost via API?
- Through OpenKey, Kimi K2.7 Code costs $0.762 per 1M input tokens and $3.60 per 1M output tokens. That is the provider price ($0.740 / $3.50) plus a flat 3% fee — nothing else.
- What is Kimi K2.7 Code's context window?
- Kimi K2.7 Code accepts up to 262K tokens of context and returns up to 16K tokens per request.
- Is Kimi K2.7 Code OpenAI-compatible?
- Yes. Send requests to OpenKey's /v1/chat/completions endpoint with model "moonshotai/kimi-k2.7-code" using any OpenAI SDK — only the base URL and API key change.
- What inputs does Kimi K2.7 Code support?
- Kimi K2.7 Code accepts text, image input and produces text output.
More from Moonshot AI
All Moonshot AI models →MoonshotAI Kimi Latest
This model always redirects to the latest model in the MoonshotAI Kimi family.
ctx 262Kin $0.567out $3.30
Kimi K2.6
Kimi K2.6 is Moonshot AI's next-generation multimodal model, designed for long-horizon coding, coding-driven UI/UX generation, and multi-agent orchestration. It handles complex end-to-end coding tasks across Python, Rust, and Go, and...
ctx 262Kin $0.567out $3.30
Kimi K2.5
Kimi K2.5 is Moonshot AI's native multimodal model, delivering state-of-the-art visual coding capability and a self-directed agent swarm paradigm. Built on Kimi K2 with continued pretraining over approximately 15T mixed...
ctx 262Kin $0.386out $2.09
Kimi K2 Thinking
Kimi K2 Thinking is Moonshot AI’s most advanced open reasoning model to date, extending the K2 series into agentic, long-horizon reasoning. Built on the trillion-parameter Mixture-of-Experts (MoE) architecture introduced in...
ctx 262Kin $0.618out $2.58