Personal Access Tokens

Admin: revoke any user's personal access token by id

Changed on

Revokes a token by id, scoped to the org's PAT client but not to a specific owning user — the admin counterpart to DELETE /personal-access-tokens/{tokenId}. Requires org-admin privileges (userAdminCheck); a non-admin caller gets 403 (ForbiddenError), same as GET /personal-access-tokens/admin.

delete/personal-access-tokens/admin/{tokenId}

Request

  • Base URL
    https://app.pipeshub.com/api/v1
  • URL
    https://app.pipeshub.com/api/v1/personal-access-tokens/admin/{tokenId}
  • Auth
    HTTP bearer

Path parameters

tokenIdstring required

Personal access token ID

Request body

reasonstring

Stored on the revocation for auditing. There is no body validator: a reason that is not a string is ignored rather than refused, and the revocation goes ahead with the default reason.

Example request

{
  "reason": "rotated"
}

Response

Personal access token revoked successfully

messagestring required

Example response

{
  "message": "Personal access token revoked successfully"
}

Changes

    • info

      added the media type application/x-www-form-urlencoded to the request body

    • info

      added the non-success response with the status

    • info

      added the optional property / to the response with the status

    • info

      added the optional property / to the response with the status

    • info

      added the optional property / to the response with the status

    • info

      added the optional property / to the response with the status

    • info

      added the non-success response with the status