How engineer12-garko/quranshare works
QuranFlow is a Quranic reminder-video library with a browser client and FastAPI backend. The main user journey is to browse or receive recommendations for catalog videos, stream one, share it, and optionally confirm it was posted; authenticated activity supports personalized recommendations. Curators synchronize the catalog from Google Drive. Separate reader and Du'a routes provide Quran and supplication content through external providers, with Quran Foundation compatibility and verse-of-day capabilities retained. Edges reflect shown route registration, indexed references, or README documentation; unsampled subsystem internals are not inferred.
Main entry points: main.py FastAPI application · routes/videos.py Video endpoints · services/videos.py Catalog and streaming · history.py Posting history
Components 31
Browser experience
- QuranFlow client
app/static/js/app.js
API and identity
- FastAPI application
app/main.py - Auth routes
app/routes/auth.py - Auth service
app/services/auth.py - Session authorization
app/dependencies/auth.py - User records
app/models/user.py - Admin operations
app/routes/admin.py
Video catalog
- Video endpoints
app/routes/videos.py - Catalog and streaming
app/services/videos.py - Video records
app/models/video.py - Category endpoints
app/routes/categories.py - Category records
app/models/category.py - Drive catalog sync
app/services/sync.py - Drive file access
app/services/google_drive.py
User activity
- Share and history
app/routes/history.py - Posting history
app/services/history.py - Posting records
app/models/posting_history.py - Reminder endpoints
app/routes/reminder.py - Recommendations
app/services/reminder.py - Progress endpoints
app/routes/progress.py - Reading progress
app/services/progress.py
Quran and Du'a
- Quran reader routes
app/routes/content.py - AlQuran Cloud client
app/services/alquran_cloud.py - Quran Foundation client
app/services/quran_foundation.py - Du'a endpoints
app/routes/duas.py - OpenDua client
app/services/opendua.py
Other components
- Visitor / user
- Google Drive
- Quran content APIs
- OpenDua API
- SQL database
app/database.py
Connections 40
- Visitor / user → QuranFlow client: uses
- QuranFlow client → FastAPI application: requests API
- FastAPI application → Auth routes: registers
app/main.py - FastAPI application → Video endpoints: registers
app/main.py - FastAPI application → Category endpoints: registers
app/main.py - FastAPI application → Quran reader routes: registers
app/main.py - FastAPI application → Du'a endpoints: registers
app/main.py - FastAPI application → Share and history: registers
app/main.py - FastAPI application → Reminder endpoints: registers
app/main.py - FastAPI application → Progress endpoints: registers
app/main.py - FastAPI application → Admin operations: registers
app/main.py - Auth routes → Auth service: calls
app/routes/auth.py - Auth service → User records: creates and checks
app/services/auth.py - Session authorization → User records: loads session user
app/dependencies/auth.py - Auth routes → Session authorization: requires current user
app/routes/auth.py - Admin operations → Session authorization: requires roles
app/routes/admin.py - Admin operations → Drive catalog sync: runs sync
app/routes/admin.py - Drive catalog sync → Drive file access: lists Drive files
app/services/sync.py - Drive file access → Google Drive: lists and streams
app/services/google_drive.py - Video endpoints → Catalog and streaming: calls
app/routes/videos.py - Catalog and streaming → Video records: queries catalog
app/services/videos.py - Catalog and streaming → Drive file access: streams file
app/services/videos.py - Category endpoints → Category records: queries categories
app/routes/categories.py - Video endpoints → Posting history: records share or post
app/routes/videos.py - Share and history → Posting history: calls
app/routes/history.py - Posting history → Posting records: records activity
app/services/history.py - Video endpoints → Recommendations: requests recommendations
app/routes/videos.py - Reminder endpoints → Recommendations: calls
app/routes/reminder.py - Recommendations → Posting records: reads recent posts
app/services/reminder.py - Progress endpoints → Reading progress: calls
app/routes/progress.py - Quran reader routes → AlQuran Cloud client: calls
app/routes/content.py - Quran reader routes → Quran Foundation client: calls
app/routes/content.py - AlQuran Cloud client → Quran content APIs: fetches Quran data
- Quran Foundation client → Quran content APIs: fetches compatibility content
- Du'a endpoints → OpenDua client: calls
app/routes/duas.py - OpenDua client → OpenDua API: fetches Du'a data
- Auth service → SQL database: reads and writes
- Catalog and streaming → SQL database: reads catalog
- Posting history → SQL database: stores activity
- Drive catalog sync → SQL database: updates catalog