发送聊天室消息
开发中POST
/im/v2/chatrooms/{room_id}/messages请求参数
Path 参数
room_id
string
聊天室 ID。
示例值:
1605537145
Body 参数application/json
object {0}
示例
{
"sender_id": "yx5",
"message": {
"message_client_id": "dsfjkldfsdlfskjdlfsdjlkfdskfsdj",
"message_type": 1,
"location_z": 34,
"text": "fugiat ullamco Duis nulla",
"attachment": {
"name": "器年众际根开以",
"md5": "esse Excepteur do",
"url": "http://zpcuedkr.nc/yjy",
"ext": "Excepteur consequat",
"width": 83,
"height": 56,
"size": 18
},
"sub_type": 72,
"location_x": 65,
"location_y": 94
},
"extension": "incididunt cupidatat",
"receiver_ids": [
"yx1",
"yx2",
"yx3"
],
"antispam_config": {
"antispam_enabled": false,
"antispam_business_id": "44",
"antispam_extension": null,
"antispam_custom_message_enabled": true,
"antispam_custom_message": "laborum non irure et",
"antispam_cheating": "{\"email\":\"123@126.com\"}"
},
"resend_flag": 0,
"message_config": {
"high_priority": false,
"chat_msg_priority": 3,
"history_enabled": false,
"need_high_priority_msg_resend": true,
"ignore_chat_banned": false,
"notify_target_tags": "et sint aute anim",
"abandon_ratio": 21,
"forbidden_if_high_priority_msg_freq": 0
},
"route_config": {
"route_environment": "aute",
"route_enabled": true
}
}
示例代码
返回响应
成功(200)
HTTP 状态码: 200
内容格式: JSONapplication/json
数据结构
code
integer
必需
msg
string
必需
data
object
必需
message
object
必需
示例
{
"code": 200,
"msg": "success",
"data": {
"message": {
"attachment": {
"ext": "Excepteur consequat",
"size": 18,
"name": "器年众际根开以",
"width": 83,
"url": "http://zpcuedkr.nc/yjy",
"md5": "esse Excepteur do",
"height": 56
},
"message_client_id": "dsfjkldfsdlfskjdlfsdjlkfdskfsdj",
"create_time": 1709175731107,
"message_type": 1,
"sender_id": "yx5",
"sender_nick": "yx5",
"sender_avatar": "",
"room_id": 1605537145,
"high_priority": false,
"sub_type": 72
}
}
}
最后修改时间: 8 个月前