Update a routing policy

Update in place; the policy id is stable across updates.

Authentication

AuthorizationBearer

A management key (prefixed mgmt_), created in the dashboard under Settings, API keys, Management keys. Distinct from a regular gateway API key, and never used to call models.

Path parameters

policy_idstringRequiredformat: "uuid"

Request

This endpoint expects an object.
namestringOptional<=255 characters
descriptionstringOptional
is_defaultbooleanOptional
strategyenumOptional
allowed_providerslist of stringsOptional

INTELLIGENT only, optional. If provided, must match the providers of allowed_models (it does not filter independently); returned derived from allowed_models on reads.

allowed_modelslist of stringsOptional
priority_orderlist of objectsOptional
axisenumOptional

INTELLIGENT only. Optimization axis the router optimizes for; defaults to COST.

Response

The updated policy.
idstringOptionalformat: "uuid"
namestringOptional
descriptionstringOptional
strategyenumOptional
allowed_providerslist of stringsOptional
allowed_modelslist of stringsOptional
priority_orderlist of objectsOptional
axisenumOptional

Optimization axis the router optimizes for (INTELLIGENT only, else null); one of COST, PERFORMANCE, CAPABILITY.

created_atdatetimeOptional
modified_atdatetimeOptional

Errors

404
Not Found Error
422
Unprocessable Entity Error