v1

latestOpenAPI 3.0.02026-07-17112116167.8 KB
Workspace API Keys

Mint a workspace API key

Returns the secret ONCE in the response body. At least one Available scope must be provided.

post/api/workspaces/{wid}/api-keys

Path parameters

widstring required

Workspace id

Request body

expires_atstring
namestring required
scopesstring[] required

Example request

{
  "expires_at": "2026-08-20T08:30:00Z",
  "name": "my-bot-integration",
  "scopes": [
    "[\"turns:submit\"]"
  ]
}

Response

Created

created_atstring required
expires_atstring required
idstring required
namestring required
prefixstring required
scopesstring[] required
secretstring required

Example response

{
  "expires_at": "2026-08-20T08:30:00Z",
  "id": "ask_a1b2c3d4e5f6g7h8",
  "prefix": "ask_a1b2c3d4e5f6g7h8",
  "secret": "ask_a1b2c3d4e5f6g7h8_X9y8Z7w6V5u4T3s2R1q0P9o8N7m6L5k4J3i2H1g0F9e8D7c6B5a4AbCdEf"
}