Using Kimi K2.6 on Cloudflare Workers AI
Implementation guide · Kimi K2 · Moonshot AI
Quick Start
- 1
- 2Use the Cloudflare Workers AI SDK or REST API to call
@cf/moonshot/kimi-k2.6— see the documentation for request format. - 3
Code Examples
About Cloudflare Workers AI
Cloudflare Workers AI is a serverless GPU inference platform enabling developers to run machine learning models on Cloudflare's global edge network. It supports diverse AI tasks including text generation, image classification, automatic speech recognition, and real-time language translation. The platform provides pay-per-use pricing and access to a curated library of open-source models from Hugging Face, enabling rapid deployment without complex infrastructure management. Key features include low-latency edge computing, streaming responses for large language models, context length customization, and the AI Gateway for monitoring, caching, and cost optimization.
Cloudflare is a leading connectivity cloud company that provides a comprehensive suite of cloud-native products and developer tools to enhance web performance, security, and reliability. Their services include content delivery network (CDN), DDoS mitigation, DNS services, and zero trust security solutions. While Cloudflare doesn't primarily market itself as an AI platform, they have incorporated AI and machine learning technologies into various aspects of their services to improve performance and security, including threat detection capabilities, content delivery optimization, and intelligent routing decisions across their global network.
Pricing on Cloudflare Workers AI
| Type | Price (per 1M) |
|---|---|
| Input tokens | $0.95 |
| Output tokens | $4.00 |
Capabilities
About Kimi K2.6
Kimi K2.6 is Moonshot AI's multimodal agentic coding model, released April 20 2026 under a Modified MIT license. Built on a 1-trillion-parameter MoE architecture (32B active, 384 experts with 8 selected per token plus 1 shared expert, 61 layers), it features a 262K context window and up to 65,536 output tokens. Supports native image and video inputs (screenshots, PDFs, spreadsheets). Designed for long-horizon coding with agent swarms of up to 300 sub-agents and 4,000 coordinated steps; Moonshot AI cites 200–300 sequential tool calls without task drift. Key benchmarks: SWE-bench Verified 80.2%, SWE-bench Pro 58.6%, LiveCodeBench v6 89.6%, GPQA Diamond 90.5%, Terminal-Bench 2.0 66.7%. Chatbot Arena Elo 1454 (2026-04-28 snapshot).