chat-sdk-javascript icon indicating copy to clipboard operation
chat-sdk-javascript copied to clipboard

Is it possible to use this SDK with a node.js application directly.

Open abanobmikaeel opened this issue 1 year ago • 1 comments

The problem

Unable to use this SDK from Node.js

What was the expected behavior?

To be able to hit the Comet Chat API from my API directly to create users/keep track of their tokens in my DB.

Reproduction

  1. Install this library to a node.js codebase
  2. you will get the error
ReferenceError: window is not defined  at Object.<anonymous>        
node_modul   ││   es/@cometchat/chat-sdk-javascript/CometChat.js:1:224)
  • Version used: Latest
  • Other modules/plugins/libraries that might be involved: Strapi.js

abanobmikaeel avatar May 10 '24 05:05 abanobmikaeel

Rosanne Fernando (CometChat Team) replied:

Hello there,

Thanks for reaching out with your concern. I am Rosanne from the Support team.

Happy to help you. Can you please elaborate more on the issue you are facing and what exactly you are trying to achieve? Additionally, can you specify the version of the JavaScript SDK you are using so that we can investigate this further?

Regards.

Rosanne Fernando CometChat