Inference Providers

Create an AI Gateway API key

Changed on

Creates 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.

post/v1/org/ai-gateway/api-keys/mine

Request

  • Base URL
    https://api.openworklabs.com
  • Auth
    • API key in header x-api-key
    • or HTTP bearer

Request body

CreateGatewayApiKeyRequest required
name, string required
expiresAt, string date-time nullable

Response

Key created.

object required
apiKey, object required
key, string required

Changes

    • breaking

      response property apiKey/expiresAt list-of-types was widened by adding types null to media type application/json of response 201

    • breaking

      response property apiKey/lastUsedAt list-of-types was widened by adding types null to media type application/json of response 201

    • info

      the apiKey/createdAt response'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