# ishitasem/planzypop architecture

> Architecture diagram of the GitHub repository ishitasem/planzypop, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ishitasem/planzypop
- Repository: https://github.com/ishitasem/planzypop

## Overview

PlanzyPop is a student-focused event planning and budget-management application. Hosts use the React workspace to create and manage events, record and split expenses, track preparation tasks, and request rule-based planning suggestions; they can also discover and save nearby Chandigarh spots. The backend exposes FastAPI routes, validates requests, and persists event-related records and saved spots in SQLite, while spot discovery uses external place sources. The graph includes documented capabilities whose implementation was not sampled; dashed edges mark screen links that the README describes but the excerpts do not establish individually.

Main entry points: [`frontend/src/App.tsx`](https://github.com/ishitasem/planzypop/blob/master/frontend/src/App.tsx) (Workspace Router), [`frontend/src/services/api.ts`](https://github.com/ishitasem/planzypop/blob/master/frontend/src/services/api.ts) (Typed API Client), [`backend/main.py`](https://github.com/ishitasem/planzypop/blob/master/backend/main.py) (FastAPI Application), [`backend/database.py`](https://github.com/ishitasem/planzypop/blob/master/backend/database.py) (SQLite Store)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workspace["Planning Workspace"]
  node_app["Workspace Router<br/>[App.tsx]"]
  node_overview["Dashboard<br/>[Overview.tsx]"]
  node_events["Event Management<br/>[MyEvents.tsx]"]
  node_eventdetail["Event Details<br/>[EventDetail.tsx]"]
  node_budget["Budget &amp; Splits<br/>[Budget.tsx]"]
  node_checklist["Checklist Timeline<br/>[Checklist.tsx]"]
  node_planner["Planning Suggestions<br/>[Planner.tsx]"]
  node_profile["Host Preferences<br/>[Profile.tsx]"]
  node_settings["Settings<br/>[SettingsScreen.tsx]"]
end

subgraph group_api["Planning API"]
  node_api_client["Typed API Client<br/>[api.ts]"]
  node_main["FastAPI Application<br/>[main.py]"]
  node_event_routes["Event Routes<br/>[events.py]"]
  node_expense_routes["Expense Routes<br/>[expenses.py]"]
  node_task_routes["Task Routes<br/>[tasks.py]"]
  node_suggestion_routes["Suggestion Routes<br/>[suggestions.py]"]
  node_suggestion_engine["Rule Engine<br/>[suggestions.py]"]
  node_schemas["Validation Schemas<br/>[schemas.py]"]
  node_models["Relational Models<br/>[models.py]"]
  node_database[("SQLite Store<br/>[database.py]")]
end

subgraph group_nearby["Nearby Discovery"]
  node_nearby_page["Nearby Finder<br/>[Nearby.tsx]"]
  node_cafe_suggestions["Cafe Suggestions"]
  node_spot_map["Spot Map<br/>[SpotMap.tsx]"]
  node_spot_routes["Spot Routes<br/>[spots.py]"]
  node_spot_service["Spot Discovery Service<br/>[spots_service.py]"]
  node_geoapify["Geoapify Client<br/>[geoapify_client.py]"]
  node_boundary["Chandigarh Boundary"]
  node_food["Food Intelligence"]
end

subgraph group_shared["UI Foundation"]
  node_button["Button<br/>[Button.tsx]"]
  node_icon["Icon<br/>[Icon.tsx]"]
  node_icon_button["Icon Button<br/>[IconButton.tsx]"]
  node_header["Header<br/>[Header.tsx]"]
  node_formatters["Display Formatters<br/>[formatters.ts]"]
  node_progress["Progress Indicator<br/>[Progress.tsx]"]
end

node_host(("Host"))

node_host -->|"uses"| node_app
node_app -.->|"routes to"| node_overview
node_app -.->|"routes to"| node_events
node_app -.->|"routes to"| node_eventdetail
node_app -.->|"routes to"| node_budget
node_app -.->|"routes to"| node_checklist
node_app -.->|"routes to"| node_planner
node_app -.->|"routes to"| node_profile
node_app -.->|"routes to"| node_settings
node_app -.->|"routes to"| node_nearby_page
node_overview -->|"requests data"| node_api_client
node_events -->|"manages events"| node_api_client
node_eventdetail -->|"loads event"| node_api_client
node_budget -->|"tracks spending"| node_api_client
node_checklist -.->|"manages tasks"| node_api_client
node_planner -.->|"requests ideas"| node_api_client
node_api_client -->|"calls HTTP API"| node_main
node_main -->|"registers"| node_event_routes
node_main -->|"registers"| node_expense_routes
node_main -->|"registers"| node_task_routes
node_main -->|"registers"| node_suggestion_routes
node_main -->|"registers"| node_spot_routes
node_event_routes -->|"opens sessions"| node_database
node_expense_routes -->|"opens sessions"| node_database
node_task_routes -->|"opens sessions"| node_database
node_event_routes -->|"queries events"| node_models
node_expense_routes -->|"queries expenses"| node_models
node_task_routes -->|"queries tasks"| node_models
node_models -->|"maps through"| node_database
node_suggestion_routes -->|"delegates to"| node_suggestion_engine
node_suggestion_routes -->|"validates with"| node_schemas
node_nearby_page -.->|"searches spots"| node_api_client
node_nearby_page -.->|"shows suggestions"| node_cafe_suggestions
node_spot_routes -->|"searches through"| node_spot_service
node_spot_routes -->|"stores favorites"| node_database
node_spot_service -->|"uses provider"| node_geoapify
node_spot_service -->|"checks coordinates"| node_boundary
node_api_client -->|"calls spot endpoints"| node_spot_routes
node_button -->|"renders"| node_icon
node_icon_button -->|"renders"| node_icon
node_header -->|"uses"| node_icon_button
node_budget -->|"formats values"| node_formatters

click node_app "https://github.com/ishitasem/planzypop/blob/master/frontend/src/App.tsx"
click node_overview "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Overview.tsx"
click node_events "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/MyEvents.tsx"
click node_eventdetail "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/EventDetail.tsx"
click node_budget "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Budget.tsx"
click node_checklist "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Checklist.tsx"
click node_planner "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Planner.tsx"
click node_profile "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Profile.tsx"
click node_settings "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/SettingsScreen.tsx"
click node_api_client "https://github.com/ishitasem/planzypop/blob/master/frontend/src/services/api.ts"
click node_main "https://github.com/ishitasem/planzypop/blob/master/backend/main.py"
click node_event_routes "https://github.com/ishitasem/planzypop/blob/master/backend/routers/events.py"
click node_expense_routes "https://github.com/ishitasem/planzypop/blob/master/backend/routers/expenses.py"
click node_task_routes "https://github.com/ishitasem/planzypop/blob/master/backend/routers/tasks.py"
click node_suggestion_routes "https://github.com/ishitasem/planzypop/blob/master/backend/routers/suggestions.py"
click node_suggestion_engine "https://github.com/ishitasem/planzypop/blob/master/backend/suggestions.py"
click node_schemas "https://github.com/ishitasem/planzypop/blob/master/backend/schemas.py"
click node_models "https://github.com/ishitasem/planzypop/blob/master/backend/models.py"
click node_database "https://github.com/ishitasem/planzypop/blob/master/backend/database.py"
click node_nearby_page "https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Nearby.tsx"
click node_cafe_suggestions "https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/nearby/CafeSuggestions.tsx"
click node_spot_map "https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/nearby/SpotMap.tsx"
click node_spot_routes "https://github.com/ishitasem/planzypop/blob/master/backend/routers/spots.py"
click node_spot_service "https://github.com/ishitasem/planzypop/blob/master/backend/spots_service.py"
click node_geoapify "https://github.com/ishitasem/planzypop/blob/master/backend/geoapify_client.py"
click node_boundary "https://github.com/ishitasem/planzypop/blob/master/backend/chandigarh_boundary.py"
click node_food "https://github.com/ishitasem/planzypop/blob/master/backend/food_intelligence.py"
click node_button "https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/Button.tsx"
click node_icon "https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/Icon.tsx"
click node_icon_button "https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/IconButton.tsx"
click node_header "https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/Header.tsx"
click node_formatters "https://github.com/ishitasem/planzypop/blob/master/frontend/src/utils/formatters.ts"
click node_progress "https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/Progress.tsx"

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_overview,node_events,node_eventdetail,node_budget,node_checklist,node_planner,node_profile,node_settings toneBlue
class node_api_client,node_main,node_event_routes,node_expense_routes,node_task_routes,node_suggestion_routes,node_suggestion_engine,node_schemas,node_models,node_database toneAmber
class node_nearby_page,node_cafe_suggestions,node_spot_map,node_spot_routes,node_spot_service,node_geoapify,node_boundary,node_food toneMint
class node_button,node_icon,node_icon_button,node_header,node_formatters,node_progress toneRose
class node_host toneIndigo
```

## Components

### Planning Workspace

- [Workspace Router](https://github.com/ishitasem/planzypop/blob/master/frontend/src/App.tsx): `frontend/src/App.tsx`
- [Dashboard](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Overview.tsx): `frontend/src/pages/Overview.tsx`
- [Event Management](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/MyEvents.tsx): `frontend/src/pages/MyEvents.tsx`
- [Event Details](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/EventDetail.tsx): `frontend/src/pages/EventDetail.tsx`
- [Budget & Splits](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Budget.tsx): `frontend/src/pages/Budget.tsx`
- [Checklist Timeline](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Checklist.tsx): `frontend/src/pages/Checklist.tsx`
- [Planning Suggestions](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Planner.tsx): `frontend/src/pages/Planner.tsx`
- [Host Preferences](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Profile.tsx): `frontend/src/pages/Profile.tsx`
- [Settings](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/SettingsScreen.tsx): `frontend/src/pages/SettingsScreen.tsx`

### Planning API

- [Typed API Client](https://github.com/ishitasem/planzypop/blob/master/frontend/src/services/api.ts): `frontend/src/services/api.ts`
- [FastAPI Application](https://github.com/ishitasem/planzypop/blob/master/backend/main.py): `backend/main.py`
- [Event Routes](https://github.com/ishitasem/planzypop/blob/master/backend/routers/events.py): `backend/routers/events.py`
- [Expense Routes](https://github.com/ishitasem/planzypop/blob/master/backend/routers/expenses.py): `backend/routers/expenses.py`
- [Task Routes](https://github.com/ishitasem/planzypop/blob/master/backend/routers/tasks.py): `backend/routers/tasks.py`
- [Suggestion Routes](https://github.com/ishitasem/planzypop/blob/master/backend/routers/suggestions.py): `backend/routers/suggestions.py`
- [Rule Engine](https://github.com/ishitasem/planzypop/blob/master/backend/suggestions.py): `backend/suggestions.py`
- [Validation Schemas](https://github.com/ishitasem/planzypop/blob/master/backend/schemas.py): `backend/schemas.py`
- [Relational Models](https://github.com/ishitasem/planzypop/blob/master/backend/models.py): `backend/models.py`
- [SQLite Store](https://github.com/ishitasem/planzypop/blob/master/backend/database.py): `backend/database.py`

### Nearby Discovery

- [Nearby Finder](https://github.com/ishitasem/planzypop/blob/master/frontend/src/pages/Nearby.tsx): `frontend/src/pages/Nearby.tsx`
- [Cafe Suggestions](https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/nearby/CafeSuggestions.tsx): `frontend/src/components/nearby/CafeSuggestions.tsx`
- [Spot Map](https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/nearby/SpotMap.tsx): `frontend/src/components/nearby/SpotMap.tsx`
- [Spot Routes](https://github.com/ishitasem/planzypop/blob/master/backend/routers/spots.py): `backend/routers/spots.py`
- [Spot Discovery Service](https://github.com/ishitasem/planzypop/blob/master/backend/spots_service.py): `backend/spots_service.py`
- [Geoapify Client](https://github.com/ishitasem/planzypop/blob/master/backend/geoapify_client.py): `backend/geoapify_client.py`
- [Chandigarh Boundary](https://github.com/ishitasem/planzypop/blob/master/backend/chandigarh_boundary.py): `backend/chandigarh_boundary.py`
- [Food Intelligence](https://github.com/ishitasem/planzypop/blob/master/backend/food_intelligence.py): `backend/food_intelligence.py`

### UI Foundation

- [Button](https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/Button.tsx): `frontend/src/components/common/Button.tsx`
- [Icon](https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/Icon.tsx): `frontend/src/components/common/Icon.tsx`
- [Icon Button](https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/IconButton.tsx): `frontend/src/components/common/IconButton.tsx`
- [Header](https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/Header.tsx): `frontend/src/components/common/Header.tsx`
- [Display Formatters](https://github.com/ishitasem/planzypop/blob/master/frontend/src/utils/formatters.ts): `frontend/src/utils/formatters.ts`
- [Progress Indicator](https://github.com/ishitasem/planzypop/blob/master/frontend/src/components/common/Progress.tsx): `frontend/src/components/common/Progress.tsx`

### Other components

- **Host**

## Connections

- Host → Workspace Router: uses (evidence: `README.md`)
- Workspace Router → Dashboard: routes to
- Workspace Router → Event Management: routes to
- Workspace Router → Event Details: routes to
- Workspace Router → Budget & Splits: routes to
- Workspace Router → Checklist Timeline: routes to
- Workspace Router → Planning Suggestions: routes to
- Workspace Router → Host Preferences: routes to
- Workspace Router → Settings: routes to
- Workspace Router → Nearby Finder: routes to
- Dashboard → Typed API Client: requests data (evidence: `frontend/src/pages/Overview.tsx`)
- Event Management → Typed API Client: manages events (evidence: `frontend/src/pages/MyEvents.tsx`)
- Event Details → Typed API Client: loads event (evidence: `frontend/src/pages/EventDetail.tsx`)
- Budget & Splits → Typed API Client: tracks spending (evidence: `frontend/src/pages/Budget.tsx`)
- Checklist Timeline → Typed API Client: manages tasks
- Planning Suggestions → Typed API Client: requests ideas (evidence: `frontend/src/pages/Planner.tsx`)
- Typed API Client → FastAPI Application: calls HTTP API (evidence: `frontend/src/services/api.ts`)
- FastAPI Application → Event Routes: registers (evidence: `backend/main.py`)
- FastAPI Application → Expense Routes: registers (evidence: `backend/main.py`)
- FastAPI Application → Task Routes: registers (evidence: `backend/main.py`)
- FastAPI Application → Suggestion Routes: registers (evidence: `backend/main.py`)
- FastAPI Application → Spot Routes: registers (evidence: `backend/main.py`)
- Event Routes → SQLite Store: opens sessions (evidence: `backend/routers/events.py`)
- Expense Routes → SQLite Store: opens sessions (evidence: `backend/routers/expenses.py`)
- Task Routes → SQLite Store: opens sessions (evidence: `backend/routers/tasks.py`)
- Event Routes → Relational Models: queries events (evidence: `backend/routers/events.py`)
- Expense Routes → Relational Models: queries expenses (evidence: `backend/routers/expenses.py`)
- Task Routes → Relational Models: queries tasks (evidence: `backend/routers/tasks.py`)
- Relational Models → SQLite Store: maps through (evidence: `backend/models.py`)
- Suggestion Routes → Rule Engine: delegates to (evidence: `backend/routers/suggestions.py`)
- Suggestion Routes → Validation Schemas: validates with (evidence: `backend/routers/suggestions.py`)
- Nearby Finder → Typed API Client: searches spots
- Nearby Finder → Cafe Suggestions: shows suggestions
- Spot Routes → Spot Discovery Service: searches through (evidence: `backend/routers/spots.py`)
- Spot Routes → SQLite Store: stores favorites (evidence: `backend/routers/spots.py`)
- Spot Discovery Service → Geoapify Client: uses provider (evidence: `backend/geoapify_client.py`)
- Spot Discovery Service → Chandigarh Boundary: checks coordinates (evidence: `backend/spots_service.py`)
- Typed API Client → Spot Routes: calls spot endpoints (evidence: `frontend/src/services/api.ts`)
- Button → Icon: renders (evidence: `frontend/src/components/common/Button.tsx`)
- Icon Button → Icon: renders (evidence: `frontend/src/components/common/IconButton.tsx`)
- Header → Icon Button: uses (evidence: `frontend/src/components/common/Header.tsx`)
- Budget & Splits → Display Formatters: formats values (evidence: `frontend/src/pages/Budget.tsx`)
