Skip to main content
POST
/
api
/
keys
Create a gateway API key
curl --request POST \
  --url https://litellm-rust.onrender.com/api/keys \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "label": "alice"
}
'
{
  "id": "<string>",
  "label": "<string>",
  "key": "<string>"
}

Authorizations

Authorization
string
header
required

Your LITELLM_MASTER_KEY. Default for local Docker Compose: sk-local

Body

application/json
label
string
Example:

"alice"

Response

Created. The secret is returned once.

id
string
label
string
key
string

The secret value — shown once, store it now.