获取单个用户信息
GET
/open-apis/contact/v3/users/{user_id}
自建应用商店应用
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://open.feishu.cn/open-apis/contact/v3/users/ou_82efa78a676d537b66dbe0e1e2f106a5?user_id_type=open_id&department_id_type=open_department_id' \
--header 'Authorization;'
响应示例响应示例
{
"code": 0,
"msg": "success",
"data": {
"user": {
"union_id": "on_94a1ee5551019f18cd73d9f111898cf2",
"user_id": "3e3cf96b",
"open_id": "ou_7dab8a3d3cdcc9da365777c7ad535d62",
"name": "张三",
"en_name": "San Zhang",
"nickname": "Alex Zhang",
"email": "zhangsan@gmail.com",
"mobile": "13011111111",
"mobile_visible": false,
"gender": 1,
"avatar": {
"avatar_72": "https://foo.icon.com/xxxx",
"avatar_240": "https://foo.icon.com/xxxx",
"avatar_640": "https://foo.icon.com/xxxx",
"avatar_origin": "https://foo.icon.com/xxxx"
},
"status": {
"is_frozen": false,
"is_resigned": false,
"is_activated": true,
"is_exited": false,
"is_unjoin": false
},
"department_ids": [
"od-4e6ac4d14bcd5071a37a39de902c7141"
],
"leader_user_id": "ou_7dab8a3d3cdcc9da365777c7ad535d62",
"city": "杭州",
"country": "CN",
"work_station": "北楼-H34",
"join_time": 2147483647,
"is_tenant_manager": false,
"employee_no": "1",
"employee_type": 1,
"orders": [
{
"department_id": "od-4e6ac4d14bcd5071a37a39de902c7141",
"user_order": 100,
"department_order": 100
}
],
"custom_attrs": [
{
"type": "TEXT",
"id": "DemoId",
"value": {
"text": "DemoText",
"url": "http://www.feishu.cn",
"pc_url": "http://www.feishu.cn",
"option_value": "option",
"name": "name",
"picture_url": "https://xxxxxxxxxxxxxxxxxx",
"generic_user": {
"id": "9b2fabg5",
"type": 1
}
}
}
],
"enterprise_email": "demo@mail.com",
"job_title": "xxxxx"
}
}
}
请求参数
Path 参数
user_id
必需
示例值:
ou_82efa78a676d537b66dbe0e1e2f106a5
Query 参数
user_id_type
必需
union_id:用户的 union id
user_id:用户的 user id
默认值:open_id
示例值:
open_id
department_id_type
必需
open_department_id:以open_department_id来标识部门
默认值:open_department_id
示例值:
open_department_id
Header 参数
Authorization
string
必需
默认值:
Bearer {{access_token}}
返回响应
修改于 2022-02-11 08:43:31