Loading…

Send a message to a friend

```javascript WXAPI.userImSendmessage(token, uid, content) ``` + token the token returned by the login interface + uid friend user number + content message content ```json { "code": 0, "msg": "success" } ``` #Extended functions ## You can also send messages to the other party even if you are not a friend of the other party. System parameters, add `switch type` parameter `im_sendmessge_needfriend` ## After sending a message to the other party, you will automatically become their friend. System parameters, add `switch type` parameter `im_sendmessge_autoTobeFriend`