Create an AI Gateway API key
Changed onCreates an AI Gateway API key for the caller, with a name and an optional expiry, and returns it once; Den keeps only a digest. An expired key is refused by the Gateway. The key reaches the models the caller's grants allow, through GET /api/v1/models and the provider-less endpoints. A member may hold 20 unexpired keys. Refused while the organization does not allow member keys.
Request
- Base URLhttps://api.openworklabs.com
- Auth
- API key in header x-api-key
- or HTTP bearer
Request body
Response
Key created.
Changes
- breaking
response property
apiKey/expiresAtlist-of-types was widened by adding typesnullto media typeapplication/jsonof response201 - breaking
response property
apiKey/lastUsedAtlist-of-types was widened by adding typesnullto media typeapplication/jsonof response201 - info
the
apiKey/createdAtresponse's property pattern^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$was added for the status
- breaking