获取客服帐号列表,包括所有的客服帐号的客服ID、名称和头像。
请求方式: POST(HTTPS)
请求地址: https://qyapi.weixin.qq.com/cgi-bin/kf/account/list?access_token=ACCESS_TOKEN
请求示例:
{
"offset": 0,
"limit": 100
}
当客服较多时,需要使用参数offset及limit 分页获取,注意offset是以0为起点,这里以图例简单说明:当获取到的 account_list中的账号数量小于 指定的limit 的时候,表示已经没有更多的数据,此时应终止获取。
参数说明:
参数 | 必须 | 类型 | 说明 |
---|---|---|---|
access_token | 是 | string | 调用接口凭证 |
offset | 否 | uint32 | 分页,偏移量, 默认为0 |
limit | 否 | uint32 | 分页,预期请求的数据量,默认为100,取值范围 1 ~ 100 |
权限说明:
返回结果:
{
"errcode": 0,
"errmsg": "ok",
"account_list": [
{
"open_kfid": "wkAJ2GCAAASSm4_FhToWMFea0xAFfd3Q",
"name": "咨询客服",
"avatar": "https://wework.qpic.cn/wwhead/duc2TvpEgSSjibPZlNR6chpx9W3dtd9Ogp8XEmSNKGa6uufMWn2239HUPuwIFoYYZ7Ph580FPvo8/0"
}
]
}
参数说明:
参数 | 类型 | 说明 |
---|---|---|
errcode | int32 | 返回码 |
errmsg | string | 错误码描述 |
account_list | obj[] | 帐号信息列表 |
account_list.open_kfid | string | 客服帐号ID |
account_list.name | string | 客服名称 |
account_list.avatar | string | 客服头像URL |