Closed miladr0 closed 6 years ago
You can use setAuthToken method on the socket to set token, before connecting to server.
On Fri, Jul 20, 2018 at 1:50 AM Milad Ranjbar notifications@github.com wrote:
hi in socket.io i use this way for auth before connect to socket. IO.Options options = new IO.Options(); options.query = "token=" + token; socket = IO.socket(SERVER_ADDRESS, options); socket.connect(); can i user this way with this library?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/sacOO7/socketcluster-client-java/issues/38, or mute the thread https://github.com/notifications/unsubscribe-auth/AP8vSW2YvVZ888vIoZCXMXC6v0dX7E9eks5uIOoNgaJpZM4VXCBK .
Hi @miladr0 , will close the issue, if your problem is resolved 👍 . Please let me know your updates on this.
hi @sacOO7 , i couldn't solved the problem according to your suggestion, so i stick to socket.io, thanks anyway.
Ohh no problem @miladr0 , please let me know if you use socketcluster in future and face any problem again 👍.
hello @sacOO7
How to set multiple option in your library.
I have option like this:
{ hostname: 'chat.xxx.com', secure: true, port: 5001, rejectUnauthorized: false // Only necessary during debug if using a self-signed certificate }
hi in socket.io i use this way for auth before connect to socket.
IO.Options options = new IO.Options(); options.query = "token=" + token; socket = IO.socket(SERVER_ADDRESS, options); socket.connect();
can i user this way with this library?