How to connect Real Time Database (Firebase) to my main code?

Hi. I can’t connect the Firebase database to my code. Every time there are some errors, and I do not know why. I couldn’t find step-by-step instructions on how to do this on the Internet.
My code is that I have added AI to my telegram channel. I need the AI to remember each user of my group, as well as their messages and their own messages, while analyzing it. In principle, the code is ready for this. The only problem is connecting to the database where this data should be stored.

Welcome to the community @BellamyMornings !

Can you please provide the link to your repl and the error you are getting?


Hi! Which language are you using for this? (Please update the category of this topic accordingly.)

Also, could you provide your Repl link or your code?