One of the measures of success in an online campaign is the amount of interaction that the ad unit(s) have had. We already measure all the basics: view, expand, close, video interaction. All these events are sent to our analytics servers and end up in our Reporting system (see below).
Image: WARM Reporting
Next to the default events mentioned before, you can also use the
screenad.event command to send custom events to our analytics server.
For example, let's say you added a game experience and you want to measure the amount of users that play it. You would need to add the following code in your start game function:
More information on the event command is available in our API in this same section.
Note: Please make sure that these commands are not called from within loops, as this will negatively impact the reliability of the statistics and performance of the ad.
The maximum length of an event name is 32 characters. Any events longer than 32 characters will be cut off. The following characters are allowed in event names:
Custom Timer events
Timer events are used to measure how much time a user spends performing a specific action, e.g: the expand time. Be sure to always call
screenad.stopTimer to stop counting the interaction time, otherwise the timer will keep running for the rest of the session. We automatically keep score of (among others) the following timers: visibility, expand duration, video play duration.
Example: measuring gameplay duration.
// when a user starts or resumes playing a game inside your ad unit
// when a user stops or pauses playing a game inside your ad unit