Skip to main content
GET
/
retention_policies
cURL
curl -i -X GET "https://api.box.com/2.0/retention_policies" \
     -H "authorization: Bearer <ACCESS_TOKEN>"
{
  "entries": [
    {
      "id": "12345",
      "type": "retention_policy",
      "policy_name": "Some Policy Name",
      "retention_length": "365",
      "disposition_action": "permanently_delete",
      "description": "Policy to retain all reports for at least one month",
      "policy_type": "finite",
      "retention_type": "non_modifiable",
      "status": "active",
      "created_by": {
        "id": "11446498",
        "type": "user",
        "name": "Aaron Levie",
        "login": "[email protected]"
      },
      "created_at": "2012-12-12T10:53:43-08:00",
      "modified_at": "2012-12-12T10:53:43-08:00",
      "can_owner_extend_retention": false,
      "are_owners_notified": false,
      "custom_notification_recipients": [
        {
          "id": "11446498",
          "type": "user",
          "name": "Aaron Levie",
          "login": "[email protected]"
        }
      ],
      "assignment_counts": {
        "enterprise": 1,
        "folder": 1,
        "metadata_template": 1
      }
    }
  ],
  "limit": 1000,
  "next_marker": "JV9IRGZmieiBasejOG9yDCRNgd2ymoZIbjsxbJMjIs3kioVii"
}
This endpoint is in the version 2024.0. No changes are required to continue using it. For more details, see Box API versioning.Learn more about Box SDK versioning strategy.

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Query Parameters

policy_name
string

Filters results by a case sensitive prefix of the name of retention policies.

policy_type
enum<string>

Filters results by the type of retention policy.

Available options:
finite,
indefinite
created_by_user_id
string

Filters results by the ID of the user who created policy.

fields
string[]

A comma-separated list of attributes to include in the response. This can be used to request fields that are not normally returned in a standard response.

Be aware that specifying this parameter will have the effect that none of the standard fields are returned in the response unless explicitly specified, instead only fields for the mini representation are returned, additional to the fields requested.

limit
integer<int64>

The maximum number of items to return per page.

Required range: x <= 1000
marker
string

Defines the position marker at which to begin returning results. This is used when paginating using marker-based pagination.

Response

Returns a list retention policies in the enterprise.

A list of retention policies.

entries
Retention policy · object[]

A list in which each entry represents a retention policy object.

limit
integer<int64>

The limit that was used for these entries. This will be the same as the limit query parameter unless that value exceeded the maximum value allowed. The maximum value varies by API.

Example:

1000

next_marker
string | null

The marker for the start of the next page of results.

Example:

"JV9IRGZmieiBasejOG9yDCRNgd2ymoZIbjsxbJMjIs3kioVii"