An OpenFGA sample application to showcase using fine-grained permissions for access control to shared lists.
As a sample, the shared lists are lists of a user's favorite wines. A (future) fully-featured app, would be a modern web application for wine enthusiasts to catalog, rate, and share their favorite wines.
- 📝 Create and manage wine lists
- 🤝 Share lists with friends or make them public
- 🔒 Fine-grained permissions using OpenFGA
- 📱 Mobile-friendly design
- 🍷 Add wines with photos, tasting notes, and details
- 📸 Upload wine label photos
- 🔍 Search and filter wines
- FastAPI - Modern Python web framework
- PostgreSQL - Database
- SQLAlchemy - ORM
- OpenFGA - Authorization
- Alembic - Database migrations
- React - UI library
- Vite - Build tool
- TailwindCSS - Styling
- React Query - Data fetching
- React Router - Navigation
See SETUP.md for detailed instructions.
# Clone and setup
git clone https://github.com/dyeam0/winebrt.git
cd winebrt
docker-compose up -d
# Backend
cd backend
python -m venv venv
source venv/bin/activate
pip install -r requirements.txt
alembic upgrade head
uvicorn app.main:app --reload
# Frontend
cd frontend
npm install
npm run devVisit http://localhost:5173
winebrt/
├── backend/ # FastAPI backend
│ ├── app/
│ │ ├── main.py
│ │ ├── models/
│ │ ├── routers/
│ │ ├── auth/
│ │ └── fga/
│ ├── tests/
│ └── alembic/
├── frontend/ # React frontend
│ ├── src/
│ │ ├── components/
│ │ ├── pages/
│ │ ├── hooks/
│ │ └── api/
│ └── public/
├── model.fga # OpenFGA model
└── docker-compose.yml
MIT