How to set journey properties in JS

You can set journy.io journey properties by a fix set of JS calls, right from within your website or application.

Here's a list of available calls at your disposal:

You can use the following script to identify a journy by email.

journy("identify", { email: "[email protected]", score: 25 });
email: the email identifying the contact.
score: a number from 0 to 100 representing the certitude/probability that the current journey belongs to this contact. If this is set in an email that can be shared, probability is low and should be set to 10, 20, or 30. If this is a log-in/registration screen, chances are much higher that this journey (on this device) is from the owning contact and the score should be set to 70 80 90 or even 100.

If a score is set to n, a later identification with lower score < n will not be recorded! Equal or higher scores >= n will have the contact re-identified with new email.

You can use the following script to trigger an event by tag string.

journy("event", { tag: "download ebook 15" });

Note that all parameter are non-case-sensitive.
Was this article helpful?
Cancel
Thank you!