-
Notifications
You must be signed in to change notification settings - Fork 366
Send private message #175
Comments
I think you can consider following approach:
|
I've created the PR #187 for this issue. My approach is as follows:
You can take look at more details about the The socket IO server log will be the following output texts: 2019-04-11T06:19:24.135Z - info: SocketIO > listening on port 1337
2019-04-11T06:19:27.208Z - info: auth token this_is_peter_token
2019-04-11T06:19:27.210Z - info: SocketIO > Connected socket M5E21GSH8uWbkk9aAAAA
2019-04-11T06:19:27.210Z - info: X-My-Header websocket rocks
2019-04-11T06:19:27.221Z - info: ElephantIO private_chat_message > {"message":"How are you?","token":"this_is_peter_token"}
2019-04-11T06:19:27.221Z - info: ElephantIO private_chat_message > I am fine, peter
2019-04-11T06:19:27.223Z - info: SocketIO : Received 1 messages
2019-04-11T06:19:27.223Z - info: SocketIO > Disconnected socket M5E21GSH8uWbkk9aAAAA
2019-04-11T06:19:27.225Z - info: auth token this_is_peter_token
2019-04-11T06:19:27.225Z - info: SocketIO > Connected socket Yv8bbaA8-pR1OgKYAAAB
2019-04-11T06:19:27.225Z - info: X-My-Header websocket rocks
2019-04-11T06:19:27.228Z - info: ElephantIO private_chat_message > {"message":"Do you remember me?","token":"this_is_peter_token"}
2019-04-11T06:19:27.228Z - info: ElephantIO private_chat_message > I remember you, peter
2019-04-11T06:19:27.228Z - info: ElephantIO private_chat_message > {"message":"Do you remember me?","token":"this_is_invalid_peter_token"}
2019-04-11T06:19:27.228Z - info: ElephantIO private_chat_message > Token is invalid
2019-04-11T06:19:27.228Z - info: ElephantIO private_chat_message > Sorry. I don't remember you.
2019-04-11T06:19:27.229Z - info: SocketIO : Received 2 messages
2019-04-11T06:19:27.229Z - info: SocketIO > Disconnected socket Yv8bbaA8-pR1OgKYAAAB
|
@arafsan, if having any problem about sending messahe to private socket id, please write the comment on this issue :). |
Hi, @peter279k I'm just trying to use elephant.io. I have tried #175 (comment) but I still got error like this:
|
Hi @awdynto, thanks for your reply. I'm not sure what kinds of dependencies you use. Could you provide your |
Hi, how can I use this to send a message to a private socket id ?
The text was updated successfully, but these errors were encountered: