Closed jlieb10 closed 8 months ago
25 May 2022
Ash, Max, Oliver, Joshua
Also linking to Max's RFC: https://github.com/guardian/dotcom-rendering/discussions/4474#discussioncomment-2765931 And my brainstorm: https://docs.google.com/document/d/1TWiLEBItO9k5cogJDhutw4aakswCjdHN89pbzgjQmXY/edit#
(Both of which have been superseded by the above)
We are need to design a general-purpose API that can sit next to tracker.js for the time being, and in time grow to replace the role of tracker.js on DCR.
The requirements are for it to be simple, lightweight, easily and readily used and expanded by devs on DCR. It needs to depend on consents (and needs to be agreed by the consents team) and also needs to be agreed with the Data team, as they will be carrying out the analyses in the first instance. Further requirements: it eventually needs to be able to do everything that tracker.js can do, and additionally we want this to be enhanced by at-minimum scroll tracking and give relative times for user interactions, so in a way this will be able to tell a rich story about the experience on the page.
In terms of tech, we will use big query and send beacon - implementations which are already in place, and can accept 62kb max payloads. Client-side code will be written in vanilla JS so it can be executed ahead of and separate from other scripts.
By the end of the quarter, we would view "success" on the KR as having an API agreed by the department and an implementation of the API for scroll depth, which may need to be anonymised at first if we have not yet come to an agreement with the consents team.
Meeting notes that inform this description, and more follow up items, are below