diff --git "a/callmanage2/\346\225\260\346\215\256\346\216\250\351\200\201\345\222\214\345\233\236\350\260\203\346\216\245\345\217\243.md" "b/callmanage2/\346\225\260\346\215\256\346\216\250\351\200\201\345\222\214\345\233\236\350\260\203\346\216\245\345\217\243.md" new file mode 100644 index 0000000..cfd91e0 --- /dev/null +++ "b/callmanage2/\346\225\260\346\215\256\346\216\250\351\200\201\345\222\214\345\233\236\350\260\203\346\216\245\345\217\243.md" @@ -0,0 +1,259 @@ +- BaseUrl + - 生产环境: http://hw-gz26.heyqiwu.cn:60013 + +#### 推送外呼数据 + +URL: {BaseUrl}/out/push/call + +METHOD: POST + +RequestHeaders: + +| key | description | +| :----------- | :------------ | +| Content-Type | application/json;charset=utf-8 | +| Timestamp | 请求时的时间戳,毫秒级 | +| Authorization | 签名, 将 appSecret+":"+timestamp 字符串md5提取摘要 | +| App-Channel-Id | 渠道ID | + +RequestBody: + +```json +{ + "username":"admin", // 运营平台任务创建者的用户名 + "outputCallTaskName":"进峰测试催收推送任务", // 任务名 + "outputCallCallbackUrl":"http://hw-gz59.heyqiwu.cn:60013/test/callback", // 回调地址 + "teleInfos":[ // 电话信息 + { + "nickname":"未知", // 电话人姓名 + "sex":"未知", // 电话人性别 + "job":"未知", // 电话人职位 + "location":"未知", // 电话人地点 + + "number":"", // 电话人号码 + "encodeNumber": "simo_test_20221009142217_7", // 加密后的号码 + "serviceName": "默认", // 业务名 + + "customSessionId":"121231", // 第三方会话ID + } + ] +} + +``` + +ResponseBody: + +```json +{ + "code": 1, // 1:表示成功, 其他表示失败 + "msg": "成功", // 提示信息 + "data": null +} +``` + +Example + +``` +curl --location --request POST 'http://hw-gz26.heyqiwu.cn:60013/out/push/call' \ +--header 'Timestamp: 1665296802212' \ +--header 'Authorization: 6c4a7fef4710e2caea0a32900a19862f' \ +--header 'App-Channel-Id: simo-test' \ +--header 'Content-Type: application/json' \ +--data-raw '{ + "username":"admin", + "outputCallTaskName":"吉仕线路任务测试", + "outputCallCallbackUrl":"http://hw-gz26.heyqiwu.cn:60013/test/callback", + "teleInfos":[ + { + "nickname":"未知", + "sex":"未知", + "job":"未知", + "location":"未知", + + "number":"", + "encodeNumber": "simo_test_20221009142217_7", + "serviceName": "默认", + + "customSessionId":"12123111" + } + ] +}' +``` + +#### 客户回调接口 + +URL: {BaseUrl}/out/custom/callback + +METHOD: POST + +RequestHeaders: + +| key | description | +| :----------- | :------------ | +| Content-Type | application/json;charset=utf-8 | +| Timestamp | 请求时的时间戳,毫秒级 | +| Authorization | 签名, 将 appSecret+":"+timestamp 字符串md5提取摘要 | +| App-Channel-Id | 渠道ID | + +RequestBody: + +```json +{ + "username":"boluobao0001", // 用户名 + "outputCallTaskName":"菠萝包召回", // 任务名 + + "teleNumber":"", // 回调的电话号码 + "tele_encode_number":"simo_test_20221009142217_7", // 加密后的号码 + "serviceName": "默认", // 业务名 + + "customSessionId":"18059821525", // 回调的客户自定义sessionId + "status":2 // 客户回调状态: 0: 初始状态 1: 短信发送失败 2: 短信发送成功 3: 用户已接收短信 4: 用户进入宣传页面 5: 用户召回成功 6:接收短信失败 +} +``` + +ResponseBody: + +```json +{ + "code": 1, // 1:表示成功, 其他表示失败 + "msg": "成功", // 提示信息 + "data": null +} +``` + +Example + +``` +curl --location --request POST 'http://hw-gz26.heyqiwu.cn:60013/out/custom/callback' \ +--header 'App-Channel-Id: boluobao-pro' \ +--header 'Timestamp: 1656397270262' \ +--header 'Authorization: 8a969f6dbac5d09660c19c2a686cac0a' \ +--header 'Content-Type: application/json' \ +--data-raw '{ + "username":"boluobao0001", + "outputCallTaskName":"菠萝包召回", + "teleNumber":"", + "tele_encode_number":"simo_test_20221009142217_7", + "serviceName": "默认", + "customSessionId":"18059821525", + "status":2 +} +' +``` + +#### 任务执行状态更新-暂停-启动 + +URL: {BaseUrl}/out/task/status/update + +METHOD: POST + +RequestHeaders: + +| key | description | +| :----------- | :------------ | +| Content-Type | application/json;charset=utf-8 | +| Timestamp | 请求时的时间戳,毫秒级 | +| Authorization | 签名, 将 appSecret+":"+timestamp 字符串md5提取摘要 | +| App-Channel-Id | 渠道ID | + +RequestBody: + +```json +{ + "username":"admin", // 用户名 + "outputCallTaskName":"进峰测试sip方式留创网关", // 任务名 + "status": 2 // 0:立即执行; 2:停止 +} +``` + +ResponseBody: + +```json +{ + "code": 1, // 1:表示成功, 其他表示失败 + "msg": "成功", // 提示信息 + "data": null +} +``` + +Example + +``` +curl --location --request POST 'http://hw-gz59.heyqiwu.cn:60011/out/task/status/update' \ +--header 'Timestamp: 1663914548839' \ +--header 'Authorization: e02f9d3ddcc99acb54e9c581ce280f7d' \ +--header 'App-Channel-Id: qiwu-monitor-pro' \ +--header 'Content-Type: application/json' \ +--data-raw '{ + "username":"admin", + "outputCallTaskName":"进峰测试sip方式留创网关", + "status": 2 +}' +``` + +#### 回调标签 + +URL: 推送外呼数据接口传的outputCallCallbackUrl字段链接 + +METHOD: POST + +RequestHeaders: + +| key | description | +| :----------- | :------------ | +| Content-Type | application/json;charset=utf-8 | +| Timestamp | 请求时的时间戳,毫秒级 | +| Authorization | 签名, 将 appSecret+":"+timestamp 字符串md5提取摘要 | +| App-Channel-Id | 渠道ID | + +RequestBody: + +```json +{ + "teleNumber":"", // 用户电话 + "teleEncodeNumber": "simo_test_20221009142217_7", // 加密后的号码 + "teleServiceName": "默认", // 业务名称 + "customSessionId":"121231", + "tags":"还款意愿:拒绝还款,逾期原因:忘记有借款,通话状态:本人接通", // BOT打的标签 + "callStatus": 1, // 1: 未接通, 4: 通话完成, 0: 已接通 + "callbackType": 1 // 1: 正常完成回调; 2: 短信通知 + +} +``` + +ResponseBody: + +```json +{ + "code": 1, // 1:表示成功, 其他表示失败 + "msg": "成功", // 提示信息 + "data": null +} +``` + +Example + +``` +curl --location --request POST 'http://hw-gz26.heyqiwu.cn:60013/test/callback' \ +--header 'App-Channel-Id: cuishou' \ +--header 'Timestamp: 1651919109374' \ +--header 'Authorization: 591a889c55e958cd59a05a596d5f5c8d' \ +--header 'Content-Type: application/json' \ +--data-raw '{ + "teleNumber":"", + "teleEncodeNumber": "simo_test_20221009142217_7", + "teleServiceName": "默认", + "tags":"还款意愿:拒绝还款,逾期原因:忘记有借款,通话状态:本人接通", + "customSessionId":"121231", + "callStatus": 1, +}' +``` + +#### 外呼对话系统uid生成规则 + +``` +{服务名称}_{毫秒级时间戳}_{customSessionId} +{服务名称}_{毫秒级时间戳}_{电话号码} +{服务名称}_{毫秒级时间戳}_{随机串} +``` +