v1

latestOpenAPI 3.0.2Apache-2.02026-07-142963051.0 MB
Retention policy assignments

Assign retention policy

Assigns a retention policy to an item.

post/retention_policy_assignments

Request body

policy_idstring required

The ID of the retention policy to assign.

start_date_fieldstring

The date the retention policy assignment begins.

If the assigned_to type is metadata_template, this field can be a date field's metadata attribute key id.

Example request

{
  "policy_id": "173463",
  "assign_to": {
    "type": "metadata_template",
    "id": "6564564"
  },
  "filter_fields": [
    {
      "field": "a0f4ee4e-1dc1-4h90-a8a9-aef55fc681d4",
      "value": "0c27b756-0p87-4fe0-a43a-59fb661ccc4e"
    }
  ],
  "start_date_field": "upload_date"
}

Response

Returns a new retention policy assignment object.

idstring required

The unique identifier for a retention policy assignment.

type'retention_policy_assignment' required

The value will always be retention_policy_assignment.

assigned_atstring date-time

When the retention policy assignment object was created.

start_date_fieldstring

The date the retention policy assignment begins. If the assigned_to type is metadata_template, this field can be a date field's metadata attribute key id.

Example response

{
  "id": "11446498",
  "type": "retention_policy_assignment",
  "retention_policy": {
    "id": "12345",
    "type": "retention_policy",
    "policy_name": "Some Policy Name",
    "retention_length": "365",
    "disposition_action": "permanently_delete"
  },
  "assigned_to": {
    "id": "a983f69f-e85f-4ph4-9f46-4afdf9c1af65",
    "type": "metadata_template"
  },
  "filter_fields": [
    {
      "field": "a0f4ee4e-1dc1-4h90-a8a9-aef55fc681d4",
      "value": "0c27b756-0p87-4fe0-a43a-59fb661ccc4e"
    }
  ],
  "assigned_by": {
    "id": "11446498",
    "type": "user",
    "name": "Aaron Levie",
    "login": "ceo@example.com"
  },
  "assigned_at": "2012-12-12T10:53:43-08:00",
  "start_date_field": "upload_date"
}