Route matching selects a provider for one inbound request. Provider protocol then decides the outbound wire behavior.
| Field | Role |
|---|
name | Optional stable identifier used by --route-override |
request_protocol | Optional inbound protocol guard: openai_responses, openai_chat_completions, or anthropic_messages |
match_kind | exact, glob, regex, or auto |
model_pattern | Logical model selector matched against the inbound model |
provider | Provider name selected when the route matches |
upstream_model | Optional model rewrite applied before the provider request is serialized |
| Condition | Outcome |
|---|
| Model does not match any explicit route | Use routing.default_provider_names.<inbound_protocol> |
Model matches and request_protocol is omitted | Route can match the detected inbound protocol |
Model matches and explicit request_protocol equals detected protocol | Use the route provider |
Model matches but explicit request_protocol differs | Return a configuration error instead of falling through |
| Selected provider protocol differs from inbound protocol | Use the explicit translation pair if supported; otherwise fail explicitly |