Hi all, I am trying to make an app which allows users to start a chat with each other. I’m planning to use the chatroom method of doing this, but no option to end/close the chatroom. So if I am userA, and let’s say I chose to start a chat with userB, a room entry would be created in the firebase realtime database, and for both the users in their apps, the room id would be visible. Clicking upon the room id should fetch all the messages in it, and show them in a DVL with custom layout. I took inspiration from @muneer 's chatroom firebase structure here - Making better chat apps with the "Any Component" blocks - #80 by muneer
Chat-DB chat-Room Room-Code Message-List Date-Stamp (as message ID) Sender Message-Text
The issue I am facing is I’ve never worked with Firebase in Thunkable X, so I don’t know how it works. How do I get started on this? Here’s the workflow I am imagining the users are going to have -
- They choose who they want to chat with.
- A room is created with a unique ID (in my primary google sheets DB, i’ll keep track of all the rooms a user has) and it is added to both user’s chatroom ids.
- the app has a menu of “My Chats”, which displays all the chatroom IDs the user has linked to their record.
- if I click on an ID, i get all the messages in that room displayed on the DVL, and i can append messages to it at the end.
A pretty basic chatroom experience, except i’m totally confused on how I should do it, as I’ve never used Firebase… Can someone maybe guide me through few steps, like creating a room entry, fetching details and adding listener to room id when user picks to open it? Thanks!!