获取用户维度的用户活跃和功能使用数据
GET
/open-apis/admin/v1/admin_user_stats
自建应用
只有企业自建应用才有权限调用此接口
错误码
HTTP状态码 | 错误码 | 描述 | 排查建议 |
---|---|---|---|
500 | 1051001 | request contain invalid param | 请求中包含非法参数 |
400 | 1051002 | request to exceed authority | 请求发生越权 |
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://open.feishu.cn/open-apis/admin/v1/admin_user_stats?user_id_type=open_id&department_id_type=department_id&start_date=2020-02-15&end_date=2020-02-15&department_id=od-382e2793cfc9471f892e8a672987654c&user_id=ou_7dab8a3d3cdcc9da365777c7ad535d62&page_size=10&page_token=2' \
--header 'Authorization;'
响应示例响应示例
{
"code": 0,
"msg": "success",
"data": {
"has_more": true,
"page_token": "3",
"items": [
{
"date": "2020-02-15",
"user_id": "ou_7dab8a3d3cdcc9da365777c7ad535d62",
"user_name": "Zhang San",
"department_name": "testcqlbfaaasdasdasd",
"department_path": "testkkk/testcqlbfaaasdasdasd",
"create_time": "2020-09-04 11:17:55",
"user_active_flag": 1,
"register_time": "2020-09-04 11:18:32",
"suite_active_flag": 1,
"last_active_time": "2020-12-21 22:21:28",
"im_active_flag": 1,
"send_messenger_num": 0,
"docs_active_flag": 1,
"create_docs_num": 1,
"cal_active_flag": 1,
"create_cal_num": 0,
"vc_active_flag": 1,
"vc_duration": 0,
"active_os": "'ios 14.2,-','ios 14.2,feishu 3.40.0-alpha'",
"create_task_num": 0,
"vc_num": 0,
"app_package_type": "Feishu,Lark",
"os_name": "iOS,Andorid,Windows"
}
]
}
}
请求参数
Query 参数
user_id_type
必需
union_id:用户的 union id
user_id:用户的 user id
默认值:open_id
示例值:
open_id
department_id_type
必需
open_department_id:部门的 Open ID
示例值:
department_id
start_date
必需
示例值:
2020-02-15
end_date
必需
示例值:
2020-02-15
department_id
必需
示例值:
od-382e2793cfc9471f892e8a672987654c
user_id
必需
示例值:
ou_7dab8a3d3cdcc9da365777c7ad535d62
page_size
可选
示例值:
10
page_token
可选
示例值:
2
Header 参数
Authorization
string
必需
默认值:
Bearer {{access_token}}
Content-Type
string
必需
默认值:
application/json; charset=utf-8
返回响应
修改于 2023-02-03 09:39:10