How ahmadkhalid007/saletracking works
SaleTracking is a web application for monitoring product prices and stock, with scheduled, time-windowed checks and configurable alerts. The main workflow is to create a tracking request, persist it, have the background processor check the product, and submit notifications through the selected channels. The application also provides account and settings management, dashboards, in-app notifications, SMTP administration, and a separate WhatsApp Web bridge. Relationships for unsampled subsystems are omitted or marked unverified rather than inferred from names alone.
Main entry points: PriceTrackingProcessor.cs Tracking processor · site.js Web interface · CreateController.cs Create tracking · http-server.js HTTP endpoints
Components 24
Web application
- Web interface
SaleTracking/wwwroot/js/site.js - Account management
SaleTracking/Controllers/AccountController.cs - Profile settings
SaleTracking/Controllers/SettingsController.cs - Create tracking
SaleTracking/Controllers/CreateController.cs - Tracking dashboard
SaleTracking/Controllers/DashboardController.cs - Notification center
SaleTracking/Controllers/NotificationsController.cs
Tracking workflow
- Alert schedule
SaleTracking/Services/TrackingSchedule.cs - Tracking processor
SaleTracking/Services/PriceTrackingProcessor.cs - Product scraping
SaleTracking/Services/ShopifyProductScraping.cs - Tracking record
SaleTracking/Models/TrackingItem.cs
Persistence
- Account store
SaleTracking/Services/SqliteAccountStore.cs - Tracking store
SaleTracking/Services/SqliteTrackingStore.cs - SQLite database
SaleTracking/Services/SqliteDatabase.cs
Alert delivery
- In-app alerts
SaleTracking/Services/InAppNotificationService.cs - Email settings
SaleTracking/Controllers/EmailController.cs - SMTP configuration
SaleTracking/Services/ISmtpConfigurationStore.cs - Email delivery
SaleTracking/Services/EmailNotificationService.cs - WhatsApp delivery
SaleTracking/Services/WhatsAppWebNotificationService.cs
WhatsApp bridge
- Bridge worker
SaleTracking/Services/WhatsAppBridgeWorker.cs - Bridge server
WhatsAppBridge/server.js - HTTP endpoints
WhatsAppBridge/http-server.js - Message sender
WhatsAppBridge/sender.js
Other components
- User
- WhatsApp Web
Connections 25
- User → Web interface: uses
- Web interface → Account management: submits requests
- Web interface → Create tracking: submits tracking
- Web interface → Tracking dashboard: opens dashboard
- Create tracking → Tracking processor: checks track
SaleTracking/Controllers/CreateController.cs - Create tracking → Alert schedule: gets local date
SaleTracking/Controllers/CreateController.cs - Tracking dashboard → Tracking processor: checks track
SaleTracking/Controllers/DashboardController.cs - Tracking processor → Alert schedule: checks eligibility
SaleTracking/Services/PriceTrackingProcessor.cs - Tracking processor → Tracking record: checks tracking
SaleTracking/Services/PriceTrackingProcessor.cs - Tracking processor → Product scraping: scrapes product
- Tracking processor → Tracking store: reads and updates
- Tracking processor → In-app alerts: creates notification
- Tracking processor → Email delivery: sends alert
- Tracking processor → WhatsApp delivery: sends alert
- Account store → SQLite database: uses
SaleTracking/Services/SqliteAccountStore.cs - Tracking store → SQLite database: uses
SaleTracking/Services/SqliteTrackingStore.cs - In-app alerts → SQLite database: stores notifications
SaleTracking/Services/InAppNotificationService.cs - Email settings → SMTP configuration: reads and saves
SaleTracking/Controllers/EmailController.cs - Email delivery → SMTP configuration: loads settings
SaleTracking/Services/EmailNotificationService.cs - WhatsApp delivery → WhatsApp Web: sends HTTP requests
SaleTracking/Services/WhatsAppWebNotificationService.cs - Bridge worker → WhatsApp delivery: checks bridge
- Bridge server → HTTP endpoints: creates server
WhatsAppBridge/server.js - Bridge server → Message sender: uses sender
WhatsAppBridge/server.js - HTTP endpoints → Message sender: dispatches messages
WhatsAppBridge/http-server.js - HTTP endpoints → WhatsApp Web: serves bridge API