这是我的通地系统对话发送消息的代码
req.post({
url: 'https://leancloud.cn/1.1/rtm/messages',
headers: {
'X-LC-Id': APP_ID,
'X-LC-Key': MASTER_KEY + ',master'
},
json:true,
body: {
'from_peer': conv.name,
'message': message,
'conv_id': conv.objectId,
'to_peers': [peerId],
'transient': false
}
}, function (error, response, body) {
if (error) {
console.log('send message error: ' + response.statusCode + JSON.stringify(body));
}
});
到是接受者接受不到消息,查看消息记录,不管我peerId参数怎么变,消息记录的 to 的值都是一个固定的值
"to": "566b8de860b25b04370c69a0", to 这里不应该是接收者id么?我查了一下,这里的to成了我的系统会话的id,以前还能正确收系统消息,现在收不了了。
-
创建时间
16年1月26日
-
最后回复
16年1月26日
-
1
回复
-
822
浏览
-
1
用户