A real-time mobile bingo game built with Kotlin and Jetpack Compose for the Android front-end and Python/Flask for the web API backend. This project is currently under development and aims to be a full-stack application with a mobile client and a web dashboard.
- Mobile App (Android): A client-side application that allows players to join a game.
- Web API (Python/Flask): A RESTful API that handles player registration, generates a unique bingo card for each player, and stores the data.
- Real-Time Web Dashboard: A web page that displays all registered players and their unique bingo cards in real-time. This page automatically updates every 3 seconds to reflect new registrations.
- Persistent Data: Player and bingo card data are stored in a local JSON file (
bingo_data.json
) on the server, ensuring data isn't lost when the server restarts.
- Android: Kotlin, Jetpack Compose, Coroutines, ViewModel, Retrofit, and OkHttp.
- Backend: Python, Flask, Gunicorn (for production).
- Database: MongoDB Atlas (NOSQL)
- Hosting: Render (for the public web service).
- Clone the repository:
git clone [https://github.com/your-username/your-repo-name.git](https://github.com/your-username/your-repo-name.git) cd your-repo-name/backend
- Create a virtual environment and install dependencies:
Your
python -m venv venv source venv/bin/activate # On Windows, use `venv\Scripts\activate` pip install -r requirements.txt
requirements.txt
should containFlask
. - Run the server:
The server will run on
python app.py
http://127.0.0.1:5000
.
- Open the project in Android Studio.
- Update the API URL:
- If you're using the local server, find your computer's local IP address and update the
BASE_URL
in yourApiService
file:const val BASE_URL = "http://YOUR_LOCAL_IP:5000/"
- If you're using the public web service hosted on Render, update the
BASE_URL
to the public URL:const val BASE_URL = "[https://bingo-jl6k.onrender.com/](https://bingo-jl6k.onrender.com/)"
- If you're using the local server, find your computer's local IP address and update the
- Build and run the app on an emulator or a physical device.
The web dashboard is a live view of all registered players and their cards. You can access it at:
https://bingo-jl6k.onrender.com/
This page will automatically update as new players are registered through the mobile app.