Architecture: Queens EYBL Tournament Email (#48)

arch-eybl-email Architecture

architecture active sprint:2

Architecture: Queens EYBL Tournament Email (#48)

Purpose

Send a branded email to parents with Queens EYBL Live Period tournament registration and travel details. This is a one-time blast email — not a recurring workflow. Follows sop-email-send approval gates. Blocked on #47 — requires ActionMailer infrastructure to be in place first.

Diagram

Components

Component Purpose Notes
ActionMailer mailer TournamentMailer class (from #47 infrastructure) Depends on #47 spike completing and ActionMailer being wired up
Layout <code>announcement</code> — multi-section rich content Registration details, travel logistics, schedule — too much for <code>action</code> layout
Audience query Parents of players on teams attending EYBL Scope or ActiveRecord query — determined by #47 spike output
EmailType New enum or mailer action: <code>tournament_info</code> or similar Rails convention: one mailer action per email type
Content sections Tournament dates, venue, registration link, travel info, costs Marcus provides details; Lucas/agent drafts email copy
CTA Registration link or RSVP action Optional — depends on whether registration is external or internal

Dependency: #47 ActionMailer Spike

This ticket is the first consumer of the ActionMailer infrastructure set up by #47. It cannot start until #47 delivers:
  • Gmail API delivery adapter configured and tested
  • OAuth token integration working in Rails
  • Base mailer class with brand styling
  • Template strategy decided (MJML-rails or ERB)

Key Decisions

  • Uses new Rails ActionMailer — this is the first real email sent through the #47 infrastructure, not the old basketball-api Python path.
  • Announcement layout — tournament details need multiple sections (dates, travel, costs, registration), which fits announcement, not action.
  • Marcus is the content source — agent drafts, Lucas approves. Standard sop-email-send flow.
  • One-time blast — no automation or recurring send. Compose → approve → send → done.
  • arch-actionmailer-westside-basketball — prerequisite: ActionMailer spike (#47)
  • arch-email — legacy email system architecture (basketball-api / Python)
  • sop-email-send — email send approval workflow (the process this follows)
  • arch-domain-westside-basketball — domain model (Parent, Player, Team, EmailLog)
  • Forgejo: westside-basketball #48