to main#794
Merged
Merged
Conversation
…riber list
Step 2 of the gig-promotion feature: the shared send core all three clients
(admin UI, Claude, gemma) call. Builds on the Step 1 subscriber list + mailer.
- Adds `promo:email` to the capability registry so it can be assigned to the
web-jam-llm bot (and validated on admin-user create).
- POST /promo/gig/email { subject, bodyHtml } -> sends to every active
email-channel subscriber, appending each recipient's unsubscribe link.
Returns { sent, failed, total }. Sequential to respect Gmail rate limits;
per-recipient failures are counted, not fatal. Content comes in the payload
(gig data lives in WebJamSocketCluster), so the backend stays decoupled.
- Authorization is privilege-first with role fallback: callers with a
privileges array must hold promo:email (bot/Claude/gemma); callers without
privileges fall back to the admin role check (JaM-admin or Developer), so the
human admin keeps working with no user-record change.
- 8 controller unit tests; full suite green (147), lint + tsc clean.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
feat(promo): POST /promo/gig/email — fan out a gig blast to the subscriber list
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.