DeepSeek V4.1 Flash
AvailableDeepSeek V4.1 Flash is the small, low-cost model in DeepSeek’s V4 family.
Good for Fast and cheap · Images and screenshots · Bulk and batch jobs
Is it right for you?
It answers quickly and is priced for volume, which suits the many short calls a coding agent makes: reading a file, proposing a small edit, running a tool and reading the result. Reasoning is optional, so you can switch it off when you want a fast, plain answer.
Best for
- High-volume agent loops where the price per request matters more than the last bit of quality.
- Background and helper tasks in Claude Code (the small/fast model slot), summaries and commit messages.
- Off-peak batch jobs: classification, extraction and code review comments over many files.
Not ideal for
- Large refactors that need careful planning across many files; try DeepSeek V4 Pro or GLM-5.3.
- Prompts longer than 128K tokens, the limit in our catalogue today.
Next to the rest of the DeepSeek line
| Model | Input | Output | Context | Per session |
|---|---|---|---|---|
| DeepSeek V4 Pro | $0.9307 | $2.4295 | 128K | $0.1894 |
| DeepSeek V4.1 Flash (this page) | $0.2146 | $0.8584 | 128K | $0.0536 |
What it costs
Prepaid, per token, no subscription. Set your traffic to see your bill.
30 days, at today's prices. You're billed on actual tokens.
- Per request
- $0.000985
- Coding session
- $0.05
- Per day
- $1.97
- Suggested key budget
- $70.00
- Alert at 80%
- $56.00
A coding session is 30 requests of 20,000 input tokens, 80% from cache, and 1,000 output tokens each: the same session as the "Per session" column above. Thinking tokens are billed as output, so reasoning raises the cost.
This model has peak and off-peak prices. A request is billed at the price in force when it starts, even if it finishes after the boundary. Batch requests (POST /v1/batches, up to 1,000 per batch) wait for the off-peak window.
Capabilities
What DeepSeek V4.1 Flash can do, as DeepSeek lists it.
| Capability | Support |
|---|---|
| Reasoning | Optional, on by default |
| Image input | Yes: text and image in, text out |
| JSON output | JSON mode yes; structured outputs on some hosts |
| Streaming | Yes |
| Prompt caching | Cache-read price listed |
Get started
Create a key in the console, export it as YUNSHU_API_KEY, then use one of these.
export ANTHROPIC_BASE_URL=https://api.yunshurouter.com
export ANTHROPIC_AUTH_TOKEN=$YUNSHU_API_KEY
export ANTHROPIC_MODEL=deepseek-v4.1-flashcurl https://api.yunshurouter.com/v1/chat/completions \
-H "Authorization: Bearer $YUNSHU_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "deepseek-v4.1-flash",
"messages": [{"role": "user", "content": "Write a Python function that reverses a string."}]
}'curl https://api.yunshurouter.com/v1/messages \
-H "x-api-key: $YUNSHU_API_KEY" \
-H "anthropic-version: 2023-06-01" \
-H "Content-Type: application/json" \
-d '{
"model": "deepseek-v4.1-flash",
"max_tokens": 1024,
"messages": [{"role": "user", "content": "Write a Python function that reverses a string."}]
}'import os
from openai import OpenAI
client = OpenAI(
base_url="https://api.yunshurouter.com/v1",
api_key=os.environ["YUNSHU_API_KEY"],
)
response = client.chat.completions.create(
model="deepseek-v4.1-flash",
messages=[{"role": "user", "content": "Write a Python function that reverses a string."}],
)
print(response.choices[0].message.content)import os
from anthropic import Anthropic
client = Anthropic(
base_url="https://api.yunshurouter.com", # no /v1: the SDK adds it
api_key=os.environ["YUNSHU_API_KEY"],
)
message = client.messages.create(
model="deepseek-v4.1-flash",
max_tokens=1024,
messages=[{"role": "user", "content": "Write a Python function that reverses a string."}],
)
print(message.content[0].text)Full steps for each tool: integration guides →
Questions
What is DeepSeek V4.1 Flash?
DeepSeek V4.1 Flash is a fast, low-cost language model from DeepSeek, part of its V4 family. It is aimed at high-volume work such as coding-agent tool loops, summaries and extraction.
Does DeepSeek V4.1 Flash support tool calling?
Yes. Tool calling works in both the OpenAI format (tools) and the Anthropic format (tools with input_schema).
Does DeepSeek V4.1 Flash support reasoning?
Yes. Reasoning is optional on this model and on by default at the provider. On Yunshu Router you can turn it on or off per request.