How hoagieclub/mail works
Hoagie Mail is a web app for authenticated campus-wide email, with separate flows for direct sending, scheduled sending, and messages submitted to a recurring digest. The frontend proxies authenticated API requests to the Hoagie API; backend modules cover authentication, mail and digest operations, and email-provider support. The README documents listserv delivery and Auth0/CAS authentication. Source excerpts confirm the proxy and authentication behavior, but not the backend endpoint-to-provider wiring, so those links are omitted.
Main entry points: route.ts API proxy · index.tsx Mail form selector · SendForm.tsx Direct send form · auth.py JWT authentication
Components 22
Web app
- Home and login
app/page.tsx - Mail workspace
app/app/page.tsx - Mail form selector
components/MailForm/index.tsx - Direct send form
components/MailForm/SendForm.tsx - Message editor
components/Editor.tsx - Scheduled send
components/MailForm/ScheduledSend/ScheduledMailForm.tsx - Digest submission
components/MailForm/DigestForm/index.tsx - API proxy
app/api/hoagie/[...path]/route.ts - Auth controls
lib/hoagie-ui/AuthButton/index.tsx
Mail backend
- Backend API
backend/hoagiemail/api - Mail endpoint
backend/hoagiemail/api/mail_view.py - Digest posts
backend/hoagiemail/api/stuff_posts_view.py - Digest user data
backend/hoagiemail/api/stuff_user_view.py - User records
backend/hoagiemail/models/user.py - Mail records
backend/hoagiemail/models/mail.py - Digest records
backend/hoagiemail/models/stuff.py - Mail provider client
backend/hoagiemail/email/mailjet_client.py
Authentication
- JWT authentication
backend/hoagiemail/api/auth/auth.py
External services
- Auth0 / CAS
- Hoagie API
- Campus listservs
Other components
- Email sender
Connections 18
- Email sender → Home and login: opens
- Home and login → Auth controls: offers login
- Email sender → Mail workspace: opens
- Mail workspace → Mail form selector: renders
- Mail form selector → Direct send form: selects direct
- Mail form selector → Digest submission: selects digest
- Direct send form → Message editor: composes in
- Direct send form → API proxy: submits via
- Scheduled send → API proxy: submits via
- Digest submission → API proxy: submits via
- API proxy → Auth0 / CAS: gets access token
- API proxy → Hoagie API: forwards request
- Hoagie API → Backend API: routes requests
- Backend API → JWT authentication: authenticates with
- JWT authentication → Auth0 / CAS: verifies JWT
- JWT authentication → User records: gets or creates
- Mail endpoint → Mail records
- Digest posts → Digest records