API7 Docs

List the Roles or Users that directly reference the Permission Policy

GET /api/permission_policies/{permission_policy_id}/references

GET /api/permission_policies/{permission_policy_id}/references

Interactive request editor loads with JavaScript.

Authorization

X-API-KEY<token>

In: header

Path Parameters

permission_policy_id*string

Permission policy ID.

Length1 <= length

Response Body

application/json

curl -X GET "$API_BASE_URL/api/permission_policies/string/references"

Successfully retrieved the list of resources referencing the permission policy.

{
  "total": 1,
  "list": [
    {
      "type": "role",
      "id": "bd58fce2-b6cc-4d2d-a53c-6ce11b19c101",
      "name": "consumer role"
    }
  ]
}
Complete operation details and schema variants

GET /api/permission_policies/{permission_policy_id}/references

List the Roles or Users that directly reference the Permission Policy

List roles and users that directly reference the specified permission policy. This helps estimate impact before policy changes. Required IAM Permission: Action iam:GetPermissionPolicy, Resource arn:api7:iam:permissionpolicy/%s

Parameters

  • permission_policy_id (path, string, required): Permission policy ID.

Responses

  • 200: Successfully retrieved the list of resources referencing the permission policy.
  • allOf variant 1
  • list (array, optional): An array of resources.
  • total (integer, optional): Total number of objects.
  • allOf variant 2
  • list (array, optional):
  • list[].type (string, optional): Referenced by Role or User.
  • list[].id (string, optional): The object ID.
  • list[].name (string, optional): The object name.
  • 400: Invalid arguments. Error details will be provided in the response.

cURL

curl -X GET '$API_BASE_URL/api/permission_policies/{permission_policy_id}/references'