Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The policy API provides functionality that allows a administrator to add, delete or update policies

Table of Contents

Section

List policies

Lists all the policies configured in the Aspire

Panel
borderColorblack
bgColor#fafafb
GET /aspire_api/policy

Query String Parameters

NameTypeRequiredDescription
typestringOptionalFilter returned seeds to only those with the given type
descriptionstringOptionalFilter returned seeds to only those whose description matches the given expression

Response

Code Block
languagejs
{
  "policy": [{
    "id": "AAABcID5GBc=",
    "type": "filesystemthrottle",
    ...
  },
  {
    "id": "AAABcIueWUc=",
    "type": "filesystemexecution",
    ...
  }],
  "message": "optional response message"
}

Status

Response codeDescription
200Success




Section

Get a single policy

Get information about a single policy configured in Aspire

Panel
borderColorblack
bgColor#fafafb

GET /aspire_api/policy?id=:id

GET /aspire_api/policy/:id

Query String and Path Parameters

NameTypeRequiredDescription
idstringRequiredThe id of the policy to return

Response

Code Block
languagejs
{
  "policy": {
    "id": "AAABcID5GBc=",
    "type": "filesystemthrottle",
    ...
 },

  "message": "optional response message"
}

Status

Response codeDescription
200Success
404The given seed id was not found




An Active Directory/LDAP domain

Examples

Add a single policy

Section

Add a policy

(s)

Add Adds one or more policies policy to Aspire

Panel
borderColorblack
bgColor#fafafb
POST /aspire_api/policy

Request Body Parameters

NameTypeRequiredDescription
typestringRequiredThe type of connector to use for this seed (may be omitted if connector is specified)policy to add
descriptionstringOptionalAn optional description of the seed

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

NameDescription
domain
usernameA username
passwordA password
emailA user email address
APIkeyAn API key
tokenan access token
Code Block
languagejs
{
  "type": "filesystemThrottle"
  "description": "Europe Net Appliance"
  ...
}

Add multiple policys

Code Block
languagejs
[{
  "type": "filesystem"
  "description": "Europe Net Appliance"
   throttle"
  ...
},
{
  "type": "sharepoint"
  "description": "SP Online"
  ...
}]

Response

Code Block
languagejs
{
  "policy": [{
    "id": "AAABcID5GBc=",
    "type": "filesystemthrottle"
    "description": "Europe Net Appliance"
    ...
   },
   {
    "id": "AAABcIueWUc=",
    "type": "sharepoint"
    "description": "SP Online"
    ...
  }],
  "message": "optional response message"
}

Status

Response codeDescription
201Created
406Not acceptable - there was an issue validating the input




Section

Update a policy

(s)

Update one or more a 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 null

Panel
borderColorblack
bgColor#fafafb
PUT /aspire_api/policy

Request Body Parameters

NameTypeRequiredDescription
idstringRequiredThe identifier of the seed policy to update
typestringRequiredThe type of connector to use for this seed (may be omitted if connector is specified)policy
descriptionstringOptionalAn optional description of the seed

Other parameters passed in the request body will depend on the type of policy being created - see Add policy(s) Policy API above

Examples

Update a single policy

Code Block
languagejs
{
  "id": "AAABcID5GBc=",
  "type": "filesystemthrottle"
  "description": "Europe Net Appliance"
  ...
}

Update multiple policies

js
Code Block
language
[{
  "id": "AAABcID5GBc=",
  "type": "filesystem"
  "description": "Europe Net Appliance"
  ...
},
{
  "id": "AAABcIueWUc=",
  "type": "sharepoint"
  "description": "SP Online"
  ...
}]

Response

Code Block
languagejs
{
  "policy": [{
    "id": "AAABcID5GBc=",
    "type": "filesystemthrottle"
    "description": "Europe Net Appliance"
    ...
   },
   {
    "id": "AAABcIueWUc=",
    "type": "sharepoint"
    "description": "SP Online"
    ...
  }],
  "message": "optional response message"
}

Status

Response codeDescription
201Created
404Not found - a given seed identifier was not found
406Not acceptable - there was an issue validating the input




Section

Delete policy(s)

Delete one or more policies from Aspire.

Panel
borderColorblack
bgColor#fafafb

DELETE /aspire_api/policy?id=:id

DELETE /aspire_api/policy/:id

DELETE /aspire_api/policy

Query String, Path and Request Body Parameters

NameTypeRequiredDescription
idstringRequiredThe identifier(s) of the policy(s) to delete

Examples

Delete a single policy

Code Block
languagejs
{
  "id": "AAABcID5GBc="
}

Delete multiple seeds

Code Block
languagejs
[{
  "id": "AAABcID5GBc="
},
{
  "id": "AAABcIueWUc="
}]

Delete multiple policies (alternative form)

Code Block
languagejs
{
  "id": ["AAABcID5GBc=", "AAABcIueWUc="]
}

Response

Code Block
languagejs
{
  "message": "optional response message"
}

Status

Response codeDescription
200Success
404Not found - a given seed identifier was not found
406Not acceptable - there was an issue validating the input