How pasupulasaiteja/darukaaearth works
Darukaa.Earth is a geospatial environmental-project platform. Administrators authenticate, manage projects, draw site polygons, and review spatial summaries and environmental time series; biodiversity views add live GBIF species telemetry. The graph combines sampled implementation links with capabilities and API relationships explicitly documented in the README. Several route and page implementations were not sampled, so their internal calls are not inferred.
Main entry points: ProjectDetailsPage.tsx Project details · api.py API v1 routes · App.tsx Route shell · sites.py Site routes
Components 34
Web application
- Route shell
frontend/src/App.tsx - Session context
frontend/src/context/AuthContext.tsx - Auth client
frontend/src/services/auth.ts - Project management
frontend/src/pages/ProjectsPage.tsx - Project details
frontend/src/pages/ProjectDetailsPage.tsx - Dashboard
frontend/src/pages/DashboardPage.tsx - Site analytics
frontend/src/pages/SiteDetailsPage.tsx - Site map
frontend/src/components/Map/MapboxViewer.tsx - Polygon drawing
frontend/src/components/Map/MapboxDrawer.tsx - Metric charts
frontend/src/components/Charts - Species panel
frontend/src/components/Biodiversity/GBIFBiodiversityPanel.tsx - REST client
frontend/src/services/api.ts - Notifications
frontend/src/context/ToastContext.tsx - Local mock data
frontend/src/services/mockEngine.ts - UI buttons
frontend/src/components/UI/Button.tsx - Status badges
frontend/src/components/UI/Badge.tsx
API and domain
- FastAPI application
backend/app/main.py - API v1 routes
backend/app/api/v1/api.py - Authentication routes
backend/app/api/v1/auth.py - Project routes
backend/app/api/v1/projects.py - Site routes
backend/app/api/v1/sites.py - Dashboard summaries
backend/app/api/v1/dashboard.py - Time-series analytics
backend/app/api/v1/analytics.py - JWT and passwords
backend/app/core/security.py
Spatial services
- Spatial calculations
backend/app/geo/spatial_utils.py
Persistence
- Database sessions
backend/app/core/database.py - User records
backend/app/models/user.py - Project records
backend/app/models/project.py - Spatial site records
backend/app/models/site.py - Analytics records
backend/app/models/analytics.py
Environmental data
- Biodiversity routes
backend/app/api/v1/biodiversity.py - GBIF queries
backend/app/services/gbif_service.py
Other components
- Administrator
- GBIF service
Connections 41
- Administrator → Route shell: uses
frontend/src/App.tsx - Route shell → Session context: provides session
frontend/src/App.tsx - Route shell → Project management: routes to
frontend/src/App.tsx - Route shell → Project details: routes to
frontend/src/App.tsx - Route shell → Dashboard: routes to
frontend/src/App.tsx - Route shell → Site analytics: routes to
frontend/src/App.tsx - Session context → Auth client: calls
frontend/src/context/AuthContext.tsx - Auth client → REST client: uses
frontend/src/services/auth.ts - Project details → Site map: renders
frontend/src/pages/ProjectDetailsPage.tsx - Project details → Polygon drawing: renders
frontend/src/pages/ProjectDetailsPage.tsx - Project details → Notifications: notifies
frontend/src/pages/ProjectDetailsPage.tsx - Site map → Dashboard: shows site map
- Dashboard → Metric charts: renders metrics
- Site analytics → Metric charts: renders metrics
- Site analytics → Species panel: shows species
- Project details → REST client: requests project data
- Dashboard → REST client: requests summaries
- Site analytics → REST client: requests site data
- FastAPI application → API v1 routes: includes routes
backend/app/main.py - API v1 routes → Authentication routes: registers
backend/app/api/v1/api.py - API v1 routes → Project routes: registers
backend/app/api/v1/api.py - API v1 routes → Site routes: registers
backend/app/api/v1/api.py - API v1 routes → Dashboard summaries: registers
backend/app/api/v1/api.py - API v1 routes → Time-series analytics: registers
backend/app/api/v1/api.py - API v1 routes → Biodiversity routes: registers
backend/app/api/v1/api.py - Authentication routes → JWT and passwords: hashes and signs
backend/app/api/v1/auth.py - Authentication routes → User records: reads and writes
backend/app/api/v1/auth.py - Site routes → Spatial calculations: calculates geometry
backend/app/api/v1/sites.py - Site routes → Spatial site records: reads and writes
backend/app/api/v1/sites.py - Site routes → Analytics records: creates baselines
backend/app/api/v1/sites.py - Site routes → Project records: checks parent project
backend/app/api/v1/sites.py - FastAPI application → Database sessions: initializes
backend/app/main.py - Database sessions → User records: provides ORM base
backend/app/models/user.py - Database sessions → Project records: provides ORM base
backend/app/models/project.py - Database sessions → Spatial site records: provides ORM base
backend/app/models/site.py - Database sessions → Analytics records: provides ORM base
backend/app/models/analytics.py - Biodiversity routes → GBIF queries: queries species
- GBIF queries → GBIF service: requests occurrences
- Local mock data → Species panel: supplies mock data
- Project details → UI buttons: renders
frontend/src/pages/ProjectDetailsPage.tsx - Project details → Status badges: renders
frontend/src/pages/ProjectDetailsPage.tsx