Retrieves all of the retention policies for an enterprise.
21312321
Filters results by the ID of the user who created policy.
Sales Policy
Filters results by a case sensitive prefix of the name of retention policies.
finite
Filters results by the type of retention policy.
Value is one of finite
,indefinite
Returns a list retention policies in the enterprise.
Returns a bad_request
if a non existent policy_type
was specified.
Returns a not_found
error if the user specified in created_by_user_id
does not exist.
An unexpected client error.
curl -X GET https://api.box.com/2.0/retention_policies \
-H 'Authorization: Bearer <ACCESS_TOKEN>'
BoxCollectionMarkerBased<BoxRetentionPolicy> policies = await client.RetentionPoliciesManager
.GetRetentionPoliciesAsync();
Iterable<BoxRetentionPolicy.Info> policies = BoxRetentionPolicy.getAll(api);
for (BoxRetentionPolicy.Info policyInfo : policies) {
// Do something with the retention policy.
}
retention_policies = client.get_retention_policies()
for policy in retention_policies:
print('The policy ID is {0} and the name is {1}'.format(policy.id, policy.policy_name))
client.retentionPolicies.getAll({ policy_name: 'Tax' })
.then(policies => {
/* policies -> {
entries:
[ { type: 'retention_policy',
id: '123456789',
name: 'Tax Documents' } ],
limit: 100,
next_marker: 'someMarkerString' }
*/
});