Mistral Small 4 API

Hybrid model unifying Instruct, Reasoning (Magistral), and Devstral families: 40% lower completion time and 3x throughput vs Small 3.

Mistral AIText Generation256K contextProprietary Endpoint

About Mistral Small 4

Hybrid model unifying Instruct, Reasoning (Magistral), and Devstral families: 40% lower completion time and 3x throughput vs Small 3.

vision

Mistral Small 4 specs

Model ID
mistral-small-4
Provider
Mistral AI
Category
Text Generation
Context window
256K tokens
Max output
65,536 tokens
Input
text, image
Output
text
Endpoints
POST /v1/chat/completions
POST /v1/responses
POST /v1/messages

Mistral Small 4 API pricing

Live pay-as-you-go rates from the EmpirioLabs catalog. You are billed only for what you use, with no monthly minimum.

Type
Spec
Rate
Input
per 1M prompt tokens
$0.15
Output
per 1M generated tokens
$0.60
Standard Web Search
per call
$0.084
Premium Web Search
per call
$0.140
Code Interpreter
per call
$0.084
Image Generation
per image
$0.280
Compare on the full pricing page

How to call the Mistral Small 4 API

Mistral Small 4 serves the OpenAI-compatible Chat Completions API. Point any OpenAI SDK at https://api.empiriolabs.ai/v1 with your EmpirioLabs API key and use the model id mistral-small-4. Get an API key from the EmpirioLabs dashboard.

cURL
curl https://api.empiriolabs.ai/v1/chat/completions \
  -H "Authorization: Bearer $EMPIRIOLABS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "mistral-small-4",
    "messages": [
      {"role": "user", "content": "Write a haiku about the ocean."}
    ]
  }'
Python (OpenAI SDK)
from openai import OpenAI

client = OpenAI(
    base_url="https://api.empiriolabs.ai/v1",
    api_key="YOUR_EMPIRIOLABS_API_KEY",
)

response = client.chat.completions.create(
    model="mistral-small-4",
    messages=[{"role": "user", "content": "Write a haiku about the ocean."}],
)
print(response.choices[0].message.content)
Full Mistral Small 4 API reference

Mistral Small 4 API parameters

Request parameters supported by the Mistral Small 4 API on EmpirioLabs. Defaults apply when a field is omitted.

ParameterTypeDefaultRange / valuesDescription
reasoning_enabledbooleantrue-Enable extended reasoning (maps to reasoning: high|none)
tool_web_searchbooleantrue-Enable web_search tool
web_search_tierenumstandardstandard, premiumStandard or Premium web-search tier. Premium uses higher-quality sources.
tool_code_interpreterbooleantrue-Allow the model to execute Python code in a sandbox to compute / analyze data.
tool_image_generationbooleantrue-Allow the model to generate images inline via the platform image-gen tool.
temperaturenumber0.70 to 1.5Sampling temperature. 0 = deterministic, 2 = maximum randomness.
max_tokensnumber40961 to 32768Maximum tokens in the response.
disable_formattingbooleanfalse-Skip the EmpirioLabs Markdown formatting (citation [[N]](url) rewriting + References block when the web_search tool was used). The raw upstream answer with plain [N]...

Good to know

Tools (web search, code interpreter, image generation) are billed only when actually invoked.

Mistral Small 4 API: common questions

How much does the Mistral Small 4 API cost?

On EmpirioLabs, Mistral Small 4 is billed pay as you go: Input $0.15 per 1M prompt tokens; Output $0.60 per 1M generated tokens; Standard Web Search $0.084 per call. The live rate card on this page always matches what the API charges.

What is the context window of Mistral Small 4?

Mistral Small 4 supports a 256K-token context window with up to 65,536 output tokens per response.

Is the Mistral Small 4 API OpenAI-compatible?

Yes. Mistral Small 4 serves the OpenAI-compatible Chat Completions API, so existing OpenAI SDKs work by pointing base_url at https://api.empiriolabs.ai/v1 and setting the model id to mistral-small-4.

Can I try Mistral Small 4 in the browser before integrating?

Yes. The EmpirioLabs playground runs Mistral Small 4 in the browser with the same parameters the API exposes, so you can test prompts before writing code.

How do I get a Mistral Small 4 API key?

Create an EmpirioLabs account, then generate a key under API Keys in the dashboard. Billing is pay-as-you-go credits, so you only pay for the requests you make.

Ready to use better endpoints?

Explore our models, or contact us about business inquiries, custom deployments, or anything else.