Docs

API reference · AI gateway

Create an alias: a model name for clients and the catalogued models it routes to

POST/v1/orgs/{org}/ai/aliases

Create an alias: a model name for clients and the catalogued models it routes to. Every target passes the region check

Permission
ai.aliases.manage
Audit log
ai.alias.create
Operation
ai.aliases.create

Parameters

NameInTypeRequiredNotes
orgpathstringyesfor example "org_01h455vb4pex5vsknk084sn02q"
Idempotency-KeyheaderstringnoOne key per intended mutation. A retry with the key replays the recorded response instead of executing again; the key with another request answers 422 idempotency_key_reused. For example "01h455vb4pex5vsknk084sn02q"
x-obhut-management-assignmentheaderstringnoSelect one staff assignment. Direct membership remains the default. Bound API tokens use their stored source and ignore this selector. For example "masg_01h455vb4pex5vsknk084sn02q"

Request body

FieldTypeRequiredNotes
strategystringyesone of "priority", "weighted", "cheapest"
targetsarray of objectyes1 to 16 items
targets[].modelstringyesfor example "cm_01h455vb4pex5vsknk084sn02q"
targets[].credentialstringnofor example "pcr_01h455vb4pex5vsknk084sn02q"
targets[].weightintegerno1 to 10000
namestringyes

Response 201

FieldTypeRequiredNotes
idstringyesfor example "als_01h455vb4pex5vsknk084sn02q"
orgIdstring or nullyes
namestringyes
strategystringyesone of "priority", "weighted", "cheapest"
targetsarray of objectyes
targets[].modelstringyesfor example "cm_01h455vb4pex5vsknk084sn02q"
targets[].providerstringyes
targets[].providerModelstringyes
targets[].locationstringyes
targets[].credentialstringyesfor example "pcr_01h455vb4pex5vsknk084sn02q"
targets[].ownCredentialbooleanyes
targets[].weightinteger or nullyes
shadowedbooleanyes
createdAtstring (date-time)yesUTC, ISO 8601.
updatedAtstring (date-time)yesUTC, ISO 8601.