微信客服消息推送
最后更新:2025/8/14在企微管家中有微信客服消息时推送此消息,type=46
{
"message_id": "1760175904711639553",
"type": 46,
"content": "{\"msg_id\":\"dbf4377d895f6eed6fed569fbc10241d\",\"session_id\":123235465645,\"servicer_group_id\":56342,\"open_kfid\":\"we456opfj78opjfsdip4223\",\"tenant_id\":\"wensd34534dfghdh5367\",\"external_user_id\":\"external_user_id\",\"send_time\":1465756654645465,\"origin\":1,\"satisfaction\":true,\"servicer_user_id\":\"dfsepiJNH23234sdfsF3234\",\"msg_type\":1,\"text\":{\"content\":\"content\",\"menu_id\":\"menuId\"},\"image\":{\"path\":\"path\",\"media_id\":\"mediaId\"},\"voice\":{\"media_id\":\"mediaId\",\"path\":\"path\",\"second\":1},\"video\":{\"media_id\":\"mediaId\",\"path\":\"path\"},\"file\":{\"media_id\":\"mediaId\",\"path\":\"path\",\"size\":1345645756,\"ext\":\"ext\",\"filename\":\"filename\"},\"location\":{\"name\":\"name\",\"address\":\"address\",\"latitude\":\"latitude\",\"longitude\":\"longitude\"},\"link\":{\"title\":\"title\",\"pic_url\":\"picUrl\",\"desc\":\"desc\",\"url\":\"url\",\"thumb_media_id\":\"thumbMediaId\",\"path\":\"path\"},\"business_card\":{\"user_id\":\"userId\",\"avatar\":\"avatar\"},\"miniprogram\":{\"app_id\":\"appId\",\"title\":\"title\",\"thumb_media_id\":\"thumbMediaId\",\"page_path\":\"pagePath\",\"path\":\"path\"},\"event\":{\"event_type\":\"eventType\",\"open_kfid\":\"openKfId\",\"external_user_id\":\"externalUserId\",\"scene\":\"scene\",\"scene_param\":\"sceneParam\",\"fail_msg_id\":\"failMsgId\",\"fail_type\":\"failType\",\"servicer_user_id\":\"servicerUserId\",\"status\":2,\"change_type\":1,\"old_servicer_user_id\":\"oldServicerUserId\",\"new_servicer_user_id\":\"newServicerUserId\"}}",
"gmt_create": 1684121106
}
业务参数说明:
| 参数 | 类型 | 说明 |
|---|---|---|
| msg_id | string | 消息id |
| session_id | long | 会话id |
| servicer_group_id | long | 接待组id |
| open_kfid | string | 客服账号id |
| tenant_id | string | 租户id |
| external_user_id | string | 外部联系人id |
| send_time | long | 发送时间(时间戳,格式:秒) |
| origin | int | 来源。 消息来源 1:来自客户回复 2:来自客服回复 3:来自系统 |
| satisfaction | bool | 满意度。 是否是满意度评价消息。 |
| servicer_user_id | string | 接待人员id |
| msg_type | int | 消息类型 |
| text | obj | 文本消息 |
| content | string | 文本内容 |
| menu_id | string | 客户点击菜单消息,触发的回复消息中附带的菜单ID |
| image | obj | 图片消息 |
| media_id | string | 图片文件id |
| path | string | 图像地址 |
| voice | obj | 语音消息 |
| media_id | string | 语音文件ID |
| path | string | 图像地址 |
| second | string | 语音时长,单位秒 |
| file | obj | 文件消息 |
| media_id | string | 文件id |
| path | string | 地址 |
| size | string | 文件大小 |
| ext | string | 文件后缀 |
| filename | string | 文件名 |
| location | obj | 位置消息 |
| name | string | 位置名称 |
| address | string | 地址 |
| latitude | string | 经度 |
| longitude | string | 纬度 |
| link | obj | 链接消息 |
| title | string | 标题 |
| pic_url | string | 缩略图链接 |
| desc | string | 描述 |
| url | string | 点击跳转的链接地址 |
| thumb_media_id | string | 文件id |
| path | string | 路径 |
| business_card | obj | 名片消息 |
| user_id | string | 名片用户id |
| avatar | string | 员工头像 |
| miniprogram | obj | 小程序消息 |
| app_id | string | 小程序appid |
| title | string | 标题 |
| thumb_media_id | string | 小程序消息封面的mediaid |
| page_path | string | 点击消息卡片后进入的小程序页面路径 |
| path | string | 路径 |
| event | obj | 事件消息 |
| event_type | string | 事件类型 |
| open_kfid | string | 客服账号id |
| external_user_id | string | 外部联系人id |
| scene | string | 进入会话的场景值,获取客服账号链接开发者自定义的场景值 |
| scene_param | string | 进入会话的自定义参数,获取客服账号链接返回的url,开发者按规范拼接的scene_param参数 |
| fail_msg_id | string | 失败消息id |
| fail_type | string | 失败的消息类型 |
| servicer_user_id | string | 接待人员id |
| status | string | 状态 |
| change_type | string | 变更类型 |
| old_servicer_user_id | string | 变更前接待人员id |
| new_servicer_user_id | string | 变更后接待人员id |