How denuoweb/questbycycle works
Main Components
a) Frontend Layer:
• Static assets (/app/static/)
• CSS styles
• JavaScript modules
• Images and media
• Templates (/app/templates/)
• Core pages
• Modal components
• Email templates
b) Backend Layer:
• Core Application Modules:
• Authentication (auth.py)
• Game Management (games.py)
• Quest System (quests.py)
• Badge System (badges.py)
• AI Integration (ai.py)
• Social Features (social.py)
• Admin Interface (admin.py)
• User Profiles (profile.py)
c) Database Layer:
• PostgreSQL Database
• Models (models.py)
d) External Services:
• Social Media Integration
• Twitter/X
• OpenAI API
• Email Service (SMTP)
[Client Browsers/Devices]
• ↕
[NGINX Web Server]
• ↕
[Gunicorn WSGI Server]
• ↕
[Flask Application]
• ↙ ↓ ↘
[Database] [External APIs] [File System]
Component Relationships
Following interactions:
• Client-Server communication through NGINX
• WebSocket connections for real-time features
• Database interactions for user data, quests, and badges
• External API calls to social media platforms and OpenAI
• File system interactions for static assets
Technical Details
• Python/Flask backend
• PostgreSQL database
• Gunicorn with GeventWebSocket workers
• NGINX reverse proxy
• Poetry for dependency management
• External API connections
Deployment Architecture
Production setup:
• NGINX configuration
• Gunicorn service
• Database connection
• File system structure