The policy policies API provides functionality that allows a administrator to add, delete or update policies
Easy Heading Free | ||||
---|---|---|---|---|
| ||||
Section | |||||||
---|---|---|---|---|---|---|---|
List Get all policiesLists all the policies configured in the Aspire, this endpoint need the at least the OPERATOR role to be executed.
Query String Parameters | |||||||
Name | Type | Required | Description | ||||
type | string | Optional | Filter returned seeds to only those with the given type |
policies |
Pagination query string parameters
Sorting query string parameters
Section | |||||||
---|---|---|---|---|---|---|---|
Get all policies, filteredLists policies configured in the Aspire, filtered by a specified criteria, this endpoint need the at least the OPERATOR role to be executed.
Pagination query string parameters |
Response
Code Block | ||||
---|---|---|---|---|
| ||||
{ "count": { "totalItems": 3 }, "policy": [ { "id": "AAABcID5GBc=10653921-1b27-40b5-9d7a-f54ef1e3ad01", "type": "filesystem", ... }, "throttle", "description": "throttleDesc", "period": "minute", "value": 5 }, { "id": "AAABcIueWUc=14822610-a387-44cf-a5ed-3e05618efb57", "type": "filesystemthrottle", "description": "throttleDesc", "period": "day", ... }], "message": "optional response message" } |
Status
"value": 333
},
{
"id": "e10af522-5830-4105-9886-3385499202ba",
"type": "route",
"description": "routim to cz",
"routeTo": "CZZZ"
}
]
} |
Status: 200
Section | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Get single policyGets | ||||||||||||||||||||||
Section | ||||||||||||||||||||||
Get a single policyGet information about a single policy configured in Aspire, this endpoint need the at least the OPERATOR role to be executed.
Query String and Path Parameters
Response
| ||||||||||||||||||||||
Response code | Description | |||||||||||||||||||||
200 | Success | |||||||||||||||||||||
404 | The given seed id was not found |
Section | |||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Add policy(sies)Add one or more Adds policies to Aspire, this endpoint need the at least the ADMINISTRATOR role to be executed.
Request Body Parameters
Other parameters passed in the request body will depend on the type of policy being created - those required by Documentum will be different from those required by SharePoint. Some candidates are shown below | |||||||||||||||||||
Name | Description | ||||||||||||||||||
domain | An Active Directory/LDAP domain | ||||||||||||||||||
username | A username | ||||||||||||||||||
password | A password | ||||||||||||||||||
A user email address | |||||||||||||||||||
APIkey | An API key | ||||||||||||||||||
token | an access token |
Name | Type | Required | Description |
---|---|---|---|
period | string | Required | Time unit of the throttling policy - second, minute, hour, day |
value | int | Required | Number of documents per time unit for the throttling policy |
Route type:
Name | Type | Required | Description |
---|---|---|---|
routeTo | string | Required | A route to tag |
DeleteIncremental type:
Name | Type | Requried | Description |
---|---|---|---|
deletesPolicy | DeletesPolicy | Required |
|
deleteCheckAfterErrors | enum DeleteCheckAfterErrors | Required for a variant IMMEDIATE | Checks if "delete" candidates still exist after an incremental when they are part of scan error.
|
value | int | Required for a variant AFTER_DAYS, AFTER_INCREMENTALS | Number of days or iterations. Valid value is also -1, that means that sends the deletes immediately since the last time the URLs were accessed. |
Example
Examples
Add a single policy
Code Block | ||||
---|---|---|---|---|
| ||||
POST /aspire_api/policies [{ "type": "filesystemthrottle", "description": "Europe Net Appliance throttle", "period": "minute" ... } |
Add multiple policys
Code Block | ||
---|---|---|
| ||
[, "value": "100" }, { "type": "route", "description": "German servers", "routeTo": "US" }, { "type": "deleteIncremental", "description": "Days before delete", "deletesPolicy": "AFTER_DAYS", "value": "1" }, { "type": "filesystemdeleteIncremental", "description": "Iterations before delete"Europe Net Appliance" ..., "deletesPolicy": "AFTER_INCREMENTALS", "value": "2" }, { "type": "sharepointdeleteIncremental", "description": "SP Online" ... }default immediate policy", "deletesPolicy": "IMMEDIATE", "deleteCheckAfterErrors": "ALWAYS" }, ] |
Response
Code Block | ||||
---|---|---|---|---|
| ||||
{ "policy": [{ "id": "AAABcID5GBc=", "type": "filesystemthrottle" "description": "Europe Net Appliance throttle", "period": "minute", ..."value": "100" }, { "id": "AAABcID5GBd=", "type": "AAABcIueWUc=route" "description": "All servers", "routeTo": "US" }, { "id": "AAABcID5GBe=", "type": "deleteIncremental", "description": "Days before delete", "deletesPolicy": "AFTER_DAYS", "value": "1" }, { "id": "AAABcID5GBf=", "type": "sharepointdeleteIncremental", "description": "SP Online"Iterations before delete", "deletesPolicy": "AFTER_INCREMENTALS", ..."value": "2" }] }, { "id": "AAABcID5GBg=", "description": "default immediate policy", "messagedeletesPolicy": "IMMEDIATE"optional response message" } |
Status
,
"deleteCheckAfterErrors": "ALWAYS"
}
]
} |
See Response Body for details regarding the response body returned where multiple items are affected with some (or all) returning errors
Status: 201, 406
Section | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Update policy(sies)Update one or more policys in Aspire. Updates will be treated as partial updates rather than overwrites. If a field is not present in the input, any previous value will remain after the update. If you wish to "delete" a value, pass a value of nullpolicies in Aspire, this endpoint need the at least the ADMINISTRATOR role to be executed.
Request Body Parameters
Other parameters passed in the request body will depend on the type of policy being created - see Add policy(s) above Examples
x - at least one field must be present ExampleUpdate a single policy
Update multiple policies
Response
Response
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Response code | Description | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
201 | Created | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
404 | Not found - a given seed identifier was not found | 406 | Not acceptable - there was an issue validating the input
: 200, 406 |
Section | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Delete policy(sies)Delete one or more policies from Aspire, this endpoint need the at least the ADMINISTRATOR role to be executed.
Query String, Path Parameters and Request Body ParametersQuery parameters
Examples Delete a single policy Body Parameter
Examples
Delete multiple seedsResponse
Status: 200, 404, 406
|
Section | |||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Export policy(ies)Export one or more policy from Aspire, this endpoint needs at least the OPERATOR role to be executed.
Path Parameters and Query parameters
Body Parameter
ExamplesDelete multiple policies (alternative form)
Response
Status | |||||||||||||||||||||||||||||||||||||||||||
Response code | Description | ||||||||||||||||||||||||||||||||||||||||||
200 | Success | ||||||||||||||||||||||||||||||||||||||||||
404 | Not found - a given seed identifier was not found | 406 | Not acceptable - there was an issue validating the input
"policy": [
{
"id": "<policy_id>",
"type": "deleteIncremental",
"description": "pD",
"deletesPolicy": "IMMEDIATE",
"deleteCheckAfterErrors": "ALWAYS"
},
...
]
}
}
} |
Status: 200, 404, 406
Section | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Export multiple policies, filteredExport multiple policies from Aspire, filtered by a specified criteria, this endpoint needs at least the OPERATOR role to be executed.
Filters: The connection filter definition here Response
Status: 200 |
Section |
---|
ImportThe import usage can be found here |
Section | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Filters
Connector filter:
|