GET organizations/…/accounts
Retrieves all accounts managed by an organization, including staff accounts.
Note that pagination works slightly differently when filtering in this way.
Resource URL
https://www.drillster.com/api/2.1.1/organizations/{organization_id}/accounts
Parameters
Field | Type | Description |
---|---|---|
organization_id required |
String | The unique ID of the organization. As a reference to the own organization, the value self may also be used.Example value: vFhqW_4Ea9ktLHqwHcrq-w |
relationType optional |
String | Optional filter on the type of relation the account should have to the organization. Use ADMIN to restrict the output to administrative (staff) accounts. |
resultFrom optional |
String | The starting value of the paginated result set returned. This concerns the creation date of the accounts, unless when querying admin accounts; then it's a simple index. The value should be taken from the lastOnPage in the 2.1.1 Pagination details. |
resultSize optional |
Integer | The maximum number of elements to return. If omitted, the value 10 is used. No page size larger than 100 items is permitted. |
query optional |
String | Optional search filter, for name or email address. |
Response
A 2.1.1 OrganizationAccounts object, containing the accounts plus pagination details.
Error responses
The following error situations are possible:
ID | Response code | Description |
---|---|---|
invalid_relation_type |
400 (Bad request) | The value for the relationType parameter is invalid. |
invalid_result_size |
400 (Bad request) | The value for the resultSize parameter is invalid. It should be positive and not larger than 100. |
invalid_result_from |
400 (Bad request) | The value for the resultFrom parameter is invalid. It should represent either a timestamp as epoch millis or the previous index. The value should be taken from the lastOnPage in the Pagination details. |
not_linked_to_organization |
401 (Unauthorized) | You are not an administrator of an organization. |
not_permitted |
403 (Forbidden) | You are not allowed to access this organization. |
not_found |
404 (Not found) | The specified organization does not exist. |
Last updated on