...
Department Administrators, and users with a custom role can get lists of users belonging to the departments they manage and their sub-departments.
| Panel | ||
|---|---|---|
| ||
If you have more than 1000 users in your account, use the Getting a List of Users (Page-by-Page) request. |
Request Headers
| Header | Description |
| Authorization (required) | Access token. You can obtain a token by making a request |
| Parameter | Description |
|---|---|
| departments (optional) | The array of departments IDs you want to get user lists of |
| groups (optional) | The array of groups IDs you want to get user lists of |
| workLeaveStatus (optional) | A work leave status. An array with the following parameters:
|
Possible Response Codes
| Code | Text | Description |
|---|---|---|
| 200 | OK | The request has been processed successfully |
| 400 | Bad Request | A request error |
| 401 | Unauthorized | An authorization error |
| 403 | Permission denied | The user doesn't have enough permissions to complete the request |
Sample Request
| Code Block | ||
|---|---|---|
| ||
GET /user?departments[]=e95b4ad0-5f50-11e9-80c4-0a580af406eb&groups[]=e0b394fc-44b9-11e9-92c8-0a580af401f6 https/1.1 Host: api-learn.ispringlearn.com Authorization: p-1sJDjmULL5DdpXPJTcbm4jVIaWVHvNmrjAxATRbNE |
...