Summary
Connect the newly built Frontend Email Comms UI to the backend emails module and user data. This involves two workflows: 1) Updating the automated transactional HTML template used for "Donation Response" (sent immediately after a successful donation), and 2) Fetching target lists and dispatching bulk campaigns via Amazon SES for "Relapsed Donor Message" and "Email Subscribers" (mass email lists).
To reiterate:
Relapsed Donor Message: Email sent to lapsed donors.
Donation Response: Email to be sent right after a donation is made to the donor.
Email Subscribers: People in email list.
Steps
- Wire the "Relapsed Donor Message" tab to fetch targets using the existing
GET /donations/lapsed endpoint in apps/backend/src/donations/donations.controller.ts.
- Implement backend logic to fetch the full list of opted-in users for the "Email Subscribers" tab.
- Create logic to save the "Donation Response" editor payload as an automated transactional HTML template, to be triggered via SES directly whenever a donation is successfully processed in the system.
- Create a POST endpoint in the
emails module that accepts the HTML body string, subject line, and the target group to dispatch the bulk campaigns ("Relapsed Donors" and "Email Subscribers").
- Connect the new POST endpoint to the existing Amazon SES integration to dispatch the emails.
- Replace the mocked "Save Changes" / "Send" action on the frontend with the actual API calls to either update the template (Donation Response) or trigger the bulk send (Relapsed/Subscribers).
Acceptance Criteria
Summary
Connect the newly built Frontend Email Comms UI to the backend
emailsmodule and user data. This involves two workflows: 1) Updating the automated transactional HTML template used for "Donation Response" (sent immediately after a successful donation), and 2) Fetching target lists and dispatching bulk campaigns via Amazon SES for "Relapsed Donor Message" and "Email Subscribers" (mass email lists).To reiterate:
Relapsed Donor Message: Email sent to lapsed donors.
Donation Response: Email to be sent right after a donation is made to the donor.
Email Subscribers: People in email list.
Steps
GET /donations/lapsedendpoint inapps/backend/src/donations/donations.controller.ts.emailsmodule that accepts the HTML body string, subject line, and the target group to dispatch the bulk campaigns ("Relapsed Donors" and "Email Subscribers").Acceptance Criteria
/donations/lapsedlogic.