Skip to main content
GET
/
policy
/
rulesets
List of Rulesets
curl --request GET \
  --url https://wks-a1b2c3d4.provisionr.io/api/v1/policy/rulesets \
  --header 'Authorization: Bearer <token>'
{
  "current_page": 2,
  "data": [
    {
      "id": "<string>",
      "state": "unmanaged",
      "resource_type": "directory_attribute",
      "resource_id": "<string>",
      "resource_parent": "<string>",
      "resource_name": "<string>",
      "resource_handle": "<string>",
      "is_authoritative": true,
      "expires_after_days": 123,
      "count": {
        "policy_ruleset_admins": 123,
        "policy_conditions": 123,
        "policy_rules": 123,
        "manifest_users": 123,
        "qualified_users": 123,
        "staged_users": 123,
        "workspace_logs_parent": 123,
        "workspace_logs_record": 123,
        "workspace_logs_related": 123
      },
      "included": {
        "policy_resource": "<unknown>",
        "policy_ruleset_admins": [
          {
            "id": "<string>",
            "state": "staged",
            "role": "admin",
            "timestamp": {
              "created_at": "2023-11-07T05:31:56Z",
              "updated_at": "2023-11-07T05:31:56Z",
              "activated_at": "2023-11-07T05:31:56Z",
              "expires_at": "2023-11-07T05:31:56Z",
              "deleted_at": "2023-11-07T05:31:56Z"
            },
            "included": {
              "directory_user": {
                "id": "<string>",
                "state": "staged",
                "manager_id": "<string>",
                "is_manager": true,
                "full_name": "<string>",
                "email": "<string>",
                "username": "<string>",
                "org": {},
                "metadata": {}
              },
              "policy_ruleset": {
                "id": "<string>",
                "state": "unmanaged",
                "type": "directory_attribute",
                "resource_id": "<string>",
                "is_authoritative": true,
                "expires_after_days": 123
              }
            },
            "links": {
              "self": "<string>",
              "directory_user": "<string>",
              "policy_ruleset": "<string>"
            }
          }
        ],
        "policy_rules": [
          {
            "id": "<string>",
            "state": "staged",
            "role_name": "<string>",
            "role_handle": "<string>",
            "is_imported": true,
            "description": "<string>",
            "expires_after_days": 123,
            "expires_after_days_inherited": true,
            "priority": 123
          }
        ],
        "policy_conditions": [
          {
            "id": "<string>",
            "is_imported": true,
            "type": "attribute",
            "ruleset_id": "<string>",
            "rule_id": "<string>",
            "resource_id": "<string>",
            "profile_key": "<string>",
            "profile_operator": "equals",
            "profile_value": "<string>",
            "description": "<string>"
          }
        ]
      },
      "links": {
        "self": "<string>",
        "policy_resource": "<string>",
        "policy_ruleset_admins": "<string>",
        "policy_rules": "<string>",
        "policy_conditions": "<string>",
        "manifest_users": "<string>",
        "qualified_users": "<string>",
        "staged_users": "<string>",
        "workspace_logs_parent": "<string>",
        "workspace_logs_record": "<string>",
        "workspace_logs_related": "<string>"
      }
    }
  ],
  "first_page_url": "<string>",
  "from": 2,
  "last_page_url": "<string>",
  "last_page": 2,
  "links": [
    {
      "url": "<string>",
      "label": "<string>",
      "active": true
    }
  ],
  "next_page_url": "<string>",
  "path": "<string>",
  "per_page": 1,
  "prev_page_url": "<string>",
  "to": 2,
  "total": 1
}

Documentation Index

Fetch the complete documentation index at: https://docs.provisionr.io/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

sort
string
default:resource_id

Available sorts are type, resource_id, is_authoritative, sync_enabled, state, -resource_type, -resource_id, -is_authoritative, -sync_enabled, -state. You can sort by multiple options by separating them with a comma. To sort in descending order, use - sign in front of the sort, for example: -type.

include
string

Available includes are rules, rules-count, rules-exists, conditions, conditions-count, conditions-exists, manifestUsers, manifestUsers-count, manifestUsers-exists, qualifiedUsers, qualifiedUsers-count, qualifiedUsers-exists, stagedUsers, stagedUsers-count, stagedUsers-exists, users, users-count, users-exists. You can include multiple options by separating them with a comma.

page[size]
integer
default:500

The number of results that will be returned per page.

page[number]
integer

The page number to start the pagination from.

filter[created_before]
string
filter[created_after]
string
filter[updated_before]
string
filter[updated_after]
string
filter[deactivated_before]
string
filter[deactivated_after]
string
filter[deleted_before]
string
filter[deleted_after]
string
filter[trashed]
string

Can be a value of with (response will contain deleted items as well), only (will contain only deleted items), or any arbitrary value (will contain only not deleted items).

filter
string
page
string
filter[id]
string

Filter by an exact match of the ruleset ID

filter[type]
string

Filter by the type of ruleset

filter[resource_id]
string

Filter by an exact match of the resource ID

filter[is_authoritative]
string

Filter by whether the ruleset is authoritative

filter[sync_enabled]
string

Filter by whether sync is enabled

filter[state]
string

Filter by an exact match of the state field

Response

Paginated set of PolicyRulesetDetailedResponseData

current_page
integer
required
Required range: x >= 1
data
PolicyRulesetDetailedResponseData · object[]
required
first_page_url
string | null
required
from
integer | null
required
Required range: x >= 1
last_page_url
string | null
required
last_page
integer
required
Required range: x >= 1

Generated paginator links.

next_page_url
string | null
required
path
string | null
required

Base path for paginator generated URLs.

per_page
integer
required

Number of items shown per page.

Required range: x >= 0
prev_page_url
string | null
required
to
integer | null
required

Number of the last item in the slice.

Required range: x >= 1
total
integer
required

Total number of items being paginated.

Required range: x >= 0