You can get a list of departments by sending the GET request to the following URL: /department.
Permission to run the request: Account Owner, Administrators, Department Administrators, Publishers.
Department Administrators and Publishers can get information only on the department they manage and its daughter departments.
|X-Auth-Account-Url (required)||Base URL of the account, e.g. http://myaccount.ispringlearn.com|
|X-Auth-Email (required)||Login of Account Owner, Administrator, Department Administrator, or Publisher.|
|X-Auth-Password (required)||Password of Account Owner, Administrator, Department Administrator, or Publisher.|
After the request has been completed, the system returns the response with the 200 code. The response code contains xml info on the departments.
Possible Response Codes
The request was successfully processed.
|400||Bad Request||A request error.|
|401||Unauthorized||An authorization error.|
The user doesn't have enough permissions to get the list of departments.