| HTTP状态码 | 错误码 | 描述 | 排查建议 |
|---|---|---|---|
| 400 | 1160001 | no matching compensation standards | please check parameter |
| 400 | 1160002 | matches to multiple compensation standards | please check parameter |
| 400 | 1160003 | Invalid effective date | 日期格式必须是类似“2020-01-01” |
| 400 | 1160004 | Invalid granting quantity | 必须是能解析成数字的字符串,例如“2.5” |
| 400 | 1160005 | Leave type not found | 检查leaveTypeID是否正确 |
| 400 | 1160006 | Employment not found | 检查employmentID是否正确 |
| 400 | 1160007 | No valid leave plan version | 检查该员工任职期间是否有对应的假期计划版本 |
| 400 | 1160008 | Employment not in scope | 检查该员工任职期间是否有对应的假期计划版本 |
| 400 | 1160009 | No valid accrual rule | 检查该假期计划版本是否正确创建,是否存在有效的授予规则 |
| 400 | 1160010 | Granting record already exists | response里会带上已存在的授予记录的信息,用户可以将其取出,不需要再重试请求 |
| 500 | 1160011 | Error when getting employment | 联系研发 |
| 500 | 1160012 | DB error | 这种情况下response也会带上已存在的授予记录的信息(如果有的话),用户可以做一下额外检查 |
| 500 | 1160013 | Error when checking scope | 联系研发 |
| 500 | 1160014 | Error when calculating | 联系研发 |
| 400 | 1160024 | Should provide leave subtype ID | 如果假期类型存在子类,那么leaveTypeID必须传子类ID |
| 400 | 1160025 | Quantity out of limit | 额度范围为-9999~9999 |
| 400 | 1160026 | Quantity fraction out of limit | 最多6位小数 |
| 400 | 1160027 | Reason too long | 授予原因长度最多3000 |
| 500 | 1160028 | Error when converting unit | 检查假期计划版本的单位转换规则是否配置正确 |
| 500 | 1169999 | Unknown error | 联系研发 |
curl --location --request GET 'https://open.feishu.cn/open-apis/corehr/v1/leaves/leave_request_history?page_token=&page_size=&employment_id_list=&initiator_id_list=&leave_request_status=&leave_type_id_list=&leave_start_date_min=&leave_start_date_max=&leave_end_date_min=&leave_end_date_max=&leave_submit_date_min=&leave_submit_date_max=&user_id_type=&leave_update_time_min=&leave_update_time_max=' \
--header 'Authorization: Bearer <token>'{
"code": 0,
"msg": "success",
"data": {
"leave_request_list": [
{
"leave_request_id": "4718803945687580505",
"employment_id": "4718803945687580505",
"employment_name": [
{
"lang": "zh-CN",
"value": "张三"
}
],
"leave_type_id": "0",
"leave_type_name": [
{
"lang": "zh-CN",
"value": "张三"
}
],
"start_time": "2022-07-06 morning",
"end_time": "2023-01-05",
"leave_duration": "2",
"leave_duration_unit": 2,
"leave_request_status": 2,
"grant_source": "manual",
"return_time": "1662134400",
"submitted_at": "1659080476",
"submitted_by": "7109664941775241244",
"notes": "备注"
}
],
"has_more": true,
"page_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9"
}
}