Users

Grant or revoke per-user permissions

Inserts or updates per-user permission grants for a member of the authenticated caller's organization. Each item sets one permission (by permissions.id) to enabled or disabled; permissions not listed are left unchanged. The caller cannot update their own permissions or an account owner's. Effective permissions are the union of role grants and enabled per-user grants — disabling a permission here does not revoke it from a role. Returns every per-user grant stored for the member.

patch/v1/users/{user_id}/permissions

Request

  • Base URL
    https://identity-api.paymongo.com
  • URL
    https://identity-api.paymongo.com/v1/users/{user_id}/permissions
  • Auth
    HTTP bearer

Path parameters

user_idstring required

User id

Request body

Example request

{
  "data": {
    "attributes": {
      "permissions": [
        {
          "enabled": true,
          "permission_id": 12
        }
      ]
    }
  }
}

Response

OK

has_moreboolean

Example response

{
  "data": [
    {
      "attributes": {
        "action": "view",
        "created_at": 1733097600,
        "enabled": true,
        "module": "payments",
        "permission_id": 12,
        "updated_at": 1733097600,
        "user_id": "42"
      }
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.