public interface WxMpKefuService
| 限定符和类型 | 方法和说明 | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
boolean |
kfAccountAdd(WxMpKfAccountRequest request)
添加客服账号
详情请见:
booleankfAccountDel(String kfAccount)
删除客服账号
详情请见:
booleankfAccountInviteWorker(WxMpKfAccountRequest request)
设置客服信息(即更新客服信息)
详情请见:
booleankfAccountUpdate(WxMpKfAccountRequest request)
设置客服信息(即更新客服信息)
详情请见:
booleankfAccountUploadHeadImg(String kfAccount,
File imgFile)
上传客服头像
详情请见:
WxMpKfListkfList()
获取客服基本信息
详情请见:
WxMpKfMsgListkfMsgList(Date startTime,
Date endTime)
获取聊天记录(优化接口,返回指定时间段内所有的聊天记录)
此接口返回的聊天记录中,对于图片、语音、视频,分别展示成文本格式的[image]、[voice]、[video]
详情请见:
WxMpKfMsgListkfMsgList(Date startTime,
Date endTime,
Long msgId,
Integer number)
获取聊天记录(原始接口)
此接口返回的聊天记录中,对于图片、语音、视频,分别展示成文本格式的[image]、[voice]、[video]
详情请见:
WxMpKfOnlineListkfOnlineList()
| ||||||||||||||||
boolean |
kfSessionCreate(String openid,
String kfAccount)
创建会话
此接口在客服和用户之间创建一个会话,如果该客服和用户会话已存在,则直接返回0。
|
||||||||||||||||
WxMpKfSessionGetResult |
kfSessionGet(String openid)
获取客户的会话状态
此接口获取一个客户的会话,如果不存在,则kf_account为空。
|
||||||||||||||||
WxMpKfSessionWaitCaseList |
kfSessionGetWaitCase()
获取未接入会话列表
开发者可以通过本接口获取当前正在等待队列中的会话列表,此接口最多返回最早进入队列的100个未接入会话。
|
||||||||||||||||
WxMpKfSessionList |
kfSessionList(String kfAccount)
获取客服的会话列表
开发者可以通过本接口获取某个客服正在接待的会话列表。
|
WxMpKfList kfList() throws WxErrorException
获取客服基本信息 详情请见:客服管理 接口url格式:https://api.weixin.qq.com/cgi-bin/customservice/getkflist?access_token=ACCESS_TOKEN
WxErrorExceptionWxMpKfOnlineList kfOnlineList() throws WxErrorException
获取在线客服接待信息 详情请见:客服管理 接口url格式:https://api.weixin.qq.com/cgi-bin/customservice/getonlinekflist?access_token=ACCESS_TOKEN
WxErrorExceptionboolean kfAccountAdd(WxMpKfAccountRequest request) throws WxErrorException
添加客服账号 详情请见:客服管理 接口url格式:https://api.weixin.qq.com/customservice/kfaccount/add?access_token=ACCESS_TOKEN
WxErrorExceptionboolean kfAccountUpdate(WxMpKfAccountRequest request) throws WxErrorException
设置客服信息(即更新客服信息) 详情请见:客服管理 接口url格式:https://api.weixin.qq.com/customservice/kfaccount/update?access_token=ACCESS_TOKEN
WxErrorExceptionboolean kfAccountInviteWorker(WxMpKfAccountRequest request) throws WxErrorException
设置客服信息(即更新客服信息) 详情请见:客服管理 接口url格式:https://api.weixin.qq.com/customservice/kfaccount/inviteworker?access_token=ACCESS_TOKEN
WxErrorExceptionboolean kfAccountUploadHeadImg(String kfAccount, File imgFile) throws WxErrorException
上传客服头像 详情请见:客服管理 接口url格式:http://api.weixin.qq.com/customservice/kfaccount/uploadheadimg?access_token=ACCESS_TOKEN&kf_account=KFACCOUNT
WxErrorExceptionboolean kfAccountDel(String kfAccount) throws WxErrorException
删除客服账号 详情请见:客服管理 接口url格式:https://api.weixin.qq.com/customservice/kfaccount/del?access_token=ACCESS_TOKEN&kf_account=KFACCOUNT
WxErrorExceptionboolean kfSessionCreate(String openid, String kfAccount) throws WxErrorException
创建会话 此接口在客服和用户之间创建一个会话,如果该客服和用户会话已存在,则直接返回0。指定的客服帐号必须已经绑定微信号且在线。 详情请见:客服会话控制接口 接口url格式: https://api.weixin.qq.com/customservice/kfsession/create?access_token=ACCESS_TOKEN
WxErrorExceptionboolean kfSessionClose(String openid, String kfAccount) throws WxErrorException
关闭会话 开发者可以使用本接口,关闭一个会话。 详情请见:客服会话控制接口 接口url格式: https://api.weixin.qq.com/customservice/kfsession/close?access_token=ACCESS_TOKEN
WxErrorExceptionWxMpKfSessionGetResult kfSessionGet(String openid) throws WxErrorException
获取客户的会话状态 此接口获取一个客户的会话,如果不存在,则kf_account为空。 详情请见:客服会话控制接口 接口url格式: https://api.weixin.qq.com/customservice/kfsession/getsession?access_token=ACCESS_TOKEN&openid=OPENID
WxErrorExceptionWxMpKfSessionList kfSessionList(String kfAccount) throws WxErrorException
获取客服的会话列表 开发者可以通过本接口获取某个客服正在接待的会话列表。 详情请见:客服会话控制 接口url格式: https://api.weixin.qq.com/customservice/kfsession/getsessionlist?access_token=ACCESS_TOKEN&kf_account=KFACCOUNT
WxErrorExceptionWxMpKfSessionWaitCaseList kfSessionGetWaitCase() throws WxErrorException
获取未接入会话列表 开发者可以通过本接口获取当前正在等待队列中的会话列表,此接口最多返回最早进入队列的100个未接入会话。 详情请见:客服会话控制 接口url格式: https://api.weixin.qq.com/customservice/kfsession/getwaitcase?access_token=ACCESS_TOKEN
WxErrorExceptionWxMpKfMsgList kfMsgList(Date startTime, Date endTime, Long msgId, Integer number) throws WxErrorException
获取聊天记录(原始接口) 此接口返回的聊天记录中,对于图片、语音、视频,分别展示成文本格式的[image]、[voice]、[video] 详情请见:获取聊天记录 接口url格式: https://api.weixin.qq.com/customservice/msgrecord/getmsglist?access_token=ACCESS_TOKEN
startTime - 起始时间endTime - 结束时间msgId - 消息id顺序从小到大,从1开始number - 每次获取条数,最多10000条WxErrorExceptionWxMpKfMsgList kfMsgList(Date startTime, Date endTime) throws WxErrorException
获取聊天记录(优化接口,返回指定时间段内所有的聊天记录) 此接口返回的聊天记录中,对于图片、语音、视频,分别展示成文本格式的[image]、[voice]、[video] 详情请见:获取聊天记录 接口url格式: https://api.weixin.qq.com/customservice/msgrecord/getmsglist?access_token=ACCESS_TOKEN
startTime - 起始时间endTime - 结束时间WxErrorExceptionCopyright © 2016. All rights reserved.