Kimi K3.1 Pro

    moonshotai/kimi-k3.1-pro

    Successor to K3 and flagship open-weight multimodal reasoning model for long-horizon coding and agentic knowledge work, with native image and video understanding.

    ReasoningCodingLong Text ProcessingMultimodal UnderstandingAgent CodingAgent
    Modality
    Input / Output Pricing
    $2 / $10M tokens
    Context
    1.04M
    Release date
    2026-10-23

    Pricing

    SpecificationPrice
    Input$2/ M tokens
    Output$10/ M tokens
    Cache read$0.2/ M tokens
    Cache write 5min$2/ M tokens
    Cache write 1h$4/ M tokens

    Quick Start

    Paste and run the sample code below. The Gate.AI API is OpenAI-compatible—most SDKs only need a new base URL. To switch models, change the model ID.

    1

    Get your API key

    Sign in to the Gate.AI console and create a new key under "API Keys". Keep it safe and send it via the Authorization header on every request.

    Create a key in the console
    2

    Make a request

    Send a POST request to the Chat Completions endpoint with a model ID and an array of messages to get a reply.

    POSThttps://api.gate.ai/openai/v1/chat/completions
    curl --location "https://api.gate.ai/openai/v1/chat/completions" \
      --header "Authorization: Bearer {API_KEY}" \
      --header "Content-Type: application/json" \
      --data '{
      "model": "kimi-k3.1-pro",
      "messages": [
        {"role": "user", "content": "Hello"}
      ]
    }'
    3

    Handle the response \\\\\& streaming

    By default a full JSON response is returned. Add "stream": true to the request body to receive incremental chunks over SSE.

    POSThttps://api.gate.ai/openai/v1/chat/completions
    curl --no-buffer --location "https://api.gate.ai/openai/v1/chat/completions" \
      --header "Authorization: Bearer {API_KEY}" \
      --header "Content-Type: application/json" \
      --data '{
      "model": "kimi-k3.1-pro",
      "messages": [
        {"role": "user", "content": "Hello"}
      ],
      "stream": true
    }'

    Endpoint

    Base URL, method, and required headers are rendered from the active protocol template for this model.

    POSThttps://api.gate.ai/openai/v1/chat/completions
    Field
    Value
    Authorization
    Authentication header containing the API key in the format Bearer {API_KEY}
    Content-Type
    Request content type, fixed to application/json
    model
    Model ID; the current model is kimi-k3.1-pro
    messages
    Ordered array of conversation messages
    stream
    Whether to return the result as an SSE stream

    Create streaming or non-streaming responses with the OpenAI Responses API.

    POSThttps://api.gate.ai/openai/v1/responses
    Field
    Value
    Authorization
    Authentication header containing the API key in the format Bearer {API_KEY}
    Content-Type
    Request content type, fixed to application/json
    model
    Model ID; the current model is kimi-k3.1-pro
    input
    Text or structured input submitted to the model
    max_output_tokens
    Maximum number of output tokens the model may generate
    stream
    Whether to return the result as an SSE stream

    Create messages in Anthropic Messages API format with text, images, tools, and extended thinking.

    POSThttps://api.gate.ai/anthropic/v1/messages
    Field
    Value
    x-api-key
    Gate.AI API key header with the value {API_KEY}
    anthropic-version
    Anthropic protocol version; for example 2023-06-01
    Content-Type
    Request content type, fixed to application/json
    model
    Model ID; the current model is kimi-k3.1-pro
    max_tokens
    Maximum number of tokens the model may generate
    messages
    Ordered array of Anthropic messages
    stream
    Whether to return the result as an SSE stream

    Related Models