You need to provide exact matches in the body of the request for the attributes of the units you are looking for.You can provide either a list of group ids through the group_ids parameter or a list of group external references through the groups_external_refs attribute to filter the list of retrieved units down.Do not provide both, as this will result in the request failing.If no group_ids or group_external_refs are specified in the request body, the authenticated user will retrieve unit records for all groups they have access to.
The API returns a maximum of 100 records per call.You can use this parameter to load the next set of records by passing in the value returned in the response, under last_id.
The last id in the set of results returned for this API call.You can use this value in the after-id parameter to load the next set of results.If there are no more results to load, this value will be -1.
Listed below are common errors that may be returned by the endpoint, along with their corresponding status code.Status Code - 400
Missing Authorization header
Copy
Ask AI
{ "error": { "type": "missing_authorization", "message": "Your request does not include an 'Authorization' header with a bearer token for your account." }}
Status Code - 401
Expired Authorization header bearer token value
Copy
Ask AI
{ "error": { "type": "expired_token", "message": "The bearer token you have provided in the 'Authorization' header has expired. Please obtain a new one." }}
Status Code - 401
Invalid Authorization header bearer token value
Copy
Ask AI
{ "error": { "type": "invalid_authorization", "message": "The bearer token you have provided in the 'Authorization' header is invalid." }}
Status Code - 400Returned if both of the group_ids and groups_external_refs attributes are provided
Both group ids and external refs provided for the unit find operation
Copy
Ask AI
{ "error": { "type": "both_group_identifiers_provided", "message": "You have provided both group ids and group external references for the find units operation. Please only provide one of the two." }}
Status Code - 404Returned if no unit records can be found matching the provided information.
No unit records found for the provided parameters
Copy
Ask AI
{ "error": { "type": "not_found", "message": "There are no unit records matching the information provided." }}