Skip to main content
PATCH
/
keys
/
{id}
Update a virtual key
curl --request PATCH \
  --url https://api.wardin.ai/v1/keys/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "monthlyBudgetUsd": 123,
  "rpmLimit": 123,
  "tpmLimit": 123
}
'
{
  "id": "<string>",
  "name": "<string>",
  "monthlyBudgetUsd": 123,
  "currentSpendUsd": 123,
  "rpmLimit": 123,
  "tpmLimit": 123,
  "createdAt": "2023-11-07T05:31:56Z"
}

Authorizations

Authorization
string
header
required

A wardin_sk_ virtual key with manager-level access.

Path Parameters

id
string
required

Body

application/json
name
string
monthlyBudgetUsd
number | null
rpmLimit
integer | null
tpmLimit
integer | null
status
enum<string>
Available options:
active,
paused

Response

200 - application/json

OK

id
string
name
string
monthlyBudgetUsd
number | null
currentSpendUsd
number
rpmLimit
integer | null
tpmLimit
integer | null
status
enum<string>
Available options:
active,
paused,
budget_exceeded,
revoked
createdAt
string<date-time>