# 获取API加好友规则详情
请求方式:POST
请求地址:https://$basehost/gateway/qopen/GetFriendsAutoAddRuleDetail
body参数:
{
"app_type": 2,
"rule_id": "规则id"
}
字段 | 类型 | 必填 | 说明 |
---|---|---|---|
app_type | int | 是 | 1-扫码号 2-平台号 |
rule_id | string | 是 | 规则id |
返回值:
{
"data": {
"rule_info": {
"rule_id": "规则id",
"name": "规则名称",
"created_at": 1625453548,
"robot_count": 1,
"creator_name": "创建规则的员工名字",
"need_add_count": 2,
"passed_count": 1,
"effective_add_count": 1,
"added_count": 2,
"state": 1,
"apply_state": 1,
"is_deduplication": false
},
"robot_info_list": [
{
"robot_id": "机器人id",
"robot_name": "机器人名称",
"avatar": "头像url"
}
],
"tag_list": [
"tag"
],
"welcome_msg_info": {
"name": ""
},
"ai_caller_info": {
"template_name": "",
"ai_template_name": ""
}
},
"errcode": 0,
"errmsg": "",
"hint": ""
}
返回说明
字段 | 类型 | 说明 |
---|---|---|
data | json | json返回值 |
rule_info.rule_id | string | 规则id |
rule_info.name | string | 规则名称 |
rule_info.created_at | int | 创建时间 |
rule_info.robot_count | int | 规则配置的机器人数量 |
rule_info.creator_name | string | 创建规则的员工名字 |
rule_info.need_add_count | int | 任务数量 |
rule_info.passed_count | int | 成功添加 |
rule_info.effective_add_count | int | 有效申请数(成功发送申请) |
rule_info.added_count | int | 已发起申请数量 |
rule_info.state | int | 允许导入数据, 1-开启,2-关闭 |
rule_info.apply_state | int | 任务执行状态, 1-开启,2-关闭 |
rule_info.is_deduplication | bool | 是否好友去重,true-开启,false-关闭 |
tag_list | array | 标签列表 |
robot_info_list[x].robot_id | string | 机器人id |
robot_info_list[x].robot_name | string | 机器人名称 |
robot_info_list[x].avatar | string | 机器人头像 |
welcome_msg_info.name | string | 欢迎语模板名称 |
ai_caller_info.template_name | string | AI外呼模板名称 |
ai_caller_info.ai_template_name | string | AI外呼话术模板名称 |
err_code | int | 状态码,0为正常,非0代表错误 |
err_msg | string | 错误信息 |
hint | string | 请求日志ID |
完整请求示例:
curl -X POST \
https://$basehost/gateway/qopen/GetFriendsAutoAddRuleDetail \
-H 'Content-Type: application/json; charset=UTF-8' \
-H 'Token: c2NdxDHKXIJ5j1zrhJeq2eJEHjh9xxx' \
-d '{
"app_type":2,
"rule_id": "规则id"
}'