Skip to content
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

feat: disable tracking in transactional email #2241

Merged
merged 6 commits into from
Jan 25, 2024

Conversation

KishenKumarrrrr
Copy link
Contributor

Problem

AWS SES includes a 1x1 tracking pixel to detect whether or not a user has opened/read an email. GSIBs block this tracking pixel which causes it to appear as a little red X at the bottom of emails. This makes the emails appear suspicious.

In this PR, I add a feature to enable transactional email users to turn off this tracking feature via a new disable_tracking flag. This would prevent this issue from popping up.

Solution

The events that are tracked by SES is determined by the configuration set that SES uses when sending out the email. This configuration set is determined by the value of the X-SES-CONFIGURATION-SET header. Configuration sets are defined via the AWS console.

I've added an additional configuration set (postman-email-no-tracking) to ap-southeast-2 that does not include tracking Open and Read states. This prevents the gif from being added.

Additionally, the transactional email request body now includes an optional disable_tracking field that users can set to true if they don't want the tracking pixel to be added. When tracking is disabled, we will use the postman-email-no-tracking configuration set instead of the default postman-email-open configuration set.

Deployment Notes

New Env Vars

  • BACKEND_SES_NO_TRACKING_CONFIGURATION_SET : Name of SES configuration set that does not include tracking open/read events

@KishenKumarrrrr KishenKumarrrrr self-assigned this Jan 24, 2024
@KishenKumarrrrr KishenKumarrrrr merged commit 1c9bcee into master Jan 25, 2024
8 checks passed
@KishenKumarrrrr KishenKumarrrrr deleted the feat/disable-tracking-in-transactional-email branch January 25, 2024 06:57
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.

None yet

3 participants