Routing

Let Valefront choose with auto

Set model to auto on a chat-completions request. Valefront evaluates the request and routes it to an available model, with provider fallback behavior when supported.

curl https://llm.valefront.com/v1/chat/completions \
  -H "Authorization: Bearer $VALEFRONT_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"auto","messages":[{"role":"user","content":"Summarize this call"}]}'

Use an explicit model ID when your application needs a fixed target. The models and pricing page links to the live pricing response.

How auto picks

  1. Valefront goes through the providers in its pool in order and uses the first one that can serve the request.
  2. A provider is skipped when it is rate-limited or over its budget, reports itself unavailable, has no model switched on for routing, or cannot read the request's content (for example images).
  3. If the chosen provider fails, the request moves on to the next provider automatically (fallback); you get an error only when no provider could answer.
  4. The response tells you what answered: the model field holds the model that served the request.

Naming a model

Send a model ID (for example deepseek-v4-flash) to use that model. Valefront sends it to a provider that serves it, and falls back to another provider that serves the same model when one fails. Use auto-vision to route among models that read images.

Every request is billed at the published price of the model that answered, with no markup; see models and pricing.