Firebase is the sole backend for HADOS. It provides the real-time Firestore database that stores tournament and user data, as well as the Authentication service that handles organizer sign-in. No other server-side infrastructure is required — Firebase handles persistence, querying, and identity entirely from the client.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/VasquezRivero92/HabboCafe/llms.txt
Use this file to discover all available pages before exploring further.
Setting up Firebase
Create a Firebase project
Open console.firebase.google.com and click Add project. Give it a name (e.g.
hados-production), optionally enable Google Analytics, then click Create project.Enable Firestore Database
In the left sidebar go to Build → Firestore Database and click Create database. Choose a region close to your users, then select a starting mode:
- Production mode — all reads and writes are denied until you write security rules. Recommended for live deployments.
- Test mode — all reads and writes are allowed for 30 days. Useful during initial development.
Enable Email/Password Authentication
Go to Build → Authentication and click Get started. On the Sign-in method tab, click Email/Password, toggle it Enabled, and click Save. HADOS uses this provider for organizer accounts — no other sign-in methods are required.
Register a Web App and copy the config
From the project overview page click the Web icon (
</>). Give the app a nickname (e.g. hados-web) and click Register app. Firebase will show you a firebaseConfig object — copy the entire object, you will need it in the next step.The firebase.ts module
src/firebase.ts is the single entry point for all Firebase services in the app. It initialises the Firebase app and exports the two service instances used throughout HADOS:
Exports
| Export | Type | Purpose |
|---|---|---|
db | Firestore | Used for all Firestore reads and writes — tournament groups, participants, and results. |
auth | Auth | Used for organizer sign-in, sign-out, and auth-state observation. |
app (internal) | FirebaseApp | The root initialized app instance. Consumed internally by db and auth; not re-exported. |
Firestore collections
HADOS uses two top-level Firestore collections:| Collection | Description |
|---|---|
users | Stores HabboUser documents representing registered players and organizers. |
dados | Stores Dado tournament-group documents, each representing a dice-roll group in a tournament round. |
The Firebase Spark (free) plan is sufficient for running small to medium Habbo dice tournaments. Spark includes 1 GiB of Firestore storage, 50,000 daily reads, and 20,000 daily writes — more than enough for a typical HADOS event.