Skip to content

Providers

BatchRouter is a routing marketplace: when you submit a batch, the router picks the cheapest eligible provider lane that meets your requirements. Providers are the upstream services behind those lanes — hyperscale APIs like OpenAI and Anthropic, aggregators, and managed edge networks that onboard through the same provider contract. The provider directory is public and read-only, so you can see who can run your work before you create a batch.

This guide covers the two provider endpoints and how providers relate to lanes and the routing_mode you choose at quote and create time.

GET /v1/providers returns the public provider directory — each entry’s slug, display_name, description, is_enabled status, and the supported_operations it can run.

Terminal window
curl https://api.batchrouter.com/v1/providers \
-H "Authorization: Bearer $BATCHROUTER_API_KEY"

The response is a providers array. Fields below are illustrative — slugs and names you see are real, but treat values as a snapshot:

{
"providers": [
{
"slug": "openai",
"display_name": "OpenAI",
"description": "Native OpenAI Batch API for responses and embeddings.",
"is_enabled": true,
"supported_operations": ["responses", "embeddings"]
},
{
"slug": "anthropic",
"display_name": "Anthropic",
"description": "Anthropic Messages batch API.",
"is_enabled": true,
"supported_operations": ["responses"]
}
]
}

GET /v1/providers/{slug} returns a single provider keyed by its slug (for example openai). The response wraps the same provider shape under a provider key and includes the provider’s supported_operations and models. A provider profile may also carry richer marketplace metadata — serving/residency regions, capacity signals, and the provider’s declared data-retention policy — used by the router when it ranks lanes. The full, authoritative field list is in the API reference; fetch a live provider to see exactly what it exposes.

Terminal window
curl https://api.batchrouter.com/v1/providers/openai \
-H "Authorization: Bearer $BATCHROUTER_API_KEY"

An unknown slug returns 404.

A lane is a concrete way to run a piece of work: a specific provider serving a specific model in a specific region. One provider typically offers several lanes. When you quote or create a batch, the router applies your hard requirements (model, region/residency, privacy tier, required hosted tools, deadline), discards lanes that can’t satisfy them, then ranks what’s left — by price for direct routes — and selects the cheapest eligible lane (splitting across lanes when one can’t finish in time).

routing_mode lets you constrain which providers are even considered:

routing_modeEffect on provider selection
cheapest (default)Any eligible lane, ranked by price.
sla_awareBalances price against the provider’s reliability and capacity for your SLA tier.
public_onlyRestricts routing to public/hyperscale provider lanes (e.g. OpenAI, Anthropic).
edge_onlyRestricts routing to managed edge provider lanes onboarded to the marketplace.
hybridAllows both public and edge lanes.
privacy_constrainedOnly lanes whose provider satisfies your privacy_tier and data-handling rules.

Every quote and every batch returns a routing receipt naming the selected lane(s) and why other eligible lanes were not chosen — so a public_only or edge_only choice is always auditable. See How routing works for the full ranking and rejection model.