Descope Website
POST
/v1/mgmt/accesskey/update

Update an existing access key, using a valid management key.

This API endpoint allows administrators to update an existing access key. With this endpoint, you can only update the access key's name.

See also

Endpoint Authentication

Use authorization bearer header with the following format:

Authorization: Bearer <ProjectId:ManagementKey>

Authorization

Authorization
Required
Bearer <token>

< Project ID >:< Management Key > as bearer

In: header

Request Body

idstring

namestring

descriptionstring

roleNamesunknown

we want to differentiate between empty and nil so we use google.protobuf.Value

keyTenantsunknown

Represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values.

customClaimsobject

permittedIpsunknown

Represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values.

Status codeDescription
200OK

Try it

/v1/mgmt/accesskey/update

The Authorization access token

curl -X POST "https://api.descope.com/v1/mgmt/accesskey/update" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <ProjectId:ManagementKey>" \
  -d '{
  "id": "string",
  "name": "string",
  "description": "string",
  "roleNames": null,
  "keyTenants": null,
  "customClaims": {},
  "permittedIps": null
}'

{
  "key": {
    "id": "string",
    "name": "string",
    "roleNames": [
      "string"
    ],
    "keyTenants": [
      {
        "tenantId": "string",
        "roleNames": [
          "string"
        ],
        "tenantName": "string"
      }
    ],
    "status": "string",
    "createdTime": 0,
    "expireTime": 0,
    "createdBy": "string",
    "clientId": "string",
    "boundUserId": "string",
    "customClaims": {},
    "editable": true,
    "description": "string",
    "permittedIps": [
      "string"
    ]
  }
}

Was this helpful?