Listing Users
Function
List users in a department. If department_id is not specified, the user list of the organization to which the current sign-in user belongs is queried.
URI
GET /koodrive/ose/v1/userList
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
deptId |
No |
String |
Department ID. |
isDirect |
No |
Boolean |
Whether the user belongs to the root department. Default value: false. |
offset |
Yes |
String |
Offset. Minimum value: 0. |
limit |
Yes |
String |
Maximum number of records to be returned. Value range: 1 to 100. |
keyWord |
No |
String |
Search keyword. You can use name as the search criterion. |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
Authorization |
Yes |
String |
Access token. Token authentication is used to call KooDrive APIs. A token indicates the permission. When an API is called, the token is added to the request header to obtain the operation permission. For details about how to obtain an access token, see the corresponding developer guide. The format is Bearer+{access_token}. |
X-Traceid |
No |
String |
Message log trace ID. The value contains 58 bits. |
language |
No |
String |
Language code, which complies with the internationalization specifications. For example, en-US indicates English (United States). English (United States) is used by default. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
code |
String |
Response code. |
msg |
String |
Response message. |
data |
Array of userInfo objects |
User information. |
Example Requests
Lists 10 users in department 1243693141656107521, starting from the first user.
GET /koodrive/ose/v1/userList?deptId=1243693141656107521&offset=0&limit=10 Authorization:Bearer+10f88**********4791e9ff
Example Responses
Status code: 200
User list information.
{ "list": [ { "id": "1316083732377071000VW5TYWZlSW50ZWdlcg==", "userId": "1008600000293202821", "deptId": "1243693141656107500VW5TYWZlSW50ZWdlcg==", "deptName": "newDept", "mobile": "0086181****8439", "name": "Sam", "role": 1, "status": 0, }, { "id": "1315783852559526700VW5TYWZlSW50ZWdlcg==", "userId": "1008600000292227464", "deptId": "1243693141656107500VW5TYWZlSW50ZWdlcg==", "deptName": "newDept", "mobile": "0086151****8338", "name": "test123", "role": 1, "status": 2 } ], "total": 2, "code": 0, "msg": "success" }
Status Codes
Status Code |
Description |
---|---|
200 |
User list information. |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot