Mistral AI: Codestral
mistral/codestral-2508Available via Safeguard
Public cloudPrivate cloud
Released
July 30, 2025
Context
128,000 tokens
Input
$0.30 / 1M tokens
Output
$0.90 / 1M tokens
Overview
Code model for low-latency tasks such as fill-in-the-middle completion and code generation.
- Provider
Mistral AI
- Modality
- Text
- Input
- text
- Output
- text
- Weights
- Closed
- Supported parameters
- tools, structured_outputsProvider's model page, checked .
- Tags
- coding, fim
Data policy
- Prompts go to
- Mistral AI (global endpoint by default)
- Retention
- Commercial terms: no training on customer data unless opted in, with exceptions, Studio Free mode may train on inputs and outputs (opt-out available), pay-as-you-go can opt out, ZDR available on pay-as-you-go for stateless endpoints
- Zero data retention
- Available
- Region
- Global by default, optional EU or US regional inference endpoints at 1.1x pricing
- Policy
- Mistral AI data policy
Summarised from the provider's published terms. The provider's own policy is what applies.
Where you can run it
How Codestral can be deployed, bought and reached through Safeguard.
- Deployment
- Public cloudPrivate cloud
- Procurement
- Not published yet
- Inference regions
- Not published yet
Closed weights stay with the provider, so this model runs in the provider's cloud, never on-prem.
Pricing
| Provider | Input / 1M tokens | Output / 1M tokens | Context |
|---|---|---|---|
| Mistral AI | $0.30 | $0.90 | 128K |
- Notes
- Standard tier. Cached input $0.03.
- Source
- Mistral AI pricing , last verified October 27, 2026
No markup on model usage: you pay the provider's list price.
API
OpenAI-compatible. Your API key and access to this model are set up for your workspace when you choose Use with Safeguard.
from openai import OpenAI
client = OpenAI(
base_url="https://api.safeguard.sh/gpt/v1",
api_key="SAFEGUARD_API_KEY",
)
response = client.chat.completions.create(
model="mistral/codestral-2508",
messages=[{"role": "user", "content": "Hello"}],
)
print(response.choices[0].message.content)Base URL https://api.safeguard.sh/gpt/v1, model mistral/codestral-2508.
Self-healing security runs on Safeguard.
Your first fix PR is minutes away.
No sales call required, even your agent can complete the purchase over MCP.