Scope: SHOP_BA_CHAT 需要申请权限 需要用户授权
触发场景#
场景:客服/用户/系统通知消息
公共参数#
| 参数名称 | 参数类型 | 参数描述 |
|---|---|---|
| event | string | 事件名 |
| timestamp | string | 事件发生时间标签 格式为yyyy-MM-dd HH:mm:ss(UTC+8) |
| content | struct | 具体消息结构体 |
消息字段#
| 参数名 | 类型 | 备注 |
|---|---|---|
| conversation_id | int | 会话id |
| main_open_id | string | 主账号open_id |
| user_open_id | string | 用户open_id |
| user_nick | string | 用户昵称 |
| user_face | string | 用户头像 |
| msg_content | string | 消息内容 |
| msg_key | string | 消息唯一标识 |
| msg_source | int | 消息来源1-苹果手机,2-安卓手机 3-ipad,6-web页 ,7-接口调用,8-客服工作台 |
| msg_status | int | 消息状态-0生效状态 |
| msg_type | int | 消息类型1-文本,2-图片,6-收藏类表情,17-视频,10005-订单,10006-商品,10008-智能欢迎语,10009-智能欢迎问题list,10015-退出人工会话,10018-客服主动消息,10019-灰字提示,10022-蓝链,10023-灰条 |
| send_type | int | 发送方类型:0-智能会话 1-人工客服,2-系统通知、3-用户 |
| ts | int | 最新消息时间戳,秒级 |
示例#
text
{
"content": {
"conversation_id": 1580570,
"user_nick": "bili_231016875",
"user_face": "https://i0.hdslb.com/bfs/face/0e1ac9dafe41aa716cb181b59edd24c736ba8c4c.jpg",
"msg_content": "{\"content\":\"V1.0-dfdaf1231231\"}",
"msg_key": "7447437175064307348",
"msg_source": 8,
"msg_status": 0,
"msg_type": 1,
"send_type": 1,
"ts": 1733991591,
"main_open_id": "490713ab45d542ad97065da4c95a5fbd",
"user_open_id": "c92520481c7744e58d8e8e2edda2cc17"
},
"event": "SEND_MSG",
"timestamp": "2024-12-01 00:00:00"
}