The credentials API provides functionality that allows a administrator to add, delete or update credentials
Lists all the credentials configured in the Aspire
GET /aspire/_api/credentials
Query String Parameters
Name | Type | Required | Description |
---|---|---|---|
from | integer | Optional | Indicates the initial page to be retrieved |
size | integer | Optional | Specifies the size of results page |
sortBy | string | Optional | Field by which results are sorted |
sortMode | string | Optional | Sort mode
|
Response
{ "credential": [{ "id": "AAABcID5GBc=", "type": "filesystem", "description": "Sales HD1 credentials", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } }, { "id": "AAABcIueWUc=", "type": "filesystem", "description": "Sales HD2 credentials", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } }] }
Status
Response code | Description |
---|---|
200 | Success |
Lists credentials configured in the Aspire, filtered by a specified criteria
POST /aspire/_api/credentials/getAll
Query String Parameters
Name | Type | Required | Description |
---|---|---|---|
from | integer | Optional | Indicates the initial page to be retrieved |
size | integer | Optional | Specifies the size of results page |
sortBy | string | Optional | Field by which results are sorted |
sortMode | string | Optional | Sort mode
|
Body Parameters
Name | Type | Required | Description |
---|---|---|---|
filter | JSON | Required | Filters retrieved credentials. Check the filter definition here |
Response
{ "credential": [{ "id": "AAABcID5GBc=", "type": "filesystem", "description": "Sales HD1 credentials", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } }, { "id": "AAABcIueWUc=", "type": "filesystem", "description": "Sales HD2 credentials", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } }] }
Status
Response code | Description |
---|---|
200 | Success |
Get information about a single credential configured in Aspire
GET /aspire/_api/credentials/:id
Query String Parameters
Name | Type | Required | Description |
---|---|---|---|
id | string | Required | The id of the credential to return |
Response
{ "credential": { "id": "AAABcID5GBc=", "type": "filesystem", "description": "Filesystem credentials", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } } }
Status
Response code | Description |
---|---|
200 | Success |
404 | The given credentials id was not found |
Adds credentials to Aspire
POST /aspire/_api/credentials
Body Parameters
Name | Type | Required | Description |
---|---|---|---|
type | string | Required | The type of credential to add |
description | string | Required | An optional description of the credential |
Example
POST /aspire/_api/credentials [{ "type": "filesystem" "description": "Europe Net Appliance" "username": "admin" }, { "type": "sharepoint" "description": "SP Online" "username": "admin" }]
Response
{ "credential": [{ "id": "AAABcID5GBc=", "type": "filesystem" "description": "Europe Net Appliance", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } }, { "id": "AAABcIueWUc=", "type": "sharepoint" "description": "SP Online", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } }] }
See Response Body for details regrading the response body returned where multiple items are affected with some (or all) returning errors
Status
Response code | Description |
---|---|
201 | Created |
406 | Not acceptable - there was an issue validating the input |
Update credentials in Aspire.
PUT /aspire/_api/credentials
Body Parameters
Name | Type | Required | Description |
---|---|---|---|
id | string | Required | The identifier of the credential to update |
type | string | Optional | The type of credential |
description | string | Optional | An optional description of the credential |
Other parameters passed in the request body will depend on the type of credential being created - see Add credential(s) above
Example
PUT /aspire/_api/credentials { "AAABcID5GBc=": { "id": "AAABcID5GBc=", "type": "filesystem" "description": "Europe Net Appliance" }, "AAABcIueWUc=": { "id": "AAABcIueWUc=", "type": "sharepoint" "description": "SP Online" } }
Response
{ "credential": [{ "id": "AAABcID5GBc=", "type": "filesystem" "description": "Europe Net Appliance", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } }, { "id": "AAABcIueWUc=", "type": "sharepoint" "description": "SP Online", "created": 1596707252548, "updated": 1596707252548, "properties": { This will be a dynamic JSON object } }] }
See Response Body for details regrading the response body returned where multiple items are affected with some (or all) returning errors
Status
Response code | Description |
---|---|
200 | Success |
404 | Not found - a given credential identifier was not found |
406 | Not acceptable - there was an issue validating the input |
Delete multiple credentials from Aspire, filtered by a specified criteria
POST /aspire/_api/credentials/deleteAll
Body Parameters
Name | Type | Required | Description |
---|---|---|---|
filter | JSON | Required | Filters retrieved credentials. Check the filter definition here |
Response
{ "message": "optional response message" }
See Response Body for details regrading the response body returned where multiple items are affected with some (or all) returning errors
Status
Response code | Description |
---|---|
200 | Success |
404 | Not found - a given credential identifier was not found |
406 | Not acceptable - there was an issue validating the input |
Delete a credentials from Aspire.
DELETE /aspire/_api/credentials/:id
Query String Parameters
Name | Type | Required | Description |
---|---|---|---|
id | string | Required | The identifier(s) of the credential(s) to delete |
Example
DELETE /aspire/_api/credentials/AAABcID5GBc=
Response
{ "message": "optional response message" }
See Response Body for details regrading the response body returned where multiple items are affected with some (or all) returning errors
Status
Response code | Description |
---|---|
200 | Success |
404 | Not found - a given credential identifier was not found |
406 | Not acceptable - there was an issue validating the input |
Returns the dxf for a specific credential type
GET /aspire/_api/credentials/type/:typeId/dxf
Query String Parameters
Name | Type | Required | Description |
---|---|---|---|
typeId | string | Required | The id of the type for which dxf is going to be retrieved |
Response
{ "dxf": {...} "message": "optional response message" }
Status
Response code | Description |
---|---|
200 | Success |
404 | Not found - a given service identifier was not found |
Some endpoint queries require a filter. A filter is basically a JSON object with the following format:
Credentials filter:
"filter" : { "ids" : ["id1", "id2", "id3"], "type" : "TYPE", "description" : "DESCRIPTION" }