DEV Community

Discussion on: Python Chat Tutorial with Django and React

Collapse
 
nickparsons profile image
Nick Parsons

Happy to help. Any chance your API key is mixed up / not the same between your app and server-side code? This would throw that kind of error.

Collapse
 
zedgr profile image
ZED

I have the same issue and I am using the following:

For the Frontend
this.client = new StreamChat("69XXX");

For the Backend at settings.py
STREAM_API_KEY = "g4eXXXXXXXXX"
STREAM_API_SECRET = "4wyXXXXXXXXX..."

Collapse
 
clinggit profile image
Chia Ling

I have the Chat.js and settings.py files updated with the same API key. Is there somewhere else the API key needs to be set that I missed?

Thread Thread
 
rhenter profile image
Rafael Henter • Edited

The problem is that the Django User ID is an integer and the Chat is missing some code.
Following my examples:

github.com/rhenter/stream-chat-api
github.com/rhenter/stream-chat-react

PS: In the React Project I didn't create a Custom Readme, so you must to add you credentials on Chat.js if you wore to try to use