# karthikeyavb/spotlytt architecture

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

- Interactive diagram: https://gitdiagram.com/karthikeyavb/spotlytt
- Repository: https://github.com/karthikeyavb/spotlytt

## Overview

Spotlight is a professional skills and networking application: users register and verify accounts, build profiles and connections, share skill media, and interact through jobs and messaging. The React app routes those experiences to an Express API, whose controllers access Supabase; sampled post and user controllers also create notifications. Admin pages provide dashboards and media review. The README is only a Vite template, so product capabilities are inferred from the route tree and sampled code; wiring for unsampled routes and controllers is left out.

Main entry points: [`server/server.js`](https://github.com/karthikeyavb/spotlytt/blob/main/server/server.js) (HTTP and socket server), [`src/App.jsx`](https://github.com/karthikeyavb/spotlytt/blob/main/src/App.jsx) (Route shell), [`src/services/api.js`](https://github.com/karthikeyavb/spotlytt/blob/main/src/services/api.js) (API client), [`server/config/supabase.js`](https://github.com/karthikeyavb/spotlytt/blob/main/server/config/supabase.js) (Supabase client)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Web experience"]
  node_app["Route shell<br/>[App.jsx]"]
  node_auth["Account access<br/>[AuthPage.jsx]"]
  node_feed["Skill feed<br/>[SkillFeed.jsx]"]
  node_profile["Profiles and people<br/>[ProfilePage.jsx]"]
  node_jobs["Jobs<br/>[JobPage.jsx]"]
  node_messages["Messaging<br/>[MessagePage.jsx]"]
  node_api_client["API client<br/>[api.js]"]
end

subgraph group_server["API services"]
  node_api_server["HTTP and socket server<br/>[server.js]"]
  node_auth_routes["Auth routes<br/>[auth.js]"]
  node_post_routes["Post routes<br/>[posts.js]"]
  node_user_routes["User routes<br/>[users.js]"]
  node_job_routes["Job routes<br/>[jobs.js]"]
  node_message_routes["Message routes<br/>[messages.js]"]
  node_auth_controller["Authentication<br/>[authController.js]"]
  node_post_controller["Posts and comments<br/>[postController.js]"]
  node_user_controller["Profiles and follows<br/>[userController.js]"]
end

subgraph group_data["Persistence"]
  node_supabase_config["Supabase client<br/>[supabase.js]"]
  node_supabase[("Supabase data and media")]
end

subgraph group_realtime["Notifications and realtime"]
  node_notification_controller["Notification dispatch"]
  node_socket["Live connections<br/>[server.js]"]
end

subgraph group_admin["Administration"]
  node_admin_pages["Admin dashboards"]
  node_content_review["Media review"]
  node_admin_client["Admin API client<br/>[adminApi.js]"]
  node_admin_routes["Admin routes<br/>[admin.js]"]
  node_admin_controller["Admin operations<br/>[adminController.js]"]
end

node_user(("Visitor or member"))
node_smtp["Email service"]

node_user -->|"uses"| node_app
node_app -->|"routes to"| node_auth
node_app -->|"routes to"| node_feed
node_app -->|"routes to"| node_profile
node_app -->|"routes to"| node_jobs
node_app -->|"routes to"| node_messages
node_auth -->|"requests"| node_api_client
node_feed -->|"requests"| node_api_client
node_profile -->|"requests"| node_api_client
node_jobs -->|"requests"| node_api_client
node_messages -->|"requests"| node_api_client
node_api_client -->|"sends API calls"| node_api_server
node_api_server -->|"mounts"| node_auth_routes
node_api_server -->|"mounts"| node_post_routes
node_api_server -->|"mounts"| node_user_routes
node_api_server -->|"mounts"| node_job_routes
node_api_server -->|"mounts"| node_message_routes
node_auth_controller -->|"reads and writes"| node_supabase_config
node_auth_controller -->|"sends verification email"| node_smtp
node_post_controller -->|"reads and writes"| node_supabase_config
node_user_controller -->|"reads and writes"| node_supabase_config
node_supabase_config -->|"connects"| node_supabase
node_post_controller -->|"creates notifications"| node_notification_controller
node_user_controller -->|"creates notifications"| node_notification_controller
node_notification_controller -->|"persists notifications"| node_supabase_config
node_notification_controller -->|"emits events"| node_socket
node_admin_pages -->|"requests"| node_admin_client
node_content_review -->|"reviews content"| node_admin_client
node_admin_client -->|"sends API calls"| node_api_server
node_api_server -->|"mounts"| node_admin_routes
node_admin_controller -->|"reads and writes"| node_supabase_config

click node_app "https://github.com/karthikeyavb/spotlytt/blob/main/src/App.jsx"
click node_auth "https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/AuthPage.jsx"
click node_feed "https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/SkillFeed.jsx"
click node_profile "https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/ProfilePage.jsx"
click node_jobs "https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/JobPage.jsx"
click node_messages "https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/MessagePage.jsx"
click node_api_client "https://github.com/karthikeyavb/spotlytt/blob/main/src/services/api.js"
click node_api_server "https://github.com/karthikeyavb/spotlytt/blob/main/server/server.js"
click node_auth_routes "https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/auth.js"
click node_post_routes "https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/posts.js"
click node_user_routes "https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/users.js"
click node_job_routes "https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/jobs.js"
click node_message_routes "https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/messages.js"
click node_auth_controller "https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/authController.js"
click node_post_controller "https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/postController.js"
click node_user_controller "https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/userController.js"
click node_supabase_config "https://github.com/karthikeyavb/spotlytt/blob/main/server/config/supabase.js"
click node_notification_controller "https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/notificationController.js"
click node_socket "https://github.com/karthikeyavb/spotlytt/blob/main/server/server.js"
click node_admin_pages "https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/admin/AdminLaunchDashboard.jsx"
click node_content_review "https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/admin/AdminContentReview.jsx"
click node_admin_client "https://github.com/karthikeyavb/spotlytt/blob/main/src/services/adminApi.js"
click node_admin_routes "https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/admin.js"
click node_admin_controller "https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/adminController.js"

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_auth,node_feed,node_profile,node_jobs,node_messages,node_api_client toneBlue
class node_api_server,node_auth_routes,node_post_routes,node_user_routes,node_job_routes,node_message_routes,node_auth_controller,node_post_controller,node_user_controller toneAmber
class node_supabase_config,node_supabase toneMint
class node_notification_controller,node_socket toneRose
class node_admin_pages,node_content_review,node_admin_client,node_admin_routes,node_admin_controller,node_user,node_smtp toneIndigo
```

## Components

### Web experience

- [Route shell](https://github.com/karthikeyavb/spotlytt/blob/main/src/App.jsx): `src/App.jsx`
- [Account access](https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/AuthPage.jsx): `src/pages/AuthPage.jsx`
- [Skill feed](https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/SkillFeed.jsx): `src/pages/SkillFeed.jsx`
- [Profiles and people](https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/ProfilePage.jsx): `src/pages/ProfilePage.jsx`
- [Jobs](https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/JobPage.jsx): `src/pages/JobPage.jsx`
- [Messaging](https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/MessagePage.jsx): `src/pages/MessagePage.jsx`
- [API client](https://github.com/karthikeyavb/spotlytt/blob/main/src/services/api.js): `src/services/api.js`

### API services

- [HTTP and socket server](https://github.com/karthikeyavb/spotlytt/blob/main/server/server.js): `server/server.js`
- [Auth routes](https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/auth.js): `server/routes/auth.js`
- [Post routes](https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/posts.js): `server/routes/posts.js`
- [User routes](https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/users.js): `server/routes/users.js`
- [Job routes](https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/jobs.js): `server/routes/jobs.js`
- [Message routes](https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/messages.js): `server/routes/messages.js`
- [Authentication](https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/authController.js): `server/controllers/authController.js`
- [Posts and comments](https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/postController.js): `server/controllers/postController.js`
- [Profiles and follows](https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/userController.js): `server/controllers/userController.js`

### Persistence

- [Supabase client](https://github.com/karthikeyavb/spotlytt/blob/main/server/config/supabase.js): `server/config/supabase.js`
- **Supabase data and media**

### Notifications and realtime

- [Notification dispatch](https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/notificationController.js): `server/controllers/notificationController.js`
- [Live connections](https://github.com/karthikeyavb/spotlytt/blob/main/server/server.js): `server/server.js`

### Administration

- [Admin dashboards](https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/admin/AdminLaunchDashboard.jsx): `src/pages/admin/AdminLaunchDashboard.jsx`
- [Media review](https://github.com/karthikeyavb/spotlytt/blob/main/src/pages/admin/AdminContentReview.jsx): `src/pages/admin/AdminContentReview.jsx`
- [Admin API client](https://github.com/karthikeyavb/spotlytt/blob/main/src/services/adminApi.js): `src/services/adminApi.js`
- [Admin routes](https://github.com/karthikeyavb/spotlytt/blob/main/server/routes/admin.js): `server/routes/admin.js`
- [Admin operations](https://github.com/karthikeyavb/spotlytt/blob/main/server/controllers/adminController.js): `server/controllers/adminController.js`

### Other components

- **Visitor or member**
- **Email service**

## Connections

- Visitor or member → Route shell: uses
- Route shell → Account access: routes to
- Route shell → Skill feed: routes to
- Route shell → Profiles and people: routes to
- Route shell → Jobs: routes to
- Route shell → Messaging: routes to
- Account access → API client: requests
- Skill feed → API client: requests
- Profiles and people → API client: requests
- Jobs → API client: requests
- Messaging → API client: requests
- API client → HTTP and socket server: sends API calls
- HTTP and socket server → Auth routes: mounts
- HTTP and socket server → Post routes: mounts
- HTTP and socket server → User routes: mounts
- HTTP and socket server → Job routes: mounts
- HTTP and socket server → Message routes: mounts
- Authentication → Supabase client: reads and writes
- Authentication → Email service: sends verification email
- Posts and comments → Supabase client: reads and writes
- Profiles and follows → Supabase client: reads and writes
- Supabase client → Supabase data and media: connects
- Posts and comments → Notification dispatch: creates notifications
- Profiles and follows → Notification dispatch: creates notifications
- Notification dispatch → Supabase client: persists notifications
- Notification dispatch → Live connections: emits events
- Admin dashboards → Admin API client: requests
- Media review → Admin API client: reviews content
- Admin API client → HTTP and socket server: sends API calls
- HTTP and socket server → Admin routes: mounts
- Admin operations → Supabase client: reads and writes
