Subscriber Systems
Integrating ATS with Piano.io

Piano.io exposes an event that is fired when a user logs in. The snippet below fetches the email and passes it to ATS on that event. Note that ATS must be triggered first on a page view.
window.tp = window.tp || [], window.tp.push(["addHandler", "loginSuccess", async function (n) { atsenvelopemodule.setAdditionalData({ 'type': 'email', 'id': window.tp.pianoId.getUser().email }) }]);
See piano.io documentation for more information.