DeepSeek v4.1 Flash
deepseek-v4.1-flashUse the DeepSeek v4.1 Flash API for chat, coding, and reasoning. Send conversation messages to get a text response through a chat completions route. Build assistants that explain errors, review changes, and draft fixes. Compare the available provider routes, request examples, and usage prices on OpenAny.
- Published price
- From $0.116 / 1M tokens
- Billing unit
- / 1M tokens
- Context / Max output
- — / —
- Listed routes
- 2
Other parameters (14)
Result preview
Neolink · 191ms
Response example. Run to see the actual response.
{
"id": "chatcmpl-0bda71b2-52a7-97e6-a047-fdf6936ceb1b",
"model": "deepseek-v4.1-flash",
"usage": {
"total_tokens": 76,
"prompt_tokens": 31,
"completion_tokens": 45,
"prompt_tokens_details": {
"text_tokens": 31,
"cached_tokens": 0
},
"completion_tokens_details": {
"text_tokens": 9,
"reasoning_tokens": 35
}
},
"object": "chat.completion",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Hello! How can I help you today?",
"reasoning_content": "We need answer greeting. User says hello. Need maybe respond. We need final only. But system says API, desired oververbosity 5. We can just greet."
},
"finish_reason": "stop"
}
],
"created": 1789456959,
"openmodels_cost": 57
}- Base URL
https://api.openany.si/v1- POST
/v1/chat/completions- Authentication
Authorization: Bearer $OPENANY_API_KEY
Request parameters
| Parameter | Type / range | Default value | Required | Description |
|---|---|---|---|---|
messages | array | — | Yes | Messages in conversation order. |
model | string | — | Yes | Public model name used by OpenAny. |
logprobs | boolean | — | No | logprobs |
max_tokens | integer · 1 ~ 393216 | — | No | max_tokens |
reasoning_effort | string · none | minimal | low | medium | high | xhigh | max | — | No | Reasoning effort level. |
response_format | object | — | No | response_format |
route | object | — | No | OpenAny routing settings. |
route_mode | string | — | No | OpenAny route selection mode. |
stop | string | array | — | No | stop |
stream | boolean | — | No | Enable streaming responses. |
stream_options | object | — | No | stream_options |
temperature | number · 0 ~ 2 | — | No | temperature |
thinking | object | — | No | Thinking mode for the model. |
tool_choice | string | object | — | No | tool_choice |
tools | array | — | No | tools |
top_logprobs | integer · 0 ~ 20 | — | No | top_logprobs |
top_p | number · <= 1 | — | No | top_p |
user_id | string | — | No | user_id |
Request example
curl 'https://api.openany.si/v1/chat/completions' \
-H "Authorization: Bearer $OPENANY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"messages": [
{
"content": "Hello!",
"role": "user"
}
],
"model": "deepseek-v4.1-flash",
"route_mode": "balanced"
}'Response example
Configured response example · not a live result
{
"id": "chatcmpl-0bda71b2-52a7-97e6-a047-fdf6936ceb1b",
"model": "deepseek-v4.1-flash",
"usage": {
"total_tokens": 76,
"prompt_tokens": 31,
"completion_tokens": 45,
"prompt_tokens_details": {
"text_tokens": 31,
"cached_tokens": 0
},
"completion_tokens_details": {
"text_tokens": 9,
"reasoning_tokens": 35
}
},
"object": "chat.completion",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Hello! How can I help you today?",
"reasoning_content": "We need answer greeting. User says hello. Need maybe respond. We need final only. But system says API, desired oververbosity 5. We can just greet."
},
"finish_reason": "stop"
}
],
"created": 1789456959,
"openmodels_cost": 57
}Error handling
400Check the model ID and request fields.429Retry with exponential backoff.5xxRetry only temporary provider failures.JSON Schema
{
"type": "object",
"allOf": [
{
"if": {
"required": [
"top_logprobs"
],
"properties": {
"top_logprobs": {
"type": "integer"
}
}
},
"then": {
"required": [
"logprobs"
],
"properties": {
"logprobs": {
"const": true
}
}
}
}
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"model",
"messages"
],
"properties": {
"stop": {
"anyOf": [
{
"type": "string"
},
{
"type": "array",
"items": {
"type": "string"
},
"maxItems": 16,
"minItems": 1
}
]
},
"model": {
"type": "string",
"minLength": 1,
"description": "Public model name used by OpenAny."
},
"route": {
"type": "object",
"properties": {
"provider": {
"type": "string"
}
},
"description": "OpenAny routing settings."
},
"tools": {
"type": "array",
"items": {
"type": "object",
"required": [
"type",
"function"
],
"properties": {
"type": {
"const": "function"
},
"function": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string"
},
"strict": {
"type": "boolean"
},
"parameters": {
"type": "object"
},
"description": {
"type": "string"
}
}
}
}
}
},
"top_p": {
"type": "number",
"maximum": 1,
"exclusiveMinimum": 0
},
"stream": {
"type": "boolean",
"description": "Enable streaming responses."
},
"user_id": {
"type": "string"
},
"logprobs": {
"type": "boolean"
},
"messages": {
"type": "array",
"items": {
"type": "object",
"allOf": [
{
"if": {
"properties": {
"role": {
"enum": [
"user",
"system",
"developer"
]
}
}
},
"then": {
"required": [
"content"
],
"properties": {
"content": {
"anyOf": [
{
"type": "string"
},
{
"type": "array",
"items": {
"type": "object",
"required": [
"type"
],
"properties": {
"text": {
"type": "string"
},
"type": {
"type": "string"
},
"image_url": {
"type": "object",
"required": [
"url"
],
"properties": {
"url": {
"type": "string"
}
}
}
}
}
}
]
}
}
}
},
{
"if": {
"properties": {
"role": {
"const": "tool"
}
}
},
"then": {
"required": [
"tool_call_id",
"content"
]
}
}
],
"required": [
"role"
],
"properties": {
"name": {
"type": "string"
},
"role": {
"enum": [
"system",
"user",
"assistant",
"tool"
],
"type": "string"
},
"content": {
"anyOf": [
{
"type": "string"
},
{
"type": "array",
"items": {
"type": "object",
"required": [
"type"
],
"properties": {
"text": {
"type": "string"
},
"type": {
"type": "string"
},
"image_url": {
"type": "object",
"required": [
"url"
],
"properties": {
"url": {
"type": "string"
}
}
}
}
}
},
{
"type": "null"
}
]
},
"tool_calls": {
"type": "array",
"items": {
"type": "object"
}
},
"tool_call_id": {
"type": "string"
},
"reasoning_content": {
"type": "string"
}
}
},
"minItems": 1,
"description": "Messages in conversation order."
},
"thinking": {
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"enum": [
"enabled",
"disabled"
],
"type": "string"
}
},
"description": "Thinking mode for the model."
},
"max_tokens": {
"type": "integer",
"maximum": 393216,
"minimum": 1
},
"route_mode": {
"type": "string",
"description": "OpenAny route selection mode."
},
"temperature": {
"type": "number",
"maximum": 2,
"minimum": 0
},
"tool_choice": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
"top_logprobs": {
"type": "integer",
"maximum": 20,
"minimum": 0
},
"stream_options": {
"type": "object",
"properties": {
"include_usage": {
"type": "boolean"
}
}
},
"response_format": {
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"enum": [
"text",
"json_object"
],
"type": "string"
}
}
},
"reasoning_effort": {
"enum": [
"none",
"minimal",
"low",
"medium",
"high",
"xhigh",
"max"
],
"type": "string",
"description": "Reasoning effort level."
}
}
}Request example
POST /v1/chat/completionscurl 'https://api.openany.si/v1/chat/completions' \
-H "Authorization: Bearer $OPENANY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"messages": [
{
"content": "Hello!",
"role": "user"
}
],
"model": "deepseek-v4.1-flash",
"route_mode": "balanced"
}'Model API questions
How do I call DeepSeek v4.1 Flash through OpenAny?
Use model ID deepseek-v4.1-flash with an OpenAny key and the operation published in this model's API tab. The model API base is https://api.openany.si/v1. Confirm the protocol and request schema; model availability does not imply every OpenAI API operation is supported.
How is DeepSeek v4.1 Flash billed?
Compare the published rate and billing unit of the selected provider route. Input, output and cache token rates may differ. Image, audio and video models can use other units. Recorded usage determines the charge under that route's billing contract.
Are Community and Verified routes the same as an official publisher API?
No. Inspect the provider name and supply classification for the specific route. A marketplace listing or a supply label is not a claim of publisher endorsement, identical service or measured uptime. Different route prices may reflect different supply and conditions.
Where do these prices come from, and when were they updated?
Rates come from the provider routes in OpenAny's public model catalog, not an independent quote from the model publisher. The catalog does not supply a price update timestamp. A page or catalog snapshot date is not a price revision date. Compare supply, billing units, tiers and conditions; a lower listed rate alone does not establish equivalent service or explain the price difference.
Use DeepSeek v4.1 Flash with your agent
Inspect endpoint contracts and confirm availability and pricing before a paid call.