Moat Analytics

Moat Analytics is one of the products from Moat that can be used to directly analyse a whole range of metrics on videos and ads, as you serve them from a multitude of platforms. Currently, Pulse has a module to plug in Moat Analytics on sites where you use our HTML5 ad player to serve ads from Pulse.


Before you can get started with the integration, you must have:

  • A Moat partner code from your Moat Analytics account.
  • An integration with the HTML5 Ad Player using version or higher.

Events reported to Moat

When using the Moat plugin with your ad player integration, the following events are automatically tracked to Moat for each ad as they occur:

  • AdVideoStart: when a video ad starts playing.
  • AdVideoFirstQuartile: when 25% of a video ad has played.
  • AdVideoMidpoint: when 50% of a video ad has played.
  • AdVideoThirdQuartile: when 75% of a video ad has played.
  • AdVideoComplete: when 100% of a video ad has played.
  • AdPaused: when a video ad is paused.
  • AdPlaying: when a video ad starts playing, or when it resumes playing after being paused.
  • AdVolumeChange: when the volume of an ad is changed.
  • AdStopped: when an ad has finished. This event is different from the AdVideoComplete event, because it signals that the ad itself has finished and not just the playback of the video it contains. For example, if a VPAID ad first plays a video ad and then shows some other interactive media, then AdVideoComplete is tracked at the end of its video ad, but AdStopped is only tracked after all of the VPAID's content has finished.

Getting started

Follow these steps to create a basic integration:

  1. Load the Moat plugin after the Pulse SDK on the page where you have your ad player integration:
    Note: Make sure that the main version of the Pulse SDK and the Moat plugin are the same. In the example below, you can see the main version is in the URL (2.1).
    <!DOCTYPE html>
    <html lang="en">
        <meta charset="UTF-8">
        <title>HTML5 video with Pulse and Moat</title>
        <script src=""></script>
        <script src=""></script>
  2. In the integration code for your ad player, configure Moat before you create the ad player:
    session = OO.Pulse.createSession(contentMetadata, requestSettings);
      partnerCode: 'partner-code-here'
    adPlayer = OO.Pulse.createAdPlayer(adContainer);

Configuration options

When configuring the Moat plugin, you have the following settings:

  • partnerCode: your Moat Analytics partner code. This setting is required.
  • disable: optionally, disable or enable the Moat plugin for each subsequent ad player created on your page. By default, the Moat plugin is enabled when you configure it for the first time. An example of enabling and disabling:
    // first configuration of the plugin
      partnerCode: 'partner-code-here'
    // Moat is enabled for this ad player
    adPlayer_1 = OO.Pulse.createAdPlayer(adContainer_1);
    // now we disable the Moat plugin
      disable: true
    // Moat is disabled for this ad player
    adPlayer_2 = OO.Pulse.createAdPlayer(adContainer_2);
    // Moat is also disabled for this ad player, because we have to specifically re-enable it
    adPlayer_3 = OO.Pulse.createAdPlayer(adContainer_3);
    // re-enabling the Moat plugin
      disable: false
    // Moat is enabled again for this ad player
    adPlayer_4 = OO.Pulse.createAdPlayer(adContainer_4);
  • idProvider: optionally, configure how ads are identified in the Moat dashboard. You do this by passing information from the ad object to the Moat SDK. In the Moat plugin we map the following options in the Moat SDK:

    • level1: mapped by default to the campaign ID of the ad.
    • level2: mapped by default to the goal ID of the ad.
    • level3: mapped by default to the ad ID.
    • slicer1: mapped by default to the ad break position (pre-, mid-, or post-roll).

    To override the idProvider, the code would look as follows:

      partnerCode: 'partner-code-here',
      idProvider: (pulseAd, adBreakPosition) => {
        return {
          'level1': pulseAd.getCoreAd().campaignId,
          'level2': pulseAd.getCoreAd().goalId,
          // overriding 'level3' to store the custom ID of the ad, instead of the ad ID
          'level3': pulseAd.getCoreAd().customId,
          'slicer1': adBreakPosition


The following limitations apply to the Moat integration:
  • The ad player can only send IDs to Moat to identify the campaigns, goals and ads, respectively.

Contact for troubleshooting and information

Contact us in case of:
  • issues with receiving data in Moat Analytics from your integration.
Contact Moat in case of:
  • issues finding your partner code,
  • issues with the data in your Moat Analytics account,
  • and getting information on which options in the Moat SDK to use to send information to Moat Analytics.