# Kimi K2.7 Code

Moonshot Kimi K2.7, the coding-specialised version. 256K context.

- Model ID (the request body's `model` field): `kimi-k2.7-code`
- Category: Text chat
- Page: https://qd.zsopc.com/en/models/kimi-k2.7-code
- Endpoint: `https://qd.zsopc.com/v1/chat/completions`
- Context window: 256,000 tokens
- Default output limit per request: 256,000 tokens
- Capabilities: Tool calling · Thinking mode · JSON mode · Open weights
- Compatible protocols: OpenAI Chat Completions
- Released: 2026-06-15
- Last updated: 2026-11-17

## Pricing

- Input: 242.64 credits (≈ ¥4.04 / ≈ $0.6) per 1M tokens
- Output: 1,011 credits (≈ ¥16.85 / ≈ $2.5) per 1M tokens
- Cached input: 40.44 credits (≈ ¥0.674 / ≈ $0.1) per 1M tokens

Credits are the platform's only unit: 60 credits = ¥1 (machine-readable: `GET https://qd.zsopc.com/api/v1/config/currency`).
Each call first holds the most it could cost, then settles on actual usage and refunds the difference.

## Example call

```bash
curl https://qd.zsopc.com/v1/chat/completions \
  -H "Authorization: Bearer $PLATFORM_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"kimi-k2.7-code","messages":[{"role":"user","content":"Hello"}]}'
```

## FAQ

### How do I call Kimi K2.7 Code?

Set the model field of the request body to kimi-k2.7-code, send it to https://qd.zsopc.com/v1/chat/completions, and put your key (it starts with sk-gpushare-) in the Authorization: Bearer header. The official OpenAI, Anthropic and Google Gemini SDKs all work directly; just point base_url at this gateway.

### How much does the Kimi K2.7 Code API cost?

Input: 242.64 credits (≈ ¥4.04 / ≈ $0.6) per 1M tokens; Output: 1,011 credits (≈ ¥16.85 / ≈ $2.5) per 1M tokens; Cached input: 40.44 credits (≈ ¥0.674 / ≈ $0.1) per 1M tokens. Prices are in credits: 60 credits = ¥1. Each call first holds the most it could cost, then settles on actual usage and refunds the difference.

### How large is Kimi K2.7 Code's context window?

256,000 tokens, with a default output limit of 256,000 tokens per request.

### What can Kimi K2.7 Code do?

Tool calling, Thinking mode, JSON mode, Open weights. Compatible protocols: OpenAI Chat Completions.

## Related

- All models and live prices: https://qd.zsopc.com/en/models
- Quickstart: https://qd.zsopc.com/en/docs/quickstart
- FAQ: https://qd.zsopc.com/en/docs/faq
- OpenAPI: https://qd.zsopc.com/openapi.json
