ZITADEL Docs
APIsCore ResourcesV2User

Add a Key

Add a keys that can be used to securely authenticate at the Zitadel APIs using JWT profile authentication using short-lived tokens. Make sure you store the returned key safely, as you won't be able to read it from the Zitadel API anymore. Only users of type machine can have keys.

Required permission:

  • user.write
POST
/v2/users/{user_id}/keys

Path Parameters

user_id*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://loading/v2/users/string/keys" \  -H "Content-Type: application/json" \  -d '{}'
{
  "creationDate": "2023-01-15T01:30:15.01Z",
  "keyId": "string",
  "keyContent": "string"
}

Was this page helpful?