How does lead creation, association and push registration work?

January 19, 2018 | by

Lead Creation and Association

The following scenarios assume that the push notification token is registered on login and unregistered on logout. Prior to the initial login and token registration, the device/lead will not be targetable.

Scenario 1 – Two users each with separate devices

Lead A opens the app on Device X and an anonymous lead is created

  • Device X is not targetable yet

Lead A logs into Device X with email leadA@mkto.com

  • If email does not exist, the anonymous lead will be updated with the email, otherwise the leads will be merged
  • Targeting leadA@mkto.com will send push notification to Device X with lead A tokens

Lead B opens the app on Device Y and second anonymous lead is created

  • Device Y is not targetable yet

Lead B logs into Device Y with email leadB@mkto.com

  • If email does not exist, the anonymous lead will be updated with the email, otherwise the leads will be merged
  • Targeting leadB@mkto.com will send push notification to Device Y with lead B tokens

At this point, there are two distinct leads with each having an associated device and push token
Lead A logs out of Device X

  • Device X is no longer targetable

Lead B logs out of Device Y

  • device Y is no longer targetable

At this point, there are two distinct leads with each having an associated device with push enabled flags equal to false

Scenario 2 – Two users share a device

Lead A opens the app on Device X and an anonymous lead is created

  • Device X is not targetable yet

Lead A logs into Device X leadA@mkto.com

  • If email does not exist, the anonymous lead will be updated with the email, otherwise the leads will be merged
  • Targeting leadA@mkto.com will send push notification to Device X with lead A tokens

Lead A logs out of Device X disabling the push-enabled flag

  • Device X is no longer targetable

Lead B opens the app on Device X

  • Until Lead B logins, all activities will be tied to Lead A

Lead B logs in with email leadB@mkto.com on Device X

  • The lead is already associated with leadA@mkto.com, consequently a new lead is created for leadB@mkto.com
  • Targeting leadB@mkto.com will send push notification to Device X with lead B tokens

Lead B logs out of Device X disabling the push-enabled flag

  • Device X is no longer target-able

Now there are two distinct leads with each having an associated device with push enabled flags equal to false

Scenario 3 – One user with multiple devices

Lead A opens the app on Device X and an anonymous lead is created

  • Device X is not targetable yet

Lead A logs into Device X with email leadA@mkto.com

  • If email does not exist, the anonymous lead will be updated with the email, otherwise the leads will be merged
  • Targeting leadA@mkto.com will send push notification to Device X with lead A tokens

Lead A opens the app on Device Y and an anonymous lead is created

  • Device Y is not targetable yet

Lead A logs into Device Y with email leadA@mkto.com

  • If email already exists so the anonymous lead will be merged along with the associated Device Y
  • Targeting leadA@mkto.com will send push notification to both devices each with lead A tokens

Lead A logs out of Device X

  • Device X is no longer target-able
  • Targeting leadA@mkto.com will send push notification to device Y with lead A tokens

Lead A logs out of device Y

  • Both devices are no longer target-able

At this point, there is only one lead with two associated devices with push enabled flags equal to false

*** NOTES ***
If the token is registered on login but not unregistered on logout, there could be multiple tokens associated with that particular device. The system will suppress the older message and disable the tokens on the backend when the next push notification is received on the device. Under these conditions, the device will show only one notification which may contain tokens from a logged-out user. Therefore, it is recommended to always unregister the push token on logout.