获取用户审批通过数据
POST
/open-apis/attendance/v1/user_approvals/query
请假的假期时长字段(interval),暂未开放提供,待后续提供。
错误码
HTTP状态码 | 错误码 | 描述 | 排查建议 |
---|---|---|---|
400 | 1220001 | 参数错误 | 请检查参数是否符合要求 |
400 | 1220002 | 租户不存在 | 请检查 tenant_access_token 是否正确 |
400 | 1220004 | 用户不存在或没有权限 | 请检查用户 ID 是否正确 |
400 | 1220005 | 没有权限 | 请前往考勤管理后台检查数据权限范围 |
500 | 1225000 | 系统错误 | 详见错误信息 |
500 | 1226000 | 班次服务系统错误 | 详见错误信息 |
500 | 1226500 | 打卡服务系统错误 | 详见错误信息 |
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://open.feishu.cn/open-apis/attendance/v1/user_approvals/query?employee_type=employee_id' \
--header 'Authorization;' \
--header 'Content-Type: application/json' \
--data-raw '{
"user_ids": [
"abd754f7"
],
"check_date_from": 20190817,
"check_date_to": 20190820,
"check_date_type": "PeriodTime",
"status": 2,
"check_time_from": "1566641088",
"check_time_to": "1592561088"
}'
响应示例响应示例
{
"code": 0,
"msg": "success",
"data": {
"user_approvals": [
{
"user_id": "abd754f7",
"date": "20210104",
"outs": [
{
"approval_id": "6737202939523236113",
"uniq_id": "9496E43696967658A512969523E89870",
"unit": 1,
"interval": 28800,
"start_time": "2021-01-04 09:00:00",
"end_time": "2021-01-04 19:00:00",
"i18n_names": {
"ch": "中文描述",
"en": "English description",
"ja": "日本語の説明"
},
"default_locale": "ch",
"reason": "外出办事",
"approve_pass_time": "2021-01-04 12:00:00",
"approve_apply_time": "2021-01-04 11:00:00"
}
],
"leaves": [
{
"approval_id": "6737202939523236113",
"uniq_id": "6852582717813440527",
"unit": 1,
"interval": 28800,
"start_time": "2021-01-04 09:00:00",
"end_time": "2021-01-04 19:00:00",
"i18n_names": {
"ch": "中文描述",
"en": "English description",
"ja": "日本語の説明"
},
"default_locale": "ch",
"reason": "家里有事",
"approve_pass_time": "2021-01-04 12:00:00",
"approve_apply_time": "2021-01-04 11:00:00"
}
],
"overtime_works": [
{
"approval_id": "6737202939523236113",
"duration": 1.5,
"unit": 1,
"category": 2,
"type": 1,
"start_time": "2021-01-09 09:00:00",
"end_time": "2021-01-10 13:00:00"
}
],
"trips": [
{
"approval_id": "6737202939523236113",
"start_time": "2021-01-04 09:00:00",
"end_time": "2021-01-04 19:00:00",
"reason": "培训",
"approve_pass_time": "2021-01-04 12:00:00",
"approve_apply_time": "2021-01-04 11:00:00"
}
],
"time_zone": "Asia/Shanghai"
}
]
}
}
请求参数
Query 参数
employee_type
必需
示例值:
employee_id
Header 参数
Authorization
string
必需
默认值:
Bearer {{access_token}}
Content-Type
string
必需
默认值:
application/json; charset=utf-8
Body 参数application/json
返回响应
修改于 2023-01-28 08:47:43