KimiKimi K3.1 Pro API
Moonshot’s most capable Kimi model — post-trained K3 with deep reasoning and a 1M-token context.
Params
Billed at this model’s published rate.
Result

Other models from Kimi
Same vendor, same API call — the differences are below.
| Model | Use case | Price | Resolution | Duration | Added |
|---|---|---|---|---|---|
| Kimi K3.1 Pro Highspeed | Image → Text | from $0.20 / 1M cached in | — | — | Oct 2026 |
| Kimi K3 | Image → Text | from $0.30 / 1M cached in | — | — | Oct 2026 |
Install the SDK
TypeScript targets Node 20+ and ships with types; Python needs 3.10+ and is async. Over REST there is nothing to install: call https://api.picsart.com from any HTTP client.
npm install @picsart/ai-sdkpip install picsart-ai-sdkAuthenticate
Send your Picsart API key as a bearer token. The SDK does it for you once the client is created.
import { createClient } from '@picsart/ai-sdk';
const ai = createClient({
apiKey: process.env.PICSART_API_KEY, // sent as: Authorization: Bearer <key>
apiUrl: 'https://api.picsart.com',
});import os
from picsart_ai_sdk import create_client
ai = create_client(
api_key=os.environ["PICSART_API_KEY"], # sent as: Authorization: Bearer <key>
api_url="https://api.picsart.com",
)Authorization: Bearer <PICSART_API_KEY>Make a request
Call the model by its id. Over REST, one endpoint serves every model: POST /workflows/v1/models/execute with the model id and its input in the body. The outer params is the envelope every workflow takes; the inner one is this model's input, with the same names generateText() / generate_text() takes.
import { createClient } from '@picsart/ai-sdk';
const ai = createClient({
apiKey: process.env.PICSART_API_KEY,
apiUrl: 'https://api.picsart.com',
});
const { text } = await ai.generateText('kimi-k3.1-pro', {
prompt: "A serene mountain lake at golden hour, ultra detailed"
});
console.log(text);import asyncio
import os
from picsart_ai_sdk import create_client
async def main() -> None:
async with create_client(
api_key=os.environ["PICSART_API_KEY"],
api_url="https://api.picsart.com",
) as ai:
res = await ai.generate_text("kimi-k3.1-pro", {
"prompt": "A serene mountain lake at golden hour, ultra detailed",
})
print(res.text)
asyncio.run(main())curl -X POST 'https://api.picsart.com/workflows/v1/models/execute' \
-H 'Authorization: Bearer $PICSART_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"params": {
"model": "kimi-k3.1-pro",
"params": {
"prompt": "A serene mountain lake at golden hour, ultra detailed"
}
}
}'Parameters
3 parameters, the same for the SDK and for the inner params over REST. Required ones must be supplied; the rest fall back to their defaults.
| Parameter | Type | Required | Default | Details |
|---|---|---|---|---|
promptThe message or question for the model, in plain language. With input images, what to say about them. | text | yes | — | — |
imageUrlsImages for the model to look at, as URLs. | file (image[]) | no | — | — |
thinkingHow much the model reasons before answering. More is slower and uses more tokens. | enum | no | high | low, high |
Response
generateText() resolves to the generated text. Over REST the output is at response.result, inside the gateway's status envelope with the task id, its status and the amount charged.
{
"text": "…generated text…",
"model": "kimi-k3.1-pro"
}{
"status": "success",
"response": {
"id": "task_abc123",
"status": "COMPLETED",
"result": {
"text": "…generated text…",
"model": "kimi-k3.1-pro"
}
}
}Overview
Alongside the unified model APIs, we expose compatibility APIs that take each vendor's original parameters exactly as the vendor defines them — nothing renamed, nothing reshaped on the way through.
That makes them the shortest path onto Picsart if you already work with the vendor directly: the request bodies you've already written keep working as they are. You keep their parameter names and defaults, and you get the vendor's full parameter set rather than the subset that is shared across every model.
The cost is that a request is written for one vendor — switching models later means rewriting it, and results come back in the vendor's own shape. When you'd rather write once and change models freely, use the unified API.
Make a request
Call the workflow with ai.apis.run() in TypeScript or Python, or hit /workflows/{workflow}/execute directly — params is passed through untouched either way.
These endpoints are addressed by workflow name rather than model id: the one in this model's header, since one model runs as one workflow. Authentication is unchanged — your Picsart API key as a bearer token (see Authentication).
import { createClient, ApiRunMode } from '@picsart/ai-sdk';
const ai = createClient({
apiKey: process.env.PICSART_API_KEY,
apiUrl: 'https://api.picsart.com',
});
// Calls the 'chat-completions' workflow directly — params are sent as-is.
const { result, usage } = await ai.apis.run('chat-completions', {
model: "gpt-6.1-sol",
messages: [
{
role: "developer",
content: []
}
]
}, {
mode: ApiRunMode.SYNC,
});
console.log(result); // workflow-specific output
console.log(usage?.credits); // amount charged, in $import asyncio
import os
from picsart_ai_sdk import ApiRunMode, create_client
async def main() -> None:
async with create_client(
api_key=os.environ["PICSART_API_KEY"],
api_url="https://api.picsart.com",
) as ai:
# Calls the 'chat-completions' workflow directly — params are sent as-is.
response = await ai.apis.run("chat-completions", {
"model": "gpt-6.1-sol",
"messages": [
{
"role": "developer",
"content": [],
},
],
}, mode=ApiRunMode.SYNC)
print(response["result"]) # workflow-specific output
print((response.get("usage") or {}).get("credits")) # amount charged, in $
asyncio.run(main())curl -X POST 'https://api.picsart.com/workflows/chat-completions/execute' \
-H 'Authorization: Bearer $PICSART_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"params": {
"model": "gpt-6.1-sol",
"messages": [
{
"role": "developer",
"content": []
}
]
}
}'Parameters
8 parameters, sent inside params. These are the vendor's own names, so they line up one-for-one with the vendor's documentation. Required ones must be supplied; the rest fall back to their defaults.
| Parameter | Type | Required | Default | Details |
|---|---|---|---|---|
modelModel used for completions | string | yes | — | gpt-6.1-solgpt-6.1-terragpt-6-astragpt-6-solgpt-6-lunagpt-5gpt-5.1gpt-5.2gpt-5.4gpt-5.4-minigpt-5.4-nanogpt-5.5gpt-5.6-solgpt-5.6-terragpt-5.6-lunagpt-5-minigpt-5-nanogpt-5-search-apigpt-4ogpt-4o-minigpt-4.1gpt-4.1-minigpt-4.1-nanoclaude-sonnet-4-5claude-sonnet-4-6claude-sonnet-5claude-sonnet-5-5claude-opus-4-8claude-opus-5claude-opus-5-5claude-haiku-4-5claude-haiku-5-5claude-fable-5claude-fable-5-1gemini-3.1-pro-previewgemini-3-flash-previewgemini-3.8-flashgemini-3.7-flashgemini-3.6-flashgemini-3.5-flashgemini-3.5-flash-litegemini-3.1-flash-litegemini-2.5-flashgemini-2.5-progemini-4-argonkimi-k3kimi-k3.1-prokimi-k3.1-pro-highspeedgrok-4.7minimax-m3minimax-m3.1-flash |
messagesA list of messages comprising the conversation so far | MessageParam[] | yes | — | — |
└ nameAn optional name for the participant. Provides the model information to differentiate between participants of the same role. | string | no | — | — |
└ roleThe role of the messages author | string | yes | — | developersystemuserassistanttool |
└ contentAn array of content parts with a defined type. Supported options differ based on the model being used to generate the response. Can contain text, image, or audio inputs. Optional on assistant messages that carry tool_calls. | MessageContentParam[] | yes | — | — |
└ typeThe type of the content part. | string | yes | — | textimage_urlfile |
└ image_urlThe image content. | object | no | — | — |
└ textThe text content. | string | no | — | — |
└ fileThe file content. | object | no | — | — |
└ tool_callsThe tool calls generated by the model, echoed back from a previous assistant turn. Echo them exactly as returned — including extra_content — or Gemini 3 models reject the request. | MessageToolCallParam[] | no | — | — |
└ idThe ID of the tool call, as returned by the model. | string | yes | — | — |
└ typeThe type of the tool call. Currently, only "function" is supported. | string | yes | — | — |
└ functionThe function the model called. | object | yes | — | — |
└ extra_contentVendor-specific data returned with the tool call, echoed back verbatim. Gemini 3 models reject the turn when `extra_content.google.thought_signature` is missing. | object | no | — | — |
└ tool_call_idOn role "tool" messages: the ID of the tool call this message responds to. | string | no | — | — |
└ reasoning_contentOn assistant messages: the reasoning the model returned with that turn, echoed back verbatim. Kimi models expect it on every earlier assistant turn, tool-call turns included, to keep their reasoning across the conversation. | string | no | — | — |
temperatureWhat sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. We generally recommend altering this or top_p but not both. | number | no | — | 0–2 e.g. 0.8 |
max_completion_tokensAn upper bound for the number of tokens that can be generated for a completion, including visible output tokens and reasoning tokens. | number | no | — | — |
reasoning_effortConstrains effort on reasoning for reasoning models. Only applicable for o-series models. Reducing reasoning effort can result in faster responses and fewer tokens used on reasoning in a response. NOT supported together with function tools for the gpt-5.6, gpt-6 and gpt-6.1 sol/terra/luna models on this endpoint: such requests are rejected by the provider. They reason by default, so function tools are rejected on them even without reasoning_effort. | string | no | — | lowmediumhigh |
tool_choiceControls which (if any) tool is called by the model. none means the model will not call any tool and instead generates a message. auto means the model can pick between generating a message or calling one or more tools. required means the model must call one or more tools. | ToolChoiceParam | object | no | — | — |
toolsA list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported. | FunctionTool[] | no | — | — |
└ nameThe name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64. | string | no | — | — |
└ descriptionA description of what the function does, used by the model to choose when and how to call the function. | string | no | — | — |
└ parametersThe parameters the functions accepts, described as a JSON Schema object. | object | no | — | — |
└ strictWhether to enable strict schema adherence when generating the function call. | boolean | no | false | — |
└ type | string | yes | function | — |
service_tierSpecifies the processing type used for serving the request. | string | no | — | autoflexprioritydefault |
Response
Over HTTP the output arrives inside a status envelope, at response.result. ai.apis.run() unwraps that envelope for you and resolves to { result, usage } instead. Either way the result itself is the vendor's own shape.
{
"result": {
"id": "wf_abc123",
"created": 0,
"model": "gpt-6.1-sol",
"choices": [
{
"index": 0,
"message": {
"role": "…",
"content": "…",
"tool_calls": [],
"reasoning_content": "…"
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 0,
"completion_tokens": 0,
"total_tokens": 0,
"cache_creation_input_tokens": 0,
"cache_creation": {
"ephemeral_5m_input_tokens": 0,
"ephemeral_1h_input_tokens": 0
},
"prompt_tokens_details": {
"cached_tokens": 0,
"audio_tokens": 0
},
"completion_tokens_details": {
"reasoning_tokens": 0,
"audio_tokens": 0,
"accepted_prediction_tokens": 0,
"rejected_prediction_tokens": 0
},
"credits": 0
}
}
}{
"status": "success",
"response": {
"id": "wf_abc123",
"status": "COMPLETED",
"result": {
"id": "wf_abc123",
"created": 0,
"model": "gpt-6.1-sol",
"choices": [
{
"index": 0,
"message": {},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 0,
"completion_tokens": 0,
"total_tokens": 0,
"cache_creation_input_tokens": 0,
"cache_creation": {
"ephemeral_5m_input_tokens": 0,
"ephemeral_1h_input_tokens": 0
},
"prompt_tokens_details": {
"cached_tokens": 0,
"audio_tokens": 0
},
"completion_tokens_details": {
"reasoning_tokens": 0,
"audio_tokens": 0,
"accepted_prediction_tokens": 0,
"rejected_prediction_tokens": 0
},
"credits": 0
}
}
}
}Rates
What this model costs per generation, in USD. Every row is an exact rate — the columns are the settings that change it.
Charged after the request finishes, on what it actually used.
| Tier | Rate |
|---|---|
| Cached input | $0.20 / 1M cached input tokens |
| Input | $2.00 / 1M input tokens |
| Output text | $10.00 / 1M output text tokens |