Get User Base Info¶
Get basic information about a user, such as the user ID, based on the user’s email, account and domain, or phone number and phone area code.
Operation Permissions¶
In Application Portal, the application must be granted the “Obtain the ID, username, email, and phone number of all users in the OU” permission.
Request Format¶
POST https://{apigw-address}/app-portal-service/v2.2/user/getUserBaseInfo
Request Parameters (Body)¶
Name |
Mandatory/Optional |
Data Type |
Description |
---|---|---|---|
organizationId |
Mandatory |
String |
The OU ID. How to get organizationId>> |
Optional |
String |
The user’s email address |
|
name |
Optional |
String |
|
domain |
Optional |
String |
|
phoneArea |
Optional |
String |
|
phone |
Optional |
String |
|
Response Parameters¶
Name |
Data Type |
Description |
---|---|---|
data |
SimpleUserListDTO Struct |
The list of basic information about the user |
SimpleUserListDTO Struct¶
Name |
Data Type |
Description |
---|---|---|
users |
List<SimpleUserDTO> |
The list of basic information about the user |
SimpleUserDTO Struct¶
Name |
Data Type |
Description |
---|---|---|
id |
String |
The user ID |
name |
String |
The user name |
domain |
String |
The domain that the user belongs to |
String |
The user’s email address |
|
department |
String |
The user’s department |
company |
String |
The user’s company |
position |
String |
The user’s position |
updatedTime |
String |
The update time of the user information. |
Error Codes¶
Code |
Description |
---|---|
31400 |
Errors such as incorrect parameters, empty parameters, and so on |
31403 |
The application has not been granted the “Obtain the ID, username, email, and phone number of all users in the OU” permission |
31404 |
Errors such as organization not found, user not found, and so on |
Samples¶
Request Sample¶
url: https://{apigw-address}/app-portal-service/v2.2/user/getUserBaseInfo
method: POST
requestBody:
{"organizationId":"yourOrgId", "email":"yourEmail"}
Return Sample¶
{
"code": 0,
"message": "OK",
"data": {
"users": [
{
"id": "your_user_id",
"name": "your_user_name",
"domain": "",
"email": "your_user_email",
"company": "your_user_company",
"position": "your_user_position",
"department": "your_user_department"
}
]
}
}