How voidqn/gspen-hub works
GSPen Hub is a multi-workspace business app spanning contact data and CRM, campaign outreach, connected mail, project management, and a separately deployable email verifier. The main outreach path is campaign setup and recipient selection, followed by assignment and message composition, then queued sending; the sampled pipeline directly supports the assignment/composition stage. Invoice Ninja webhooks feed CRM ingestion, and unsubscribe links let recipients change suppression state. The README is only the stock Next.js starter, so product capabilities and wiring are inferred from the repository tree and sampled source; unsampled links are omitted.
Main entry points: db.ts PostgreSQL · pipeline.ts Assign and compose · mail Mail sync and replies · campaigns Campaign workspace
Components 27
Hub application
- Workspace UI
src/app/(app) - Sessions and access
src/lib/auth - Project management
src/app/(app)/project-management
Contacts and CRM
- Contact database
src/app/(app)/database - Import and tables
src/lib/database - CRM review
src/app/(app)/crm - Invoice ingestion
src/lib/crm/ingest.ts
Campaign outreach
- Campaign workspace
src/app/(app)/email/campaigns - Audience segments
src/lib/segments - Assign and compose
src/lib/outreach/pipeline.ts - Send queue
src/lib/outreach/sender.ts - Sender worker
scripts/sender.ts
Mail operations
- Inbox and reports
src/app/(app)/email - Mail sync and replies
src/lib/mail - Mail sync job
scripts/mail-sync.ts - Unsubscribe handler
src/app/unsubscribe/[token]/route.ts
Email verification
- Verifier tools
src/app/(app)/email/verifier/page.tsx - Verifier API routes
src/app/api/verifier - Verifier client
src/lib/verifier/proxy.ts - Verifier HTTP service
services/verifier/api/main.py - Probe and generate
services/verifier/core
Other components
- Hub user
- Invoice Ninja webhook
src/app/api/webhooks/invoice-ninja/route.ts - PostgreSQL
src/db/db.ts - Gmail
- Recipient mail servers
- Invoice Ninja
Connections 23
- Hub user → Workspace UI: uses
- Workspace UI → Sessions and access: checks access
- Contact database → Import and tables: imports and edits
- Import and tables → PostgreSQL: reads and writes
- CRM review → PostgreSQL: loads CRM data
- Invoice Ninja → Invoice Ninja webhook: posts events
- Invoice Ninja webhook → Invoice ingestion: ingests payload
- Invoice ingestion → PostgreSQL: stores and matches
- Campaign workspace → Audience segments: configures audience
- Campaign workspace → Assign and compose: starts campaign
- Assign and compose → PostgreSQL: loads and updates
- Assign and compose → Send queue: composes messages
- Sender worker → Send queue: processes sends
- Inbox and reports → Mail sync and replies: manages conversations
- Mail sync and replies → Gmail: syncs and replies
- Mail sync job → Mail sync and replies: runs sync
- Unsubscribe handler → PostgreSQL: updates suppression
- Verifier tools → Verifier API routes: requests checks
- Verifier API routes → Verifier client: proxies requests
- Verifier client → Verifier HTTP service: calls API
- Verifier HTTP service → Probe and generate: runs verification
- Probe and generate → Recipient mail servers: probes MX hosts
- Hub user → Project management: manages projects