Expensify / App

Welcome to New Expensify: a complete re-imagination of financial collaboration, centered around chat. Help us build the next generation of Expensify by sharing feedback and contributing to the code.
https://new.expensify.com
MIT License
3.58k stars 2.92k forks source link

[Tracking] Add email tracking for email deliverability and open/click rates. #48663

Open danielrvidal opened 2 months ago

danielrvidal commented 2 months ago

High level design doc

Proposal: Add email tracking for email deliverability and open/click rates.

Problem: Recipients are not reliably clicking on IOUs from senders, and thus never coming into the product. We know a non zero percentage of users ignore the emails we send, but we don’t actually know how bad the problem is. We rely on email notifications to pull viral leads into our product. However, we’re unable to determine if our emails are making this problem bigger by not being engaging and compelling for our users, or even worse not getting delivered. This lack of insight prevents us from optimizing our email communications, resulting in decreased user engagement, decreased understanding of our value, decreased conversion rates, and ultimately hampers our ability to drive sustainable growth.

Solution: Let’s start tracking email deliverability and open/click through rates with all relevant notifications so we know how big the problem is and can a/b test email communications to increase conversion of invited users to active users.

  1. Let’s start by tracking the emails we send for one invite type: IOUs for new users.
  2. We already use custom subject line to trigger an immediate unread message notification to the IOU recipient (added in this PR). Let’s add a tracker in this same place that identifies the type of email.
    • It might look something like $this->parameters['trackingKey'] = 'IOUnewUser'
  3. We’ll send this tracker as a tag to Mailgun
  4. Mailgun is already set up to measure email deliverability and open/click-through rates for all emails. All we need to do now is distinguish an IOU notification vs. any other unread message notification and the tracker accomplishes that
    • Note: Mailgun only covers 50% of our emails. But so long as we track the control and test versions and compare them within that 50% pool, and then wait for statistical significance, we should learn if/which notifications are effective.
  5. We’ll run an inbox placement test which sends the IOU notification to various mail providers and lets us know how often the specific notification is getting caught by spam.
  6. We will get a baseline on the current notification open/click rate and validate this design before we introduce any A/B testing
    • A/b testing the open rate of IOUs for new users using different subject lines will likely be our first test which is why we chose that, but the a/b test will come later.

Tasks

Issue OwnerCurrent Issue Owner: @danielrvidal
danielrvidal commented 2 months ago

Here are the next steps as of now

From there we'll plan the next steps once those are done.

justinpersaud commented 2 months ago

Workong on it this week but I'm just trying to wrap up some SOX audit issues that keep coming back from EY + finishing up blocking spam with ChatGPT for #fireroom-05-23-spam

danielrvidal commented 2 months ago

We should have the doc out today or tomorrow!

justinpersaud commented 2 months ago

I updated the design doc and filled in the Data Storage / API section

danielrvidal commented 2 months ago

High level design doc

The HL is ready for reviews. Please give it a read and ask questions in the doc or room. Assigning the review label now!

melvin-bot[bot] commented 2 months ago

:wave: Hello Generalist Track Team - you have been assigned to review this High Level Design Doc. Check out this Stack Overflow for some tips on reviewing a design doc. Once you are done, simply press the Add "Reviewed Doc" comment button in the right hand side K2 panel or follow these instructions.


fukawi2 commented 2 months ago

I have read and reviewed this Design Doc!

srikarparsi commented 2 months ago

I have read and reviewed this Design Doc!

garrettmknight commented 2 months ago

I have read and reviewed this Design Doc!

MarcFillari commented 2 months ago

I have read and reviewed this Design Doc!

twisterdotcom commented 2 months ago

I have read and reviewed this Design Doc!

dangrous commented 2 months ago

I have read and reviewed this Design Doc!

danielrvidal commented 2 months ago

I just bumped the remaining reviewers but hopefully we'll move to detailed in the next day or so.

Christinadobrzyn commented 2 months ago

I have read and reviewed this Design Doc!

davidcardoza commented 2 months ago

I have read and reviewed this Design Doc!

stephanieelliott commented 2 months ago

I have read and reviewed this Design Doc!

justinpersaud commented 1 month ago

Detailed is ready to go out I think.

francoisl commented 1 month ago

I have read and reviewed this Design Doc!

techievivek commented 1 month ago

I have read and reviewed this Design Doc!

iwiznia commented 1 month ago

I have read and reviewed this Design Doc!

flodnv commented 1 month ago

I have read and reviewed this Design Doc!

melvin-bot[bot] commented 1 month ago

:wave: Hello Generalist Track Team - you have been assigned to review this Detailed Design Doc. Check out this Stack Overflow for some tips on reviewing a design doc. Once you are done, simply press the Add "Reviewed Doc" comment button in the right hand side K2 panel or follow these instructions.


justinpersaud commented 1 month ago

Wrapping up some discussions in the detailed portion

puneetlath commented 1 month ago

I have read and reviewed this Design Doc!

garrettmknight commented 1 month ago

I have read and reviewed this Design Doc!

cead22 commented 1 month ago

I have read and reviewed this Design Doc!

CherylWalsh commented 1 month ago

I have read and reviewed this Design Doc!

tylerkaraszewski commented 1 month ago

I have read and reviewed this Design Doc!

chiragsalian commented 1 month ago

I have read and reviewed this Design Doc!

justinpersaud commented 1 month ago

Implementation for this is in review

JmillsExpensify commented 1 month ago

I have read and reviewed this Design Doc!

justinpersaud commented 1 month ago

Working on some last bit of bugs with the IOU tracking

justinpersaud commented 2 weeks ago

Need to review and see if this is working this week

justinpersaud commented 2 weeks ago

Seems like this is working given we found data for the variants here

https://expensify.slack.com/archives/C07HPDRELLD/p1731372028836229?thread_ts=1730161250.824289&cid=C07HPDRELLD

justinpersaud commented 1 week ago

Daniel is going to review the data from the analytics before we close this off

justinpersaud commented 1 day ago

Latest update was here https://expensify.slack.com/archives/C07HPDRELLD/p1732551384217819?thread_ts=1730161250.824289&cid=C07HPDRELLD