Model catalog
DeepSeek V4.1 Flash API pricing and integration
DeepSeek V4.1 Flash (deepseek-v4.1-flash) on ProxyStacks Relay — input $0.180, output $0.740 per 1M tokens. Pay as you go from the same balance as every other model.
deepseek-v4.1-flash1,000,000 tokensStreaming40% below list| Billing item | Peak | Off-peak |
|---|---|---|
| Input | $0.180 | $0.090 |
| Output | $0.740 | $0.370 |
| Cache hit | $0.0039 | $0.0020 |
| Cache write · 5m TTL | <$0.0001 | <$0.0001 |
| Cache write · 1h TTL | <$0.0001 | <$0.0001 |
Official list / 1M: $0.30 / $1.20 · Official list price is shown for comparison; Relay bills the rates above.
Off-peak hours · GMT+8: Sat, Sun 00:00–23:59, Mon–Fri 00:00–08:59, Mon–Fri 12:00–13:59, Mon–Fri 18:00–23:59 · Billing items without a dedicated off-peak rate charge the peak price during off-peak hours.
Connect this model
Set RELAY_API_KEY in your environment. Install openai or anthropic for the corresponding Python example. Keep secrets out of source control.
import os
from openai import OpenAI
client = OpenAI(
api_key=os.environ["RELAY_API_KEY"],
base_url="https://proxystacks.com/v1",
)
response = client.chat.completions.create(
model="deepseek-v4.1-flash",
messages=[{"role": "user", "content": "Hello!"}],
)
print(response.choices[0].message.content)import os
from anthropic import Anthropic
client = Anthropic(
api_key=os.environ["RELAY_API_KEY"],
base_url="https://proxystacks.com/anthropic",
)
response = client.messages.create(
model="deepseek-v4.1-flash",
max_tokens=256,
messages=[{"role": "user", "content": "Hello!"}],
)
print(response.content){
"env": {
"ANTHROPIC_AUTH_TOKEN": "sk-relay-your-key",
"ANTHROPIC_BASE_URL": "https://proxystacks.com/anthropic",
"ANTHROPIC_DEFAULT_OPUS_MODEL": "deepseek-v4.1-flash",
"ANTHROPIC_DEFAULT_SONNET_MODEL": "deepseek-v4.1-flash",
"ANTHROPIC_DEFAULT_HAIKU_MODEL": "deepseek-v4.1-flash",
"ANTHROPIC_SMALL_FAST_MODEL": "deepseek-v4.1-flash"
}
}Model questions
What is the exact API model ID and endpoint for DeepSeek V4.1 Flash?
Pass model="deepseek-v4.1-flash" to https://proxystacks.com/v1 (OpenAI-compatible Chat Completions / Responses) or https://proxystacks.com/anthropic (Anthropic Messages for Claude Code).
Does this model support streaming?
Supported
What is the context window?
1,000,000 tokens
How is cached usage billed?
Cache reads and writes are separate billing items. The rate card above lists USD per 1M tokens; actual cache usage depends on the upstream model and request.
When do off-peak prices apply?
Sat, Sun 00:00–23:59, Mon–Fri 00:00–08:59, Mon–Fri 12:00–13:59, Mon–Fri 18:00–23:59 (Asia/Shanghai). Billing items without a dedicated off-peak rate charge the peak price during off-peak hours.
Specs
- Context window
- 1,000,000 tokens
- Streaming
- Supported