Skip to content

批量删除经常性支付记录

指定经常性支付记录ID,删除ID对应的经常性支付记录

请求

项目
HTTP URLhttps://open.feishu.cn/open-apis/compensation/v1/recurring_payment/batch_remove
HTTP MethodPOST
接口频率限制10 次/秒
支持的应用类型custom
权限要求 调用该 API 所需的权限。开启其中任意一项权限即可调用corehr:compensation.recurring_payment:delete 经常性支付记录删除权限

请求头

名称类型必填描述
Authorizationstringtenant_access_token 值格式:"Bearer access_token" 示例值:"Bearer t-7f1bcd13fc57d46bac21793a18e560" 了解更多:如何选择与获取 access token
Content-Typestring固定值:"application/json; charset=utf-8"

请求体

名称类型必填描述
record_idsstring\[\]需要删除的记录ID(通过【查询经常性支付记录】 接口进行查询)
示例值:["7397033607132351532"]
数据校验规则
- 长度范围:0500
reasonstring原因
示例值:"删除错误创建的数据"

请求体示例

json
{
    "record_ids": [
        "7397033607132351532"
    ],
    "reason": "删除错误创建的数据"
}

响应

响应体

名称类型描述
codeint错误码,非 0 表示失败
msgstring错误描述
data\--
  └ operate_resultsrecurring_payment_operate_result\[\]每条记录的操作结果
    └ idstring操作记录的id
    └ unique_idstring操作的记录的 unique_id
    └ codeint操作结果状态码
可选值有
- 0: "Success" 操作成功 - 21280001: "The format of the single payment amount is incorrect" 单次发放金额格式不正确 - 21280002: "The format of the distribution start time is incorrect" 发放开始时间格式不正确 - 21280003: "The format of the issuance end time is incorrect" 发放结束时间格式不正确 - 21270304: "No permission for recurring payment record" 没有该经常性支付记录权限 - 21270305: "The recurring payment type salary item does not exist" 经常性支付类型薪酬项不存在 - 21270306: "The currency does not exist" 币种不存在 - 21270307: "The distribution method does not exist" 发放方式不存在 - 21270308: "The distribution start time is greater than the distribution end time" 发放开始时间大于发放结束时间 - 21270309: "Employees are not covered by the remuneration rules" 员工不在薪酬项规则适用范围之内 - 21270310: "The payment method does not match the salary item rules" 发放方式不匹配薪酬项规则 - 21270311: "Currency mismatch compensation item rules" 币种不匹配薪酬项规则 - 21270312: "The distribution start date is earlier than the current date and cannot be deleted" 发放开始日期早于当前日期不可删除 - 21270313: "The recurring payment record does not exist" 该经常性支付记录不存在 - 21270314: "Payment frequency does not match the salary item" 发放频率不匹配薪酬项
    └ messagestring操作结果描述

响应体示例

json
{
    "code": 0,
    "msg": "success",
    "data": {
        "operate_results": [
            {
                "id": "7390583861280556588",
                "unique_id": "7390583861280556588",
                "code": 21270202,
                "message": "unique id conflict"
            }
        ]
    }
}

错误码

HTTP状态码错误码描述排查建议
4002290001param is invalid参数异常,请检查入参
5002290002server error服务端异常,请稍后重试

内容来源:飞书开放平台 · 自动爬取整理