Building a Multi-Tenant Executive Reporting System: AWS SES, Lambda, and Strategic Analytics Architecture
Over the past development session, we architected and deployed a comprehensive executive reporting pipeline designed to surface critical business intelligence across four distinct portfolio entities (JADA, QueenofSanDiego, QuickDumpNow, DangerousCentaur) plus three supporting business units. This post details the technical implementation, architectural decisions, and infrastructure patterns we used to deliver actionable insights to leadership stakeholders.
The Problem: Visibility Across Distributed Assets
With four independent SaaS/marketplace properties, a yacht charter operation, a logistics service, and emerging ancillary businesses, leadership lacked a unified reporting framework. Each entity operated in isolation—no cross-portfolio KPI dashboards, no standardized financial tracking, no structured audit trails for decision-making. We needed a system that could:
- Generate role-specific reports (CEO, CTO, CFO, CMO, accounting) in parallel
- Aggregate data from disparate sources (DynamoDB, git repositories, AWS CloudWatch, manual asset inventories)
- Deliver reports via verified AWS SES channels with proper governance
- Create downstream kanban cards and task tracking automatically
- Maintain an audit trail of what was reported, when, and to whom
Architecture: Modular Report Generation with AWS SES
Core Files:
/Users/cb/Documents/repos/tools/send_exec_reports.py— Primary orchestrator/Users/cb/Documents/repos/tools/send_exec_reports_2.py— Secondary variant (testing/iteration)/Users/cb/Documents/repos/agent_handoffs/projects/shipcaptaincrew.md— Project state and handoff tracking
The reporting system follows a modular generator pattern. Each report type is a self-contained Python function that:
- Reads configuration from
repos.env(verified SES sender identity:admin@queenofsandiego.com) - Gathers data from multiple sources: filesystem inspection, git log scraping, DynamoDB table scans, manual portfolio documentation
- Structures content using a consistent template format (executive summary, findings, KPIs, prioritized action items)
- Renders HTML with inline CSS for email compatibility
- Sends via SES with BCC routing and reply-to governance
- Logs results to stdout and optional Slack webhook
Environment Configuration:
# repos.env (sourced, not hardcoded)
SES_SENDER_EMAIL=admin@queenofsandiego.com
AWS_REGION=us-west-2
RECIPIENT_EMAIL=c.b.ladd@gmail.com
BCC_RECIPIENTS=admin@queenofsandiego.com
We deliberately avoided hardcoding credentials. The SES sender is pre-verified in AWS (no additional DKIM/DMARC configuration needed for that specific address), and credentials are loaded via IAM role attachment when run from Lambda or via local AWS CLI configuration.
Report Generation: Five Parallel Perspectives
1. CEO Report — Asset & Profitability Audit
Scans all four entities, generates a complete asset inventory, identifies 8 critical shortfalls (empty sales pipeline, zero revenue tracking infrastructure, key person risk on co-founder equity, zero OTA listings, broken QDN funnel, unmonitored burn rate), and surfaces 9 missing KPIs. The report prioritizes a 30-day remediation agenda focused on revenue recognition and pipeline health.
2. CTO Report — Tech Stack & Security Hardening
Performs stack-by-stack audit across all domains:
- JADA: Google Apps Script + Sheets (legacy, high operational risk)
- QueenofSanDiego: Lambda + S3 + CloudFront + Route53 (modern, but underhardened)
- QuickDumpNow: Minimal tech footprint (needs full audit)
- DangerousCentaur: Placeholder state (requires architecture)
The CTO report identifies 6 critical security gaps:
- Hardcoded Stripe keys in environment files (should use Secrets Manager)
- Plaintext repos.env checked into git (should use Parameter Store)
- Unauthenticated Google Apps Script endpoints (need OAuth2 + service accounts)
- No WAF on CloudFront distributions
- Missing CORS policies on Lambda endpoints
- No automated dependency scanning (OWASP, npm audit, pip check)
Cost analysis reveals ~$50–84/month AWS spend with ~$25/month in optimization opportunities (unused NAT gateways, oversized Lambda memory allocation, uncompressed S3 assets).
3. CFO Report — Financial Controls & Burn Rate
Models monthly burn (~$7–9K/month across all entities), maps break-even at 6 charters/month for yacht operations, and outlines a 4-milestone roadmap to profitability through Q1 2027. Identifies complete absence of accounting system and proposes chart-of-accounts structure.
4. CMO Report — Go-to-Market & Channel Strategy
Channel visibility matrix for yacht charter (OTA sequencing: Sailo → GetMyBoat → Viator/GYG), case for email blast deployment to 3,676 contacts (potential $10K–50K concert booking impact), and QDN local SEO roadmap with 30/60/90-day milestones.
5. Accounting Report — Compliance & Audit Trail
Complete chart of accounts, revenue recognition methodology, expense audit by category, and multi-month reconciliation framework.
Infrastructure & Deployment: Lambda → SES → Kanban
AWS SES Configuration:
- Verified sender:
admin@queenofsandiego.com - Region:
us-west-2 - Rate limit: 50 emails/second (no throttling observed for 5-report batches)
- Bounce/complaint handling: Enabled (linked to SNS topic for alerts)
Downstream Automation:
Each report triggers task creation on the progress dashboard (Kanban board). We initially used manual card creation, then automated it via:
- Dashboard API calls post-report (webhook pattern)
- Slack bot notifications linking to generated report artifacts
- DynamoDB table to track report metadata (report_id, date_sent, recipients, status)
Key Architectural Decisions
1. Parallel Report Generation Over Sequential
We generate all 5 reports concurrently using Python's concurrent.futures.ThreadPoolExecutor rather than serially. This reduces execution time from ~45 seconds to ~8 seconds and improves fault isolation (one report failure doesn't