-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CCAP-493] Create sendGrid family confirmation email and background job #970
base: main
Are you sure you want to change the base?
Conversation
42994ee
to
76c5aab
Compare
@cram-cfa Not fully implemented is the webhook which I haven't been able to get working. The webhook should provide asynchronous updates on email statuses from Sendgrid, to our applications endpoint. I can see pings to the endpoint in the Heroku logs, but the endpoint shows a 403 (unauthorized?) which I'm not sure if that means our application is saying Heroku is unauthorized or vice versa. https://www.twilio.com/docs/sendgrid/for-developers/tracking-events/getting-started-event-webhook If we can get this working we should be able to implement retries when needed and a status table for emails. |
I also setup a Datadog alert if communicating with Sendgrid fails: |
Sure. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
return; | ||
} | ||
String familyEmail = familySubmission.getInputData().get("parentContactEmail").toString(); | ||
if (familyEmail == null || familyEmail.isEmpty()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So if the family choses to be reached out by phone, this email value should be null
private Content createFamilyConfirmationEmailBody(Submission familySubmission, String confirmationCode, Locale locale) { | ||
String parentFirstName = familySubmission.getInputData().get("parentFirstName").toString(); | ||
String emailLink = familySubmission.getInputData().get("emailLink").toString(); | ||
String ccrAndR = familySubmission.getInputData().get("ccrrName").toString(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is so exciting. Looking forward to setting ccrrName dynamically to test different providers
🔗 Jira ticket
CCAP-493
✍️ Description
Creates a SendGridEmailService and background job which is enqueued via an action. The action queue's a background job to send an email via the sendgrid API.