Closed QaysarA closed 3 years ago
These are the GA parameters and their values: The tid value for non-productions environments is UA-50123418-16
v=1
t=event
tid=UA-50123418-16
cid=<notification id>
aip=1
ec=email
ea=open
el=<template name>
dp=/email/vanotify/<organization name>/<service name>/<template name>
dt=<email subject>
cn=<template name>
cs=<notification api provider>
cm=email
ci=<template id>
example:
v=1
t=event
tid=UA-50123418-16
cid=894de4a5-4be3-441c-8d1c-76e054a7a5ff
aip=1
ec=email
ea=open
el=Form 526ez email confirmation
dp=/email/vanotify/va.gov/va.gov/Form 526ez email confirmation
dt=Weʼve received your application
cn=Form 526ez email confirmation
cs=gov-delivery
cm=email
ci=0c1335fc-ca67-408a-b2ae-08b91ffaceba
We need to modify the code so the required values are available. The next comment will include the required changes.
When v2/notifications/email end point code has access to authenticated_service which is the service we need and can be used to get serice name. It also contains organisation_id and possibly organisation. If organization is not loaded, then the organisation_id should be used to get the organization. In celery worker the service is available when HTMLEmailTemplate is created. HTMLEmailTemplate is the notification utils that uses jinja2 template to generate html and plan emails.
tested on Friday 13, November 2020; tested with gmail, yahoo and outlook Analytics All Web Site Data - VA.gov Testing Environments Top Events 20201113-20201113.pdf
Value Statement:
As a VANotify stakeholder I want to understand the open rates for notification emails So that I can measure and evolve the performance of notifications
Acceptance Criteria
1. GIVEN an email notification WHEN the email is sent THEN the html body contains a google tracking pixel with parametrized tags
2. GIVEN an email notification has been delivered WHEN the email is opened THEN the appropriate open rate data is visible in GA dashboard
Checklist:
Assumptions:
Additional Info/Resources:
Out of Scope:
Open Questions: