查询统计数据
POST
/open-apis/attendance/v1/user_stats_datas/query
自建应用
错误码
HTTP状态码 | 错误码 | 描述 | 排查建议 |
---|---|---|---|
400 | 1220001 | 参数错误 | 请检查参数是否符合要求 |
400 | 1220002 | 租户不存在 | 请检查 tenant_access_token 是否正确 |
400 | 1220004 | 用户不存在或没有权限 | 请检查用户 ID 是否正确 |
500 | 1228000 | 统计服务系统错误 | 详见错误信息 |
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://open.feishu.cn/open-apis/attendance/v1/user_stats_datas/query?employee_type=employee_id' \
--header 'Authorization;' \
--header 'Content-Type: application/json' \
--data-raw '{
"locale": "zh",
"stats_type": "month",
"start_date": 20210316,
"end_date": 20210323,
"user_ids": [
"ec8ddg56"
],
"need_history": true,
"current_group_only": true,
"user_id": "ec8ddg56"
}'
响应示例响应示例
{
"code": 0,
"msg": "success",
"data": {
"user_datas": [
{
"name": "小李",
"user_id": "ec8ddg56",
"datas": [
{
"code": "50102",
"value": "无需打卡(-), 无需打卡(-)",
"features": [
{
"key": "Abnormal",
"value": "false"
}
],
"title": "姓名"
}
]
}
]
}
}
请求参数
Query 参数
employee_type
必需
employee_no
示例值:
employee_id
Header 参数
Authorization
string
必需
默认值:
Bearer {{access_token}}
Content-Type
string
必需
默认值:
application/json; charset=utf-8
Body 参数application/json
返回响应
修改于 2023-01-28 08:45:59