Error when trying to connect user
I was getting the following error with my code and still do after cloning your repository.
Uncaught (in promise) Error: {"code":2,"StatusCode":401,"message":"WS failed with code 2 and reason - Connect failed with error: \"api_key not valid\"","isWSFailure":false} at StableWSConnection2._callee$ (connection.ts:125:15) at tryCatch (regeneratorRuntime.js:44:17) at Generator.<anonymous> (regeneratorRuntime.js:125:22) at Generator.throw (regeneratorRuntime.js:69:21) at asyncGeneratorStep (asyncToGenerator.js:3:23) at _throw (asyncToGenerator.js:25:9)
I believe the error happens when trying to connect the user, i.e. in client/src/context/AuthContext.tsx with the command below
const connectPromise = chat.connectUser(user, token).then(() => { if (isInterrupted) return; setStreamChat(chat); })
Maybe you will know what goes wrong here?
Hello Sorry for the late reply, unfortunately, I just checked GitHub and saw your issue I will check and let you know as soon as possible