Custom Data Events

This method sends custom events for tracking and real-time personalization. It can be used to send third-party data, or to trigger your own custom event based on the visitor behavior. Custom data events are counted once in a visitor’s session.

You must become a Web Personalization customer and have the RTP tag deployed on your site prior to using the User Context API.

 

Parameter Optional/Required Type Description
‘send’ Required String Method action.
‘event’ Required String Method name.
customData Required String or Array Custom data.

Examples

Send Event using String for Custom Data:

Send Event using Array of Strings for Custom Data:

The custom data array can contain a maximum of 4 elements.  If you need to send more than 4 elements, then call Send Event API repeatedly (with a maximum of 4 items) until all items are sent.

Send Event Based on Button Click:

Marketo personalizes content on their website to web visitors who download a specific white paper. They do this by capturing the visitor’s click on the white paper download button, which sends a custom data event. RTP segments in real-time all visitors who clicked on the download white paper button, showing each visitor a personalized campaign offering 2 clicks later. This is achieved by displaying a another piece of content related to the white paper downloaded.