How yusufcanesener/online-dietitian-platform works
Online Diyetisyen Platformu connects members, dietitians, and admins through web and mobile clients to a FastAPI service. The main workflow is role-based sign-in, member nutrition tracking and dietitian plan management, with AI analysis and reports as an additional workflow; messaging, subscriptions, news, and notifications are also documented capabilities. Agent scheduling and rule-based risk analysis form an internal layer. Several feature endpoints and screens are represented by their existing directories because their implementation was not sampled; links without direct source evidence are omitted.
Main entry points: main.py FastAPI application · src/App.tsx Web portal · front-end-mobile/App.tsx Mobile app · router.py REST route registry
Components 25
Web and mobile clients
- Web portal
frontend/src/App.tsx - Admin panel
frontend/src/pages/AdminPanel.tsx - Mobile app
front-end-mobile/App.tsx - Mobile auth
front-end-mobile/src/context/AuthContext.tsx - Mobile auth service
front-end-mobile/src/services/authService.ts - Mobile API client
front-end-mobile/src/services/api.ts - Mobile local storage
front-end-mobile/src/utils/storage.ts
API and identity
- FastAPI application
backend/app/main.py - REST route registry
backend/app/api/api_v1/router.py - Role-based identity
backend/app/api/api_v1/endpoints/auth.py
Nutrition and care
- Care endpoints
backend/app/api/api_v1/endpoints
AI and agents
- AI endpoints
backend/app/api/api_v1/endpoints/ai_router.py - AI orchestrator
backend/app/agent/orchestrator.py - Risk rule engine
backend/app/agent/rule_engine.py - Agent scheduler
backend/app/agent/scheduler.py - Agent batch runner
backend/app/agent/batch_runner.py - Agent live updates
backend/app/agent/websocket_manager.py
Persistence and integrations
- n8n automation
- Database initialization
backend/app/core/database.py - MongoDB
- User and member records
backend/app/models/user.py - Agent logs
backend/app/models/agent_log.py
Other components
- Member
- Dietitian
- Admin
Connections 31
- Member → Web portal: uses
README.md - Dietitian → Web portal: uses
README.md - Admin → Web portal: uses
README.md - Member → Mobile app: uses
README.md - Dietitian → Mobile app: uses
README.md - Admin → Mobile app: uses
README.md - Web portal → Admin panel: routes to
frontend/src/App.tsx - Web portal → FastAPI application: uses API
README.md - Mobile app → Mobile auth: renders
front-end-mobile/App.tsx - Mobile auth → Mobile auth service: uses
front-end-mobile/src/context/AuthContext.tsx - Mobile auth → Mobile local storage: uses
front-end-mobile/src/context/AuthContext.tsx - Mobile auth service → Mobile API client: sends requests
front-end-mobile/src/services/authService.ts - Mobile auth service → Mobile local storage: stores credentials
front-end-mobile/src/services/authService.ts - Mobile API client → Mobile local storage: reads token
front-end-mobile/src/services/api.ts - Mobile app → FastAPI application: uses API
README.md - FastAPI application → REST route registry: mounts routes
backend/app/main.py - FastAPI application → Database initialization: initializes
backend/app/main.py - FastAPI application → Agent scheduler: starts scheduler
backend/app/main.py - REST route registry → Role-based identity: registers
backend/app/api/api_v1/router.py - REST route registry → Care endpoints: registers feature routes
backend/app/api/api_v1/router.py - REST route registry → AI endpoints: registers
backend/app/api/api_v1/router.py - AI endpoints → AI orchestrator: invokes
backend/app/api/api_v1/endpoints/ai_router.py - AI endpoints → n8n automation: triggers workflows
backend/app/api/api_v1/endpoints/ai_router.py - Agent scheduler → Agent batch runner: runs batches
backend/app/agent/scheduler.py - Agent scheduler → Agent live updates: publishes updates
backend/app/agent/scheduler.py - AI orchestrator → Risk rule engine: uses rules
backend/app/agent/orchestrator.py - AI orchestrator → Agent logs: records analysis
backend/app/agent/orchestrator.py - Risk rule engine → User and member records: analyzes member data
- Database initialization → MongoDB: connects
backend/app/core/database.py - Database initialization → User and member records: registers models
backend/app/core/database.py - Database initialization → Agent logs: registers models
backend/app/core/database.py