Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

332
Views
How would I verify an users identity SOCKET.IO

I am making an live - chat platform, but I cannot find a way to verify a users identity.

I do not have any code because there arent any errors.

about 4 years ago · Juan Pablo Isaza
2 answers
Answer question

0

You need a way to uniquely identify the socket to each client, so you'd have to do something like this:

Login request to API > API retrieves user from database > Sends Response to Client > Create websocket connection in frontend, pass in unique id from database response through url params to wss endpoint > you can also do db transactions with this unique identifier to add more fine grained control for caching/session tracking.

It's hard to really give specific code examples if you're not sharing your code.

about 4 years ago · Juan Pablo Isaza Report

0

I ended up solving this after reading this article. They used the express-session package and showed how to get the req.session variable from a socket.io event.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!