Skip to main content

Set Admin API key

post
/api/pvlt/1.0/ctl/iam/admin/set-api-key

Set the API key of the Admin user.

Vault always has an Admin user account, which you use to update the configuration of Vault.

The API key should meet the specified criteria:

  • It must be at least 15 characters long.
  • It must contain a mix of digits, lowercase letters, and uppercase letters.

This API is restricted to the Admin user.
The Admin API Key can be also set using the environment variable PVAULT_SERVICE_ADMIN_API_KEY

Request

Request body

The API key of the Admin user to set.

object required*
  • key - string required*

    The new API key for the Admin user.

Example
{
"key": "string"
}

Possible responses

The request is successful.

Try the API

Authorization

Request body

Navigate to the docs of your local Vault installation to try the API directly from there.

Code examples

Example