# yashaswinimshetty/aarohana---smart-tourist-safety-app architecture

> Architecture diagram of the GitHub repository yashaswinimshetty/aarohana---smart-tourist-safety-app, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/yashaswinimshetty/aarohana---smart-tourist-safety-app
- Repository: https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app

## Overview

Aarohana is a tourist-safety application whose user flow is onboarding and registration, then access to a digital identity, itinerary, location, and SOS features. The frontend routes these screens to a JSON API; the backend provides tourist, itinerary, and alert operations with file-backed data. The README also highlights real-time location tracking and instant SOS alerts, though the supplied excerpts do not establish a location transport or live-tracking implementation. Edges below use shown calls, routing, or README claims; unsampled capabilities are included without speculative implementation links.

Main entry points: [`aarohan-frontend/src/App.js`](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/App.js) (Route shell), [`aarohan-frontend/src/api/apiClient.js`](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/api/apiClient.js) (API client), [`aarohan-frontend/src/screens/Onboarding.jsx`](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Onboarding.jsx) (Registration), [`aarohan-backend/server.js`](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/server.js) (HTTP API)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Tourist app"]
  node_app["Route shell<br/>[App.js]"]
  node_onboard["Registration<br/>[Onboarding.jsx]"]
  node_credentials["Personal details"]
  node_emergency_form["Emergency details"]
  node_trip_form["Trip details"]
  node_validation["Form validation<br/>[validation.js]"]
  node_verification["Verification step"]
  node_home["Safety home<br/>[Home.jsx]"]
  node_digital_id["Digital identity<br/>[DigitalID.jsx]"]
  node_badge["Blockchain badge"]
  node_itinerary["Trip itinerary<br/>[Itinerary.jsx]"]
  node_location["Location view<br/>[Location.jsx]"]
  node_sos["SOS alerts<br/>[Emergency.jsx]"]
  node_api_client["API client<br/>[apiClient.js]"]
end

subgraph group_services["Safety API"]
  node_api["HTTP API<br/>[server.js]"]
  node_validation_backend["Server validation<br/>[validation.js]"]
  node_live_location["Real-time tracking<br/>[Location.jsx]"]
end

subgraph group_state["Application data"]
  node_tourist_data[("Tourist records<br/>[tourists.json]")]
  node_itinerary_data[("Itinerary records<br/>[itineraries.json]")]
  node_alert_data[("Alert records<br/>[alerts.json]")]
end

node_tourist(("Tourist"))

node_tourist -->|"opens app"| node_app
node_app -->|"routes to"| node_onboard
node_app -->|"routes to"| node_home
node_app -->|"routes to"| node_digital_id
node_app -->|"routes to"| node_itinerary
node_app -->|"routes to"| node_location
node_app -->|"routes to"| node_sos
node_onboard -->|"renders"| node_credentials
node_onboard -->|"renders"| node_emergency_form
node_onboard -->|"renders"| node_trip_form
node_trip_form -->|"validates with"| node_validation
node_onboard -->|"shows"| node_verification
node_onboard -->|"creates tourist"| node_api_client
node_home -->|"requests data"| node_api_client
node_digital_id -->|"requests data"| node_api_client
node_digital_id -->|"renders"| node_badge
node_itinerary -->|"reads and creates"| node_api_client
node_location -->|"requests data"| node_api_client
node_sos -->|"creates alert"| node_api_client
node_api_client -->|"sends JSON requests"| node_api
node_api -->|"validates input"| node_validation_backend
node_api -.->|"reads and writes"| node_tourist_data
node_api -.->|"reads and writes"| node_itinerary_data
node_api -.->|"writes alerts"| node_alert_data
node_tourist -.->|"uses tracking"| node_live_location

click node_app "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/App.js"
click node_onboard "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Onboarding.jsx"
click node_credentials "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/onboarding/CredentialsForm.jsx"
click node_emergency_form "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/onboarding/EmergencyContactForm.jsx"
click node_trip_form "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/onboarding/TripDetailsForm.jsx"
click node_validation "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/utils/validation.js"
click node_verification "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/onboarding/VerificationLoader.jsx"
click node_home "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Home.jsx"
click node_digital_id "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/DigitalID.jsx"
click node_badge "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/digitalID/BlockchainBadge.jsx"
click node_itinerary "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Itinerary.jsx"
click node_location "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Location.jsx"
click node_sos "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Emergency.jsx"
click node_api_client "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/api/apiClient.js"
click node_api "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/server.js"
click node_validation_backend "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/validation.js"
click node_tourist_data "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/data/tourists.json"
click node_itinerary_data "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/data/itineraries.json"
click node_alert_data "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/data/alerts.json"
click node_live_location "https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Location.jsx"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_app,node_onboard,node_credentials,node_emergency_form,node_trip_form,node_validation,node_verification,node_home,node_digital_id,node_badge,node_itinerary,node_location,node_sos,node_api_client toneBlue
class node_api,node_validation_backend,node_live_location toneAmber
class node_tourist_data,node_itinerary_data,node_alert_data toneMint
class node_tourist toneIndigo
```

## Components

### Tourist app

- [Route shell](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/App.js): `aarohan-frontend/src/App.js`
- [Registration](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Onboarding.jsx): `aarohan-frontend/src/screens/Onboarding.jsx`
- [Personal details](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/onboarding/CredentialsForm.jsx): `aarohan-frontend/src/components/onboarding/CredentialsForm.jsx`
- [Emergency details](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/onboarding/EmergencyContactForm.jsx): `aarohan-frontend/src/components/onboarding/EmergencyContactForm.jsx`
- [Trip details](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/onboarding/TripDetailsForm.jsx): `aarohan-frontend/src/components/onboarding/TripDetailsForm.jsx`
- [Form validation](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/utils/validation.js): `aarohan-frontend/src/utils/validation.js`
- [Verification step](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/onboarding/VerificationLoader.jsx): `aarohan-frontend/src/components/onboarding/VerificationLoader.jsx`
- [Safety home](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Home.jsx): `aarohan-frontend/src/screens/Home.jsx`
- [Digital identity](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/DigitalID.jsx): `aarohan-frontend/src/screens/DigitalID.jsx`
- [Blockchain badge](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/components/digitalID/BlockchainBadge.jsx): `aarohan-frontend/src/components/digitalID/BlockchainBadge.jsx`
- [Trip itinerary](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Itinerary.jsx): `aarohan-frontend/src/screens/Itinerary.jsx`
- [Location view](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Location.jsx): `aarohan-frontend/src/screens/Location.jsx`
- [SOS alerts](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Emergency.jsx): `aarohan-frontend/src/screens/Emergency.jsx`
- [API client](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/api/apiClient.js): `aarohan-frontend/src/api/apiClient.js`

### Safety API

- [HTTP API](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/server.js): `aarohan-backend/server.js`
- [Server validation](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/validation.js): `aarohan-backend/validation.js`
- [Real-time tracking](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-frontend/src/screens/Location.jsx): `aarohan-frontend/src/screens/Location.jsx`

### Application data

- [Tourist records](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/data/tourists.json): `aarohan-backend/data/tourists.json`
- [Itinerary records](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/data/itineraries.json): `aarohan-backend/data/itineraries.json`
- [Alert records](https://github.com/yashaswinimshetty/aarohana---smart-tourist-safety-app/blob/main/aarohan-backend/data/alerts.json): `aarohan-backend/data/alerts.json`

### Other components

- **Tourist**

## Connections

- Tourist → Route shell: opens app (evidence: `aarohan-frontend/src/App.js`)
- Route shell → Registration: routes to (evidence: `aarohan-frontend/src/App.js`)
- Route shell → Safety home: routes to (evidence: `aarohan-frontend/src/App.js`)
- Route shell → Digital identity: routes to (evidence: `aarohan-frontend/src/App.js`)
- Route shell → Trip itinerary: routes to (evidence: `aarohan-frontend/src/App.js`)
- Route shell → Location view: routes to (evidence: `aarohan-frontend/src/App.js`)
- Route shell → SOS alerts: routes to (evidence: `aarohan-frontend/src/App.js`)
- Registration → Personal details: renders (evidence: `aarohan-frontend/src/screens/Onboarding.jsx`)
- Registration → Emergency details: renders (evidence: `aarohan-frontend/src/screens/Onboarding.jsx`)
- Registration → Trip details: renders (evidence: `aarohan-frontend/src/screens/Onboarding.jsx`)
- Trip details → Form validation: validates with (evidence: `aarohan-frontend/src/components/onboarding/TripDetailsForm.jsx`)
- Registration → Verification step: shows (evidence: `aarohan-frontend/src/screens/Onboarding.jsx`)
- Registration → API client: creates tourist (evidence: `aarohan-frontend/src/screens/Onboarding.jsx`)
- Safety home → API client: requests data (evidence: `aarohan-frontend/src/screens/Home.jsx`)
- Digital identity → API client: requests data (evidence: `aarohan-frontend/src/screens/DigitalID.jsx`)
- Digital identity → Blockchain badge: renders (evidence: `aarohan-frontend/src/screens/DigitalID.jsx`)
- Trip itinerary → API client: reads and creates (evidence: `aarohan-frontend/src/screens/Itinerary.jsx`)
- Location view → API client: requests data (evidence: `aarohan-frontend/src/screens/Location.jsx`)
- SOS alerts → API client: creates alert (evidence: `aarohan-frontend/src/screens/Emergency.jsx`)
- API client → HTTP API: sends JSON requests (evidence: `aarohan-frontend/src/api/apiClient.js`)
- HTTP API → Server validation: validates input (evidence: `aarohan-backend/server.js`)
- HTTP API → Tourist records: reads and writes
- HTTP API → Itinerary records: reads and writes
- HTTP API → Alert records: writes alerts
- Tourist → Real-time tracking: uses tracking (evidence: `README.md`)
