Create a route

Add a new routing rule. The rule is active for new requests within a few seconds — the gateway re-reads rules at a short polling interval.

POST /v1/routes Preview
https://api.routeur.ai

Request body

name string required
Unique within the organisation. Surfaced in trace metadata.
priority integer optional · default 0
Higher numbers evaluate first.
enabled boolean optional · default true
Create disabled if you want to stage a rule without it taking effect.
action_kind pin | auto required
Resolution strategy.
match object required
Match condition. Currently supports requested_model.
action object required
For pin, supply provider and model.

Returns

The newly created Route object.