# samanhoseinpour/perseus-creative-studio-v2 architecture

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

- Interactive diagram: https://gitdiagram.com/samanhoseinpour/perseus-creative-studio-v2
- Repository: https://github.com/samanhoseinpour/perseus-creative-studio-v2
- Video tour (about a minute): https://gitdiagram.com/samanhoseinpour/perseus-creative-studio-v2/video

## Overview

Perseus Creative Studio is a public marketing and publishing site paired with a private studio-operations dashboard. Visitors discover services, projects and blog content, search the site, or submit contact and career inquiries. Staff authenticate to administer content and run studio work—tasks, client reports, CRM, tickets, inboxes, payroll and monitoring. The README documents Neon/Drizzle persistence, cached public content, private uploads and scheduled jobs; sampled source confirms selected search, media-upload, SEO and cron flows, but not every action implementation.

Main entry points: [`src/app/(admin)/admin/(protected)/_actions`](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/_actions) (Admin actions), [`src/db`](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/db) (Neon Postgres), [`src/app/api/cron`](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/api/cron) (Scheduled jobs), [`src/app/(marketing)/contact`](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(marketing)/contact) (Contact and careers)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_public["Public site"]
  node_marketing["Marketing routes"]
  node_public_blog["Public blog"]
  node_contact["Contact and careers"]
  node_site_search["Site search"]
  node_seo_routes["SEO endpoints<br/>[route.ts]"]
end

subgraph group_admin["Admin access"]
  node_auth["Authentication<br/>[route.ts]"]
  node_protected_admin["Protected dashboard"]
  node_actions["Admin actions"]
end

subgraph group_studio["Studio work"]
  node_work_management["Tasks and projects"]
  node_crm["Client CRM"]
  node_reports["Client reports"]
  node_tickets_inbox["Tickets and inbox"]
  node_operations["Payroll and costs"]
  node_scheduled_jobs["Scheduled jobs"]
end

subgraph group_publishing["Publishing"]
  node_blog_admin["Blog editor"]
  node_portfolio_careers["Portfolio and careers"]
  node_seo_admin["SEO management"]
end

subgraph group_platform["Data and integrations"]
  node_database[("Neon Postgres")]
  node_blob[("Vercel Blob")]
  node_email["Resend email"]
end

node_visitors(("Site visitors"))
node_staff(("Studio staff"))

node_visitors -->|"browse"| node_marketing
node_visitors -->|"read posts"| node_public_blog
node_visitors -->|"submit inquiry"| node_contact
node_visitors -->|"search"| node_site_search
node_marketing -->|"read content"| node_database
node_public_blog -->|"read published posts"| node_database
node_contact -->|"save submissions"| node_database
node_contact -.->|"send notifications"| node_email
node_site_search -->|"searches index"| node_marketing
node_seo_routes -->|"read settings and blog index"| node_database
node_staff -->|"sign in"| node_auth
node_auth -->|"verify accounts"| node_database
node_staff -->|"use dashboard"| node_protected_admin
node_protected_admin -->|"invoke mutations"| node_actions
node_actions -->|"read and write"| node_database
node_actions -.->|"store uploaded media"| node_blob
node_work_management -->|"manage tasks and projects"| node_actions
node_crm -->|"manage relationships"| node_actions
node_reports -->|"manage reports and shares"| node_actions
node_tickets_inbox -->|"triage submissions"| node_actions
node_blog_admin -->|"edit and publish"| node_actions
node_portfolio_careers -->|"manage listings"| node_actions
node_seo_admin -->|"update SEO settings"| node_actions
node_operations -->|"manage payroll and costs"| node_actions
node_scheduled_jobs -->|"run scheduled updates"| node_database
node_scheduled_jobs -.->|"send scheduled mail"| node_email
node_scheduled_jobs -->|"invalidate published content"| node_public_blog

click node_marketing "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(marketing)"
click node_public_blog "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(marketing)/blogs"
click node_contact "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(marketing)/contact"
click node_site_search "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/components/SiteSearch"
click node_seo_routes "https://github.com/samanhoseinpour/perseus-creative-studio-v2/blob/main/src/app/llms.txt/route.ts"
click node_auth "https://github.com/samanhoseinpour/perseus-creative-studio-v2/blob/main/src/app/api/auth/%5B...all%5D/route.ts"
click node_protected_admin "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)"
click node_actions "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/_actions"
click node_work_management "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/tasks"
click node_crm "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/crm"
click node_reports "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/reports"
click node_tickets_inbox "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/tickets"
click node_blog_admin "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/blogs"
click node_portfolio_careers "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/projects"
click node_seo_admin "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/seo"
click node_operations "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/payroll"
click node_scheduled_jobs "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/api/cron"
click node_database "https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/db"

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_marketing,node_public_blog,node_contact,node_site_search,node_seo_routes toneBlue
class node_auth,node_protected_admin,node_actions toneAmber
class node_work_management,node_crm,node_reports,node_tickets_inbox,node_operations,node_scheduled_jobs toneMint
class node_blog_admin,node_portfolio_careers,node_seo_admin toneRose
class node_database,node_blob,node_email,node_visitors,node_staff toneIndigo
```

## Components

### Public site

- [Marketing routes](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(marketing)): `src/app/(marketing)`
- [Public blog](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(marketing)/blogs): `src/app/(marketing)/blogs`
- [Contact and careers](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(marketing)/contact): `src/app/(marketing)/contact`
- [Site search](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/components/SiteSearch): `src/components/SiteSearch`
- [SEO endpoints](https://github.com/samanhoseinpour/perseus-creative-studio-v2/blob/main/src/app/llms.txt/route.ts): `src/app/llms.txt/route.ts`

### Admin access

- [Authentication](https://github.com/samanhoseinpour/perseus-creative-studio-v2/blob/main/src/app/api/auth/%5B...all%5D/route.ts): `src/app/api/auth/[...all]/route.ts`
- [Protected dashboard](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)): `src/app/(admin)/admin/(protected)`
- [Admin actions](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/_actions): `src/app/(admin)/admin/(protected)/_actions`

### Studio work

- [Tasks and projects](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/tasks): `src/app/(admin)/admin/(protected)/tasks`
- [Client CRM](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/crm): `src/app/(admin)/admin/(protected)/crm`
- [Client reports](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/reports): `src/app/(admin)/admin/(protected)/reports`
- [Tickets and inbox](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/tickets): `src/app/(admin)/admin/(protected)/tickets`
- [Payroll and costs](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/payroll): `src/app/(admin)/admin/(protected)/payroll`
- [Scheduled jobs](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/api/cron): `src/app/api/cron`

### Publishing

- [Blog editor](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/blogs): `src/app/(admin)/admin/(protected)/blogs`
- [Portfolio and careers](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/projects): `src/app/(admin)/admin/(protected)/projects`
- [SEO management](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/app/(admin)/admin/(protected)/seo): `src/app/(admin)/admin/(protected)/seo`

### Data and integrations

- [Neon Postgres](https://github.com/samanhoseinpour/perseus-creative-studio-v2/tree/main/src/db): `src/db`
- **Vercel Blob**
- **Resend email**

### Other components

- **Site visitors**
- **Studio staff**

## Connections

- Site visitors → Marketing routes: browse
- Site visitors → Public blog: read posts
- Site visitors → Contact and careers: submit inquiry
- Site visitors → Site search: search
- Marketing routes → Neon Postgres: read content
- Public blog → Neon Postgres: read published posts
- Contact and careers → Neon Postgres: save submissions
- Contact and careers → Resend email: send notifications
- Site search → Marketing routes: searches index
- SEO endpoints → Neon Postgres: read settings and blog index
- Studio staff → Authentication: sign in
- Authentication → Neon Postgres: verify accounts
- Studio staff → Protected dashboard: use dashboard
- Protected dashboard → Admin actions: invoke mutations
- Admin actions → Neon Postgres: read and write
- Admin actions → Vercel Blob: store uploaded media
- Tasks and projects → Admin actions: manage tasks and projects
- Client CRM → Admin actions: manage relationships
- Client reports → Admin actions: manage reports and shares
- Tickets and inbox → Admin actions: triage submissions
- Blog editor → Admin actions: edit and publish
- Portfolio and careers → Admin actions: manage listings
- SEO management → Admin actions: update SEO settings
- Payroll and costs → Admin actions: manage payroll and costs
- Scheduled jobs → Neon Postgres: run scheduled updates
- Scheduled jobs → Resend email: send scheduled mail
- Scheduled jobs → Public blog: invalidate published content
