How harshitvanani/apix works
APIx collects airline fares, standardizes and validates them, calculates a daily fare index, and serves fare, trend, and route analytics through an institutional dashboard and API. The principal ingestion and database relationships are supported by sampled source; the tree indicates additional API and visualization modules, but their internal calls were not sampled, so those connections are left conservative.
Main entry points: main.py FastAPI service · DashboardView.jsx Dashboard view · master_orchestrator.py Harvest coordinator · ingestion_pipeline.py Ingestion pipeline
Components 22
Fare collection
- Harvest coordinator
backend/scrapers/master_orchestrator.py - Airline scrapers
backend/scrapers/airline_scrapers.py - OTA scrapers
backend/scrapers/ota_scrapers.py - Scrape engines
backend/scrapers/engine
Data processing
- Ingestion pipeline
backend/tasks/ingestion_pipeline.py - Fare cleansing
backend/tasks/data_cleansing_service.py - Index calculation
backend/services/index_calculator.py - DGCA validation
backend/services/dgca_validation_service.py
Persistence and cache
- Mongo connection
backend/services/mongo_manager.py - Fare and index store
- Redis cache
API and validation
- FastAPI service
backend/api/main.py - Database access
backend/services/db_service.py - Fare endpoints
backend/api/routes/fares.py - Analytics endpoints
backend/api/routes/analytics.py
Institutional dashboard
- Authenticated app
frontend/src/App.jsx - Dashboard view
frontend/src/DashboardView.jsx - Charts and metrics
frontend/src/components/VisualizationSuite.jsx - Route analytics view
frontend/src/components/RouteAnalytics.jsx - Route fares table
frontend/src/components/RouteFaresTable.jsx
Other components
- Institutional users
- Airline and OTA sources
Connections 24
- Institutional users → Authenticated app: use portal
- Authenticated app → Dashboard view: routes to
- Airline and OTA sources → Airline scrapers: provide fares
- Airline and OTA sources → OTA scrapers: provide fares
- Harvest coordinator → Airline scrapers: dispatches harvest
- Harvest coordinator → OTA scrapers: dispatches harvest
- Airline scrapers → Scrape engines: use engines
- OTA scrapers → Scrape engines: use engines
- Harvest coordinator → Ingestion pipeline: submits fares
- Ingestion pipeline → Fare cleansing: cleans fares
- Ingestion pipeline → Fare and index store: reads and writes
- Fare cleansing → Fare and index store: reads and writes
- Index calculation → Fare and index store: stores index
- DGCA validation → Fare and index store: reads fares
- Mongo connection → Fare and index store: connects
- FastAPI service → Mongo connection: uses connection
- FastAPI service → Redis cache: caches fare stats
- FastAPI service → Database access: uses data access
- FastAPI service → Fare endpoints: mounts routes
- FastAPI service → Analytics endpoints: mounts routes
- Dashboard view → Charts and metrics: renders charts
- Dashboard view → Route analytics view: renders analytics
- Dashboard view → Route fares table: renders fares
- Authenticated app → FastAPI service: requests data