# vanshsuri07/indbyagent architecture

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

- Interactive diagram: https://gitdiagram.com/vanshsuri07/indbyagent
- Repository: https://github.com/vanshsuri07/indbyagent

## Overview

IndbyAgent is a Next.js app for agent-readable event invitations, guest actions, and person-to-person follow-up. Its main workflow is a guest or agent opening a token-scoped invite, then submitting an RSVP or poll response; hosts manage parties and planning, while separate meet-card and vendor-request flows extend the product. The graph preserves documented capabilities, but many host routes and core modules were not excerpted, so those connections are based on README statements rather than inspected implementations.

Main entry points: [`src/app/host/page.tsx`](https://github.com/vanshsuri07/indbyagent/blob/main/src/app/host/page.tsx) (Host board), [`src/app/m/[slug]/route.ts`](https://github.com/vanshsuri07/indbyagent/blob/main/src/app/m/%5Bslug%5D/route.ts) (Meet card routes), [`src/lib/vendors.ts`](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/vendors.ts) (Venue and vendor search), [`src/app/i/[token]/route.ts`](https://github.com/vanshsuri07/indbyagent/blob/main/src/app/i/%5Btoken%5D/route.ts) (Invite endpoints)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_guest["Guest invitations"]
  node_invite_api["Invite endpoints<br/>[route.ts]"]
  node_invite_domain["Invite and RSVP<br/>[invite.ts]"]
  node_invite_page["Invite rendering<br/>[invite-page.ts]"]
  node_guest_actions["RSVP and polls<br/>[route.ts]"]
  node_join_routes["Join links and QR<br/>[join.ts]"]
  node_join_page["Join screen<br/>[join-page.ts]"]
end

subgraph group_host["Host planning"]
  node_host_board["Host board<br/>[page.tsx]"]
  node_host_party_api["Party management API"]
  node_planner["Planning chat<br/>[planner.ts]"]
  node_mail_inbound["Email reply parsing<br/>[inbound.ts]"]
end

subgraph group_meet["Meet cards"]
  node_meet_routes["Meet card routes<br/>[route.ts]"]
  node_meet_domain["Meet cards and context<br/>[meet.ts]"]
  node_meet_page["Meet page and QR<br/>[meet-page.ts]"]
  node_meet_mail["Meet intro email<br/>[meet-mail.ts]"]
end

subgraph group_vendor["Venue and vendors"]
  node_vendor_public["Vendor request routes<br/>[route.ts]"]
  node_vendor_request["Vendor request workflow<br/>[vendor-requests.ts]"]
  node_vendor_page["Vendor request page<br/>[vendor-page.ts]"]
  node_venue_search["Venue and vendor search<br/>[vendors.ts]"]
end

subgraph group_platform["Shared services"]
  node_supabase[("Supabase party data<br/>[db.ts]")]
  node_neon[("Neon vendor data<br/>[neon.ts]")]
  node_shared_http["HTTP and validation<br/>[http.ts]"]
end

node_guest_actor(("Guest or agent"))
node_host_actor(("Host"))
node_agentmail["AgentMail"]
node_claude["Claude"]

node_guest_actor -->|"opens invite"| node_invite_api
node_invite_api -.->|"loads invite"| node_invite_domain
node_invite_api -.->|"renders page"| node_invite_page
node_guest_actor -->|"submits RSVP or poll"| node_guest_actions
node_guest_actions -->|"writes response"| node_invite_domain
node_guest_actor -->|"joins party"| node_join_routes
node_join_routes -->|"renders QR screen"| node_join_page
node_host_actor -->|"manages party"| node_host_board
node_host_board -.->|"uses host API"| node_host_party_api
node_host_board -->|"plans party"| node_planner
node_host_board -->|"starts venue search"| node_venue_search
node_agentmail -->|"delivers replies"| node_mail_inbound
node_mail_inbound -.->|"records parsed activity"| node_supabase
node_guest_actor -->|"opens card or drops contact"| node_meet_routes
node_meet_routes -->|"loads and creates meet"| node_meet_domain
node_meet_routes -->|"renders card and QR"| node_meet_page
node_meet_routes -->|"sends intro"| node_meet_mail
node_meet_mail -.->|"sends email"| node_agentmail
node_guest_actor -->|"answers vendor request"| node_vendor_public
node_vendor_public -->|"loads or writes request"| node_vendor_request
node_vendor_public -->|"renders request"| node_vendor_page
node_host_board -.->|"manages requests"| node_vendor_request
node_host_board -->|"reviews suggestions"| node_venue_search
node_venue_search -->|"searches venues"| node_claude
node_venue_search -->|"stores suggestions"| node_neon
node_vendor_request -->|"stores requests"| node_neon
node_invite_domain -.->|"stores party state"| node_supabase
node_shared_http -->|"validates requests"| node_guest_actions

click node_invite_api "https://github.com/vanshsuri07/indbyagent/blob/main/src/app/i/%5Btoken%5D/route.ts"
click node_invite_domain "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/invite.ts"
click node_invite_page "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/invite-page.ts"
click node_guest_actions "https://github.com/vanshsuri07/indbyagent/blob/main/src/app/i/%5Btoken%5D/rsvp/route.ts"
click node_join_routes "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/join.ts"
click node_join_page "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/join-page.ts"
click node_host_board "https://github.com/vanshsuri07/indbyagent/blob/main/src/app/host/page.tsx"
click node_host_party_api "https://github.com/vanshsuri07/indbyagent/tree/main/src/app/api/host/parties"
click node_planner "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/planner.ts"
click node_mail_inbound "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/inbound.ts"
click node_meet_routes "https://github.com/vanshsuri07/indbyagent/blob/main/src/app/m/%5Bslug%5D/route.ts"
click node_meet_domain "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/meet.ts"
click node_meet_page "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/meet-page.ts"
click node_meet_mail "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/meet-mail.ts"
click node_vendor_public "https://github.com/vanshsuri07/indbyagent/blob/main/src/app/v/%5Btoken%5D/route.ts"
click node_vendor_request "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/vendor-requests.ts"
click node_vendor_page "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/vendor-page.ts"
click node_venue_search "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/vendors.ts"
click node_supabase "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/db.ts"
click node_neon "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/neon.ts"
click node_shared_http "https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/http.ts"

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_invite_api,node_invite_domain,node_invite_page,node_guest_actions,node_join_routes,node_join_page toneBlue
class node_host_board,node_host_party_api,node_planner,node_mail_inbound toneAmber
class node_meet_routes,node_meet_domain,node_meet_page,node_meet_mail toneMint
class node_vendor_public,node_vendor_request,node_vendor_page,node_venue_search toneRose
class node_supabase,node_neon,node_shared_http,node_guest_actor,node_host_actor,node_agentmail,node_claude toneIndigo
```

## Components

### Guest invitations

- [Invite endpoints](https://github.com/vanshsuri07/indbyagent/blob/main/src/app/i/%5Btoken%5D/route.ts): `src/app/i/[token]/route.ts`
- [Invite and RSVP](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/invite.ts): `src/lib/invite.ts`
- [Invite rendering](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/invite-page.ts): `src/lib/invite-page.ts`
- [RSVP and polls](https://github.com/vanshsuri07/indbyagent/blob/main/src/app/i/%5Btoken%5D/rsvp/route.ts): `src/app/i/[token]/rsvp/route.ts`
- [Join links and QR](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/join.ts): `src/lib/join.ts`
- [Join screen](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/join-page.ts): `src/lib/join-page.ts`

### Host planning

- [Host board](https://github.com/vanshsuri07/indbyagent/blob/main/src/app/host/page.tsx): `src/app/host/page.tsx`
- [Party management API](https://github.com/vanshsuri07/indbyagent/tree/main/src/app/api/host/parties): `src/app/api/host/parties`
- [Planning chat](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/planner.ts): `src/lib/planner.ts`
- [Email reply parsing](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/inbound.ts): `src/lib/inbound.ts`

### Meet cards

- [Meet card routes](https://github.com/vanshsuri07/indbyagent/blob/main/src/app/m/%5Bslug%5D/route.ts): `src/app/m/[slug]/route.ts`
- [Meet cards and context](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/meet.ts): `src/lib/meet.ts`
- [Meet page and QR](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/meet-page.ts): `src/lib/meet-page.ts`
- [Meet intro email](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/meet-mail.ts): `src/lib/meet-mail.ts`

### Venue and vendors

- [Vendor request routes](https://github.com/vanshsuri07/indbyagent/blob/main/src/app/v/%5Btoken%5D/route.ts): `src/app/v/[token]/route.ts`
- [Vendor request workflow](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/vendor-requests.ts): `src/lib/vendor-requests.ts`
- [Vendor request page](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/vendor-page.ts): `src/lib/vendor-page.ts`
- [Venue and vendor search](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/vendors.ts): `src/lib/vendors.ts`

### Shared services

- [Supabase party data](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/db.ts): `src/lib/db.ts`
- [Neon vendor data](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/neon.ts): `src/lib/neon.ts`
- [HTTP and validation](https://github.com/vanshsuri07/indbyagent/blob/main/src/lib/http.ts): `src/lib/http.ts`

### Other components

- **Guest or agent**
- **Host**
- **AgentMail**
- **Claude**

## Connections

- Guest or agent → Invite endpoints: opens invite (evidence: `README.md`)
- Invite endpoints → Invite and RSVP: loads invite
- Invite endpoints → Invite rendering: renders page
- Guest or agent → RSVP and polls: submits RSVP or poll (evidence: `README.md`)
- RSVP and polls → Invite and RSVP: writes response (evidence: `src/app/i/[token]/rsvp/route.ts`)
- Guest or agent → Join links and QR: joins party (evidence: `README.md`)
- Join links and QR → Join screen: renders QR screen (evidence: `src/app/q/[code]/route.ts`)
- Host → Host board: manages party (evidence: `README.md`)
- Host board → Party management API: uses host API
- Host board → Planning chat: plans party (evidence: `README.md`)
- Host board → Venue and vendor search: starts venue search (evidence: `README.md`)
- AgentMail → Email reply parsing: delivers replies (evidence: `README.md`)
- Email reply parsing → Supabase party data: records parsed activity
- Guest or agent → Meet card routes: opens card or drops contact (evidence: `README.md`)
- Meet card routes → Meet cards and context: loads and creates meet (evidence: `src/app/m/[slug]/route.ts`)
- Meet card routes → Meet page and QR: renders card and QR (evidence: `src/app/m/[slug]/route.ts`)
- Meet card routes → Meet intro email: sends intro
- Meet intro email → AgentMail: sends email
- Guest or agent → Vendor request routes: answers vendor request (evidence: `README.md`)
- Vendor request routes → Vendor request workflow: loads or writes request (evidence: `src/app/v/[token]/route.ts`)
- Vendor request routes → Vendor request page: renders request (evidence: `src/app/v/[token]/route.ts`)
- Host board → Vendor request workflow: manages requests
- Host board → Venue and vendor search: reviews suggestions (evidence: `README.md`)
- Venue and vendor search → Claude: searches venues (evidence: `README.md`)
- Venue and vendor search → Neon vendor data: stores suggestions (evidence: `src/lib/vendors.ts`)
- Vendor request workflow → Neon vendor data: stores requests (evidence: `src/lib/vendor-requests.ts`)
- Invite and RSVP → Supabase party data: stores party state
- HTTP and validation → RSVP and polls: validates requests (evidence: `src/app/i/[token]/rsvp/route.ts`)
