StrataMail
A StrataBI Platform Module
Powered by Shaleio
Tier: Supported · module id stratamail · type multi_page_app (an app StrataBI renders from its own pages) · requires StrataBI · stands alone
StrataMail turns StrataBI dashboards into scheduled email reports, delivered through your own Amazon SES. You pick a dashboard, StrataMail checks that it can be rendered as a static email, and EventBridge Scheduler runs it on your schedule for your distribution lists.
What you get
Open Apps → StrataMail. Each tab has a list at the top and a form below it; choose an Action and press ▷ on the Action tile. Nothing is created or sent until you press ▷.
| Tab | Purpose |
|---|---|
| Reports | Pick one of your favorite or pinned dashboards — Email compatibility shows at once whether it can be emailed and which tiles can't. Add a name, subject, sender and lists, then Create report. Pick an Existing report to load it into the form, then Save changes, Send now, Pause/Enable or Delete. |
| Distributions | Email lists. Enter addresses separated by commas or one per line; they're validated and de-duplicated. Create, Add/Remove/Replace recipients, Rename, Delete. A list used by an active schedule can't be deleted until that schedule is paused or deleted. |
| Schedules | Daily, weekly (pick weekdays) or monthly (day 1–28) at a time and time zone. Leave Send to blank to use the report's lists. A schedule shows ACTIVE only once its EventBridge schedule exists. Pause, Resume, Delete. |
| Delivery History | Every run, scheduled or sent now: status, recipient count, SES message id, or the error. |
Quick start
- Distributions → Create new list with one verified address.
- Reports → pick a dashboard, fill in the fields, Create report.
- Pick it under Existing report → Send now, then check Delivery History.
- Schedules → pick the report and a time → Create schedule.
Which dashboards and who sees what
The dashboard list is the same as your homepage: dashboards you've starred plus those your admin pinned. Star a dashboard on its page to make it available. A star or pin only makes a dashboard findable — StrataMail checks that you may use it when you pick it and again on every scheduled run.
With StrataBI authentication configured (auth proxy or Cognito), reports, lists and schedules belong to you (owner_mode = actor). Without it there is no verified user, so everyone who can open StrataMail shares one workspace. Limit where mail can go with allowed_recipient_domains and approved_senders (required — with none set, nothing is sent).
What can be emailed
Compatibility is judged by what the dashboard renders, not how it gets data:
- Supported blocks:
table,plotly(exported as a PNG with Kaleido),markdown— including static markdown and inline charts with noexec. - Supported execution:
athena,cache, and customlambdamodules you have allow-listed. - Rejected:
raw_html, interactive inputs (input_select,input_range, …), iframes, unresolved interactive:params, and Lambdas that aren't allow-listed.
Rejected tiles are listed explicitly and block scheduling. The dashboard must also pass StrataBI's own schema (1.6.0); a failing field is reported with its path. If a chart can't be exported at send time the run fails and says which chart — it is never silently replaced with a table.
Delivery states
PENDING → GENERATING → RENDERING → RENDERED → SENDING → SENT, or FAILED (with the stage and reason), or UNCERTAIN — the send may or may not have reached SES (e.g. a timeout). An uncertain run is never resent automatically; check SES before sending again. Exactly-once delivery is not promised.
Install and update
stratactl install stratamail
stratactl update stratamail --to <version>
stratactl uninstall stratamailSettings
| Setting | Default | Meaning |
|---|---|---|
approved_senders | — (required) | Verified SES sender identities, comma-separated. |
app_url | — | Your StrataBI URL (e.g. https://bi.example.com); emails link to the live dashboard. |
ses_region | us-east-1 | Region of those SES identities. |
allowed_recipient_domains | any | Restrict recipients to these domains. |
allowed_lambda_modules | none | Custom Lambda modules a report may execute. |
allowed_workgroups | primary | Athena workgroups reports may use. |
allowed_cache_prefixes | none | S3 cache prefixes reports may read. |
report_retention_days | 30 | How long rendered report artifacts are kept. |
owner_mode | actor | actor (the signed-in user; shared when StrataBI has no auth), deployment (always shared), session (one browser session — demos), or event (an owner_id injected by your own authorizer). |
favorites_table / pinned_table | <name_prefix>-dashboard-favorites / -pinned | StrataBI's own overlay tables (read-only). |
Settings live at config/stratamail.auto.tfvars.json in your StrataCI bucket; change them and run stratactl update stratamail (how).
Set up SES
StrataMail sends through Amazon SES in your account. It does not create sender identities. You verify them, then tell StrataMail which ones it may use. Use the same region throughout: ses_region (default us-east-1).
1. Verify a sender. An email address is quickest:
aws sesv2 create-email-identity --email-identity reports@example.com --region us-east-1SES emails a verification link to that address; click it. For production, verify the domain instead (--email-identity example.com). The response contains three DKIM tokens: publish each as a CNAME record <token>._domainkey.example.com → <token>.dkim.amazonses.com. Every address at a verified domain can then send. DNS can take a while to propagate. Check status with:
aws sesv2 get-email-identity --email-identity reports@example.com --region us-east-1 \
--query VerifiedForSendingStatus2. Check whether the account is in the SES sandbox.
aws sesv2 get-account --region us-east-1 --query ProductionAccessEnabledfalse means sandbox: you can only send to verified addresses (verify test recipients the same way as step 1), with low sending limits. To mail anyone, request production access in the SES console (Account dashboard → Request production access). AWS reviews the request.
3. Approve the sender in StrataMail. Using the Module settings snippet with M=stratamail, set:
approved_senders=reports@example.com # comma-separated for several
allowed_recipient_domains=example.com # optional: only mail these domainsthen run stratactl update stratamail.
Only addresses in approved_senders can be used, and mail_sender's role can only send from identities in ses_region.
Gmail says "couldn't verify this"? You're sending from a single verified address. Verify the domain with Easy DKIM (step 1) so receivers can authenticate the mail, and keep the sender on that domain.
4. Check it. On Reports, the Sender dropdown lists your address. Create a list with one verified recipient, create a report, use Send now, then look at Delivery History.
AWS services
Everything below runs in your AWS account. It is created by the install unless noted.
| Service | Used for | Required |
|---|---|---|
| Amazon DynamoDB | Single-table store for distributions, reports, schedules, runs, deliveries. | Yes |
| Amazon EventBridge Scheduler | Native recurrence; invokes report_dispatcher. | Yes |
| Amazon SES | Email delivery from approved sender identities. | Yes |
| AWS Lambda | The in-app tabs, CRUD, scheduling, execution, rendering, delivery. | Yes |
| Amazon S3 | Fresh report artifacts + report.html with a dedicated lifecycle policy. | Yes |
| Amazon Athena | For athena-exec dashboard tiles. | Optional |
| Amazon SQS | EventBridge Scheduler target DLQ. | Yes |
| AWS IAM | Least-privilege per function. | Yes |
| Amazon CloudWatch Logs | Runtime logs. | Yes |
It also uses pieces of your existing StrataBI install: the system S3 bucket, the module registry (DynamoDB) and, for tile results, the <name_prefix>-status-writer Lambda.
How it works
EventBridge Scheduler ─► report_dispatcher ─► report_executor ─► report_renderer ─► mail_sender ─► SES| Lambda | Does |
|---|---|
ui_handler | The four tabs: dropdown options, lists and actions. It reads your favorites/pins and calls the managers below; it has no report data or scheduler access of its own. |
distribution_manager / report_manager / schedule_manager | Management: lists, report definitions (+ compatibility check), schedules. |
report_dispatcher | Validates a scheduled run and orchestrates it (idempotent). |
report_executor | Runs the report's Athena / cache / allow-listed Lambda sources. |
report_renderer | Renders email-safe static HTML and chart images. |
mail_sender | Sends through SES and records delivery (never resends a confirmed delivery). |
report_history | Authorized history retrieval. |
Each function has its own role; mail_sender alone can send email, and no role can invoke arbitrary Lambdas. Data lives in the module's DynamoDB table and the stratamail/ prefix of the system bucket.
Troubleshooting
- Dashboard dropdown is empty — star a dashboard on its page (or ask an admin to pin one).
- "You don't have access to that dashboard" — it's another user's private dashboard; only global, your own, or pinned dashboards can be emailed.
- "can't be emailed yet" — remove or replace the listed tiles (e.g.
raw_html, inputs), or allow-list the Lambda module the tile uses (allowed_lambda_modules). - Sender dropdown says "install sets approved_senders" — set
approved_sendersand runstratactl update stratamail(Set up SES, step 3). - "Email address is not verified" — the sender, or (in the SES sandbox) a recipient, isn't verified in
ses_region. Click the verification link, or check the region matches. - Send now shows FAILED in history — the error column says why; the most common cause is an unverified sender or, in the SES sandbox, an unverified recipient.
Shaleio