Preview

Revoke an API key

Revokes an API key so it can no longer authenticate API requests. If the target credential is a publishable key, Paypercut rotates it and returns a replacement because each account must retain a current publishable key.

Access is not enabled by default. Customers must request API key management permissions from Paypercut before using this endpoint. The acting principal must have permission to revoke API keys for the account.

Revoke keys that are no longer used, were created for a retired integration, or may have been exposed.

Path Parameters
  • id
    Type: string
    max length:  
    100
    required

    API key identifier.

Responses
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
Request Example for post/v2/credentials/api-keys/{id}/revoke
curl 'https://api.paypercut.io/v2/credentials/api-keys/{id}/revoke' \
  --request POST \
  --header 'Authorization: Bearer YOUR_SECRET_TOKEN'
{
  "action": "revoked",
  "replacement": {
    "id": "ak_123",
    "secret": "sk_test_1234567890abcdef"
  }
}