Search API request input
- Last UpdatedOct 21, 2026
- 4 minute read
Search API Request Input - Initial Load
The following table shows an example request body to be used for retrieving the full set of data (not a delta) from AIM. This could be used after an initial load:
|
Data Category |
Request body for Search API |
|
Tags |
{ "criteria": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND", "bracket": "Open", "includeInCriteria": true }, { "itemIdentifierType": "ClassId", "value": "FACILITY", "valueOperator": "Equals", "booleanOperator": "AND", "includeInCriteria": true },{ "associationTypeName": "has project", "associationClassId": "??????", "value": "", "booleanOperator": "AND", "bracket": "None", "item": { "properties": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND" }, { "itemIdentifierType": "ClassId", "value": "??????", "valueOperator": "Equals", "booleanOperator": "AND" } ] }, "valueOperator": "NotEquals" }], "paging": { "pageSize": "100", "currentPage": 1 }, "sorting": { "sortAscending": true, "sortBy": "Id" }, "projection": [{ "associationTypeName": "has dataset", "AssociationClassId":"OPERATIONAL DATASET", "item": { "properties": [ {"attributeId": "@??????_parent_tag_name", "Label":"Parent Tag Name"}, {"attributeId": "@aim_ATT_LastModified", "Label":"AIM Last Modified"} ] } },{ "associationTypeName": "is implemented by", "AssociationClassId":"ASSET", "item": { "properties": [ {"itemIdentifierType": "Id", "Label":"Related Equipment"} ] } }] } |
|
Documents |
{ "criteria": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND", "bracket": "Open", "includeInCriteria": true }, { "itemIdentifierType": "ClassId", "value": "DOCUMENT CONTENT", "valueOperator": "Equals", "booleanOperator": "AND", "includeInCriteria": true }], "paging": { "pageSize": "100", "currentPage": 1 }, "sorting": { "sortAscending": true, "sortBy": "Id" }, "projection": [{"attributeId": "@aim_ATT_LastModified", "Label":"AIM Last Modified"}] } |
|
Equipments |
{ "criteria": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND", "bracket": "Open", "includeInCriteria": true }, { "itemIdentifierType": "ClassId", "value": "ASSET", "valueOperator": "Equals", "booleanOperator": "AND", "includeInCriteria": true }], "paging": { "pageSize": "100", "currentPage": 1 }, "sorting": { "sortAscending": true, "sortBy": "Id" }, "projection": [{ "associationTypeName": "has dataset", "AssociationClassId":"OPERATIONAL DATASET", "item": { "properties": [ {"attributeId": "@aim_ATT_LastModified", "Label":"AIM Last Modified"} ] } }] } |
Notes:
-
It is sufficient to include in the "Tags" a projection criteria of "is implemented by" to retrieve the tag-equipment relationships.
-
DOCUMENT CONTENT is the parent of Document and Document Package classes. Therefore, the above call fetches both documents and document packages. However, if the call needs to be more specific, then modify the DOCUMENT CONTENT class accordingly. This change can be applied to section Search API Request Inputs - Delta Loads and section Search API Request Inputs – Tag-Document relationships.
Search API Request Input - Delta Loads
The following table shows an example request body to be used for retrieving a delta set of data. Update the highlighted date to retrieve the delta from a specific date:
|
Data Category |
Request body for Search API |
|
Tags |
{ "criteria": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND", "bracket": "None", "includeInCriteria": true }, { "itemIdentifierType": "ClassId", "value": "FACILITY", "valueOperator": "Equals", "booleanOperator": "AND", "includeInCriteria": true }, { "attributeId": "@aim_ATT_LastModified", "dataType": "Date", "value":"2022-07-22T00:00:00Z", "valueOperator": "GreaterThanOrEquals", "booleanOperator": "AND", "bracket": "None", "allValues": "true" } ], "paging": { "pageSize": "100", "currentPage": 1 }, "sorting": { "sortAscending": true, "sortBy": "Id" }, "projection": [{ "associationTypeName": "has dataset", "AssociationClassId":"OPERATIONAL DATASET", "item": { "properties": [ {"attributeId": "@??????_parent_tag_name", "Label":"Parent Tag Name"}, {"attributeId": "@??????_tag_status", "Label":"Tag Status"}, {"attributeId": "@aim_ATT_LastModified", "Label":"AIM Last Modified"} ] } },{ "associationTypeName": "is implemented by", "AssociationClassId":"ASSET", "item": { "properties": [ {"itemIdentifierType": "Id", "Label":"Related Equipment"} ] } }] } |
|
Documents |
{ "criteria": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND", "bracket": "Open", "includeInCriteria": true }, { "itemIdentifierType": "ClassId", "value": "DOCUMENT CONTENT", "valueOperator": "Equals", "booleanOperator": "AND", "includeInCriteria": true }, { "attributeId": "@aim_ATT_LastModified", "dataType": "Date", "value":"2022-11-04T00:00:00Z", "valueOperator": "GreaterThanOrEquals", "booleanOperator": "AND", "bracket": "None", "allValues": "true" } ], "paging": { "pageSize": "100", "currentPage": 1 }, "sorting": { "sortAscending": true, "sortBy": "Id" }, "projection": [ {"attributeId": "@aim_ATT_LastModified", "Label":"AIM Last Modified"} ] } |
|
Equipments |
{ "criteria": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND", "bracket": "Open", "includeInCriteria": true }, { "itemIdentifierType": "ClassId", "value": "ASSET", "valueOperator": "Equals", "booleanOperator": "AND", "includeInCriteria": true }, { "attributeId": "@aim_ATT_LastModified", "dataType": "Date", "value":"2022-07-22T00:00:00Z", "valueOperator": "GreaterThanOrEquals", "booleanOperator": "AND", "bracket": "None", "allValues": "true" } ], "paging": { "pageSize": "100", "currentPage": 1 }, "sorting": { "sortAscending": true, "sortBy": "Id" }, "projection": [{ "associationTypeName": "has dataset", "AssociationClassId":"OPERATIONAL DATASET", "item": { "properties": [ {"attributeId": "@aim_ATT_LastModified", "Label":"AIM Last Modified"} ] } }] } |
Search API Request Input – Tag-Document relationships
|
Data Category |
Request body for Search API |
|
Documents linked to a Tag |
{ "criteria": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND", "bracket": "Open", "includeInCriteria": true }, { "itemIdentifierType": "ClassId", "value": "DOCUMENT CONTENT", "valueOperator": "Equals", "booleanOperator": "AND", "includeInCriteria": true }, { "associationTypeName": "refers to", "associationClassId": "FACILITY", "value": "", "booleanOperator": "AND", "bracket": "None", "item": { "properties": [{ "itemIdentifierType": "Id", "value": "{TAG_FULL_ID}", "valueOperator": "Equals", "booleanOperator": "AND" } ] }, "valueOperator": "Equals" } ], "paging": { "pageSize": "1000", "currentPage": 1 }, "sorting": { "sortAscending": true, "sortBy": "Id" }, "projection": [] } |
|
Tags linked to a Document |
{ "criteria": [{ "itemIdentifierType": "Id", "value": "%", "valueOperator": "Like", "booleanOperator": "AND", "bracket": "Open", "includeInCriteria": true }, { "itemIdentifierType": "ClassId", "value": "FACILITY", "valueOperator": "Equals", "booleanOperator": "AND", "includeInCriteria": true }, { "associationTypeName": "is referenced in", "associationClassId": "DOCUMENT CONTENT", "value": "", "booleanOperator": "AND", "bracket": "None", "item": { "properties": [{ "itemIdentifierType": "Id", "value": "{DOCUMENT_FULL_ID}", "valueOperator": "Equals", "booleanOperator": "AND" } ] }, "valueOperator": "Equals" } ], "paging": { "pageSize": "1000", "currentPage": 1 }, "sorting": { "sortAscending": true, "sortBy": "Id" }, "projection": [] } |
Notes:
-
It is sufficient to use Tags linked to a Document to retrieve the tag-document relationships as whenever a new link is added the "AIM Last Modified" attribute is updated for a document.
-
Replace "FACILITY" with "ASSET" in the request to retrieve the document to equipment relationships.
-
Replace "DOCUMENT CONTENT" with an appropriate class to retrieve the document to tag/equipment relationships.
-
Replace "DOCUMENT CONTENT" with an appropriate class to retrieve the document package to tag/equipment relationships.