# 获取API规则加好友列表

请求方式:POST

请求地址:https://$basehost/gateway/qopen/GetFriendsAutoAddRuleList

body参数

{
    "app_type": 2,
    "offset": 0,
    "limit": 10,
    "robot_id":"机器人id"
}
字段 类型 必填 说明
app_type int 1-扫码号 2-平台号
offset int 每次获取的的开始位置,最小值为0
limit int 每次获取的条数,取值范围(1~100)
robot_id string 机器人id

返回值:

{
    "data": {
        "has_more": true,
        "rule_list": [
            {
                "rule_id": "规则id",
                "name": "规则名称",
                "created_at": 1626267674,
                "robot_count": 1,
                "creator_name": "创建规则的员工名字",
                "need_add_count": 100,
                "passed_count": 0,
                "effective_add_count": 91,
                "added_count": 67,
                "state": 1,
                "apply_state": 2,
                "is_deduplication": false
            }
        ]
    },
    "errcode": 0,
    "errmsg": "",
    "hint": ""
}

返回说明

字段 类型 说明
data json json返回值
   has_more bool 是否有下一页
   rule_list array 规则列表
     rule_id string 规则id
     name string 规则名称
     created_at int 创建时间
     robot_count int 规则配置的机器人数量
     creator_name string 创建规则的员工名字
     need_add_count int 任务数量
     passed_count int 成功添加
     effective_add_count int 有效申请数(成功发送申请)
     added_count int 已发起申请数量
     state int 允许导入数据, 1-开启,2-关闭
     apply_state int 任务执行状态, 1-开启,2-关闭
     is_deduplication bool 是否好友去重,true-开启,false-关闭
errcode int 状态码,0为正常,非0代表错误
errmsg string 错误信息
hint string 请求日志ID

完整请求示例:

curl -X POST \
  https://$basehost/gateway/qopen/GetFriendsAutoAddRuleList \
  -H 'Content-Type: application/json; charset=UTF-8' \
  -H 'Token: c2NdxDHKXIJ5j1zrhJeq2eJEHjh9xxx' \
  -d '{
    "app_type": 2,
    "offset": 0,
    "limit": 10
}'
最后更新时间: 2024/1/24 10:34:06