Integrating with Drift

Mutiny automatically integrates with Drift so you can track conversions and identify your users.

Updated over a week ago

If you use Drift on your website, you can track Mutiny conversions and identifications when users take specific actions on your site.

Conversion Tracking

By default, Mutiny will create a conversion for you called "All Drift conversions". This conversion will automatically track emailCapture, phoneCapture, and scheduling:meetingBooked events from Drift.

If you'd like to specify specific pages where this conversion is tracked, you can create a new conversion.

  1. Click "+ New Conversion".

  2. Select Drift under "See more types".

  3. Define which pages you want this conversion to fire on. You can choose a single URL, or define more pages by selecting "Use multiple URLs". Then click "Save".

Identification

You can identify users that submit their email on Drift by taking advantage of Mutiny's Identify SDK. Read more about the Identify SDK here. To do this, you'll want to place this code on all pages of your website (you can also place this script using Google Tag Manager).

<script>
function waitForDrift(callback, timeout) {
var checkDrift = setInterval(function() {
if (window.drift) {
clearInterval(checkDrift);
callback();
}
}, 100);

setTimeout(function() {
clearInterval(checkDrift);
}, timeout);
}

waitForDrift(function() {
if (window.drift) {
window.drift.on("emailCapture", function(data) {
var email = data.data.email
window.mutiny.client.identify(null, {
email: email
});
});
} else {
}
}, 10000);
</script>This script will listen for any email capture events that Drift sends, and automatically pass the user's email back to Mutiny.

This script will wait for Drift to load on your site, and then place an event listener on the emailCaptured event. When a user submits their email, it'll be passed back to Mutiny.


Don't be a stranger

If you have any questions, we’re here to help! Please feel free to contact us at any time, either through intercom chat or via support@mutinyhq.com.

Did this answer your question?