Skip to content

feat(api): send replies to a school's marketing email to its owner - #886

Merged
s3rot0n1n merged 1 commit into
feat/plan-limitsfrom
feat/marketing-sender-reply-to
Nov 15, 2026
Merged

s3rot0n1n merged 1 commit into
feat/plan-limitsfrom
feat/marketing-sender-reply-to

Conversation

@clbotdev

@clbotdev clbotdev commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

Stacked on #881 (feat/plan-limits).

Each school's marketing email goes out from the organization's shared SendLit provider. The team's grant on that provider already carries the school's name as the From name; this adds the owner's email as Reply-To, so replies reach the school instead of the shared address.

What changes

  • sendlit-sender.ts builds the sender (school name, plus the owner's email when known). Both provisioning paths (the outbox job and ensureSendLitTeam) use it.
  • A school's name can't be changed after creation, so nothing needs re-syncing.
  • Self-hosting docs and the API README list the scopes SENDLIT_ORGANIZATION_API_KEY needs: organization:read, teams:provision, teams:read, teams:manage, teams:keys, usage:read. Without teams:manage, the plan quota can't be written to the team.
  • plan-limits.md section 6 describes the marketing sender and the one-time setup of the school-team organization (subdomain sending address, autoGrantDefaultEsp on, teamEspEnabledByDefault off).

Depends on

SendLit's bootstrap key gaining those scopes: codelitdev/sendlit#202. QA's key needs them added by hand.

Tests

  • Unit tests for the sender.
  • integration-provisioning.test.ts checks the reply-to sent at provisioning.

A school's SendLit team is provisioned with the owner's email as
Reply-To, next to the school's name as the sender, so replies don't
land at the shared sending address.

Docs: list the organization key scopes CourseLit needs
(teams:manage, teams:keys, usage:read on top of the provisioning ones)
and the one-time setup of the school-team organization.
@s3rot0n1n
s3rot0n1n merged commit c47917b into feat/plan-limits Nov 15, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants