Advertising Events

🚧

Video ad insertion requires a JWX Enterprise license. Please contact our team to upgrade your account.

This API provides developers with more control over the functionality of the Advertising edition of the JWX player. For VAST and IMA plugins, this API allows for things like impression verification, custom scheduling, and multiple companions.



.on('adBidRequest')

Fired when header bidding starts requesting for bids.

Returns an object with the following:

PropertyDescription
bidders array An array of all bidders in the current bid request.
bidTimeout number The amount of milliseconds it will wait for the bids to return after user clicks to play.
client string

The client that is currently being used.



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
floorPriceCents number

Floor price that the return bids need to beat to play.



Not returned when using dfp mediation layer.

floorPriceCurrency string

The currency of the floor price cents value.



Needs to be usd for Facebook. Only used for Facebook bids when mediation layer is set to jwp.

mediationLayerAdServer string

The mediation layer, which is the decision-maker in what ad to run



Possible Values:
  • dfp
  • jwp
  • jwpdfp
  • jwpspotx
offset stringThe offset of the ad
type string

The type of the event



This will always return adBidRequest.

viewable number

If the player is viewable or not.



Possible Values:
  • 0
  • 1

Each bidder object contains the following:

PropertyDescription
id number The publisher ID used for header bidding for each of the bidder.
name string

The name of the bidder



Possible Values:


See: advertising.bids.bidders[].name



.on('adBidResponse')

Fired when header bidding returns response.

Return an object with the following:

PropertyDescription
bidders array An array of all bidders in the current bid request.
bidTimeout number The amount of milliseconds it will wait for the bids to return after user clicks to play.
client string

The client that is currently being used.



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
floorPriceCents number

Floor price that the return bids need to beat to play.



Not returned when using dfp mediation layer.

floorPriceCurrency string

The currency of the floor price cents value.



Needs to be usd for Facebook. Only used for Facebook bids when mediation layer is set to jwp.

mediationLayerAdServer string

The mediation layer, which is the decision-maker in what ad to run



Possible Values:
  • dfp
  • jwp
  • jwpdfp
  • jwpspotx
offset stringThe offset of the ad
placement string

Value sent in a bid request that identifies the location of a player



Possible Values:
  • article
  • banner
  • feed
  • floating
  • instream
  • interstitial
  • slider
type string

The type of the event



This will always return adBidResponse.

viewable number

If the player is viewable or not.



Possible Values:
  • 0
  • 1

Bidder Object

Each bidder object contains the following:

PropertyDescription
id number The publisher ID used for header bidding for each of the bidder
name string

The name of the bidder



Possible Values:


See: advertising.bids.bidders[].name

priceInCents number

The price of the bid.



Only used when JWP is the mediation layer

result string

The result of the bidder's bid



Possible Values:
  • bid
  • noBid
  • timeout
tagKey number

The tagKey of the bid returned.



Only used for SpotX bidder

timeForBidResponse numberTime taken for the bid to return in milliseconds
winner boolean

Set to true when the bidder is the winning bid



Possible Values:
  • false
  • true


.on('adBlock')

This event is fired when an ad plugin (Either VAST or Google IMA) is configured inside of the JWX player setup, and an ad blocker is detected on a viewer's browser. It is then possible to request a user disable their ad blocker to proceed.



.on('adBreakEnd')

Fires when control is passed back to the player from the ad.

Returns an object with the following:

PropertyDescription
adposition string

An ad's position.



Possible Values:
  • mid
  • post
  • pre
client string

The ad client in use for the ad break.



Possible Values:


  • dai
  • freewheel
  • googima
  • vast
type string

The type of the event is firing



This will always return adBreakEnd.

viewable number

If the player is viewable or not.



Possible Values:


  • 0: The player is below 50% or is in an inactive tab
  • 1: The player is at least 50% in view and is in the active tab


.on('adBreakIgnored')

(VAST only) Fires when the time elapsed between the previous fully-watched ad break and the current ad break is less than the value defined by advertising.rules.timeBetweenAds


{
    "id": "adbreak2",
    "tag": "{ad_tag_url}",
    "offset": 6,
    "timeSinceLastAd": 3.256,
    "type": "adBreakIgnored"
}
PropertyDescription
id string Descriptive name of the ad break
offset number | string

Position of an ad



Possible Values:


  • {number in seconds} (This occurs for mid-roll ad breaks.)
  • post
  • pre
tag string URL of the ad tag
timeSinceLastAd number

Duration between the current ad break and the saved time of the last ad break



This value will always be less than the advertising.rules.timeBetweenAds value.

type string

The type of the event is firing



This will always return adBreakIgnored.



.on('adBreakStart')

Fires after the ad request and immediately before the ad is loaded into the player. Only fires before the first ad inside of an ad break.

Returns an object with the following:

PropertyDescription
adposition string

An ad's position.



Possible Values:
  • mid
  • post
  • pre
client string

The ad client in use for the ad break.



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
type string

The type of the event is firing



This will always return adBreakStart

viewable number

If the player is viewable or not.



Possible Values:
  • 0: The player is below 50% or is in an inactive tab
  • 1: The player is at least 50% in view and is in the active tab


.on('adClick')

Fires whenever a user clicks an ad to be redirected to its landing page

{
    "client": "dai",
    "viewable": 1,
    "id": "cfau4gxh3q00",
    "adPlayId": "of0i8kj1tkp0",
    "adtitle": "External NCA1C1L1 Preroll",
    "adsystem": "GDFP",
    "creativetype": "application/x-mpegURL",
    "linear": "linear",
    "adposition": "pre",
    "type": "adClick"
}
{
    "client": "freewheel",
    "tag": "placeholder_preroll",
    "freewheel": {
        "ad": {
            "adId": "17302931"
        }
    },
    "adposition": "pre",
    "id": "17302931",
    "linear": "linear",
    "creativetype": "video/mp4",
    "viewable": 1,
    "sequence": 1,
    "podcount": 2,
    "skipoffset": 3,
    "type": "adClick"
}
{
    "client": "googima",
    "placement": 1,
    "viewable": 0,
    "adposition": "pre",
    "tag": "//playertest-cdn.longtailvideo.com/pre.xml",
    "adBreakId": "1fuk7qd71j5p",
    "adPlayId": "1fuk7qd71j5p",
    "id": "1fuk7qd71j5p",
    "ima": {...},
    "adtitle": "JW Test Preroll",
    "adsystem": "Alex_Vast",
    "creativetype": "video/mp4",
    "duration": 0,
    "linear": "linear",
    "description": "",
    "creativeAdId": "",
    "adId": "232859236",
    "universalAdId": [],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "//content.bitsontherun.com/videos/1EI2jHpo-52qL9xLP.mp4"
    },
    "type": "adClick"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "1bzytku1wlz6",
    "adPlayId": "1bzytku1wlz6",
    "offset": "pre",
    "id": "1jnyb7aup1ya",
    "tag": "//playertest-cdn.longtailvideo.com/pre-60s.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 5,
    "adschedule": {
        "item": 1,
        "breakid": "adbreak1",
        "tags": [
            "//playertest-cdn.longtailvideo.com/pre-60s.xml"
        ],
        "offset": "pre"
    },
    "adtitle": "JW Test Preroll",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 2 qualities"
    ],
    "mediafile": {
        "file": "//content.jwplatform.com/videos/zz4Abp0Z-bPwArWA4.mp4"
    },
    "viewable": 1,
    "creativetype": "video/mp4",
    "categories": [],
    "type": "adClick"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adId string From the ad XML, identity of the ad server that provides the creative

Definition from IAB Tech Lab
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string From the ad XML, common name for the ad

Definition from IAB Tech Lab
adVerifications object From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
categories array From the ad XML, list of category codes or labels that identifies the ad content categories

Definition from IAB Tech Lab
clickThroughUrl string From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

Possible Values:
  • dai
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string MIME type of the current media file specified in the VAST XML
dealId string From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string From the ad XML, provides a long ad description

Definition from IAB Tech Lab
duration number From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm

Definition from IAB Tech Lab
freewheel object Contains the unique ad identifier within its ad.adId property
id string Unique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
mediaFileCompliance boolean Indicates if the ad is mediaFile compliant

To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
nonComplianceReasons array Reasons why mediaFileCompliance has failed
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
podcount number Total number of ads in the pod
request object XML HTTP request to the ad tag URL
response object XML response received from the request
sequence number Returns the order of the ad within the pod
skipoffset number Time in seconds before an ad can be skipped
tag string URL of the ad tag
type string Category of player event

This is always adClick for this event.
universalAdId object From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative

Definition from IAB Tech Lab
vastversion number VAST version reference in the VAST XML
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount number Waterfall count
witem number Waterfall index


.on('adCompanions')

(VAST, IMA) Fires whenever an ad contains companions

{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "<AD_TAG_URL>",
    "adBreakId": "h3utj61mmce1",
    "adPlayId": "h3utj61mmce1",
    "id": "h3utj61mmce1",
    "ima": {},
    "adtitle": "IAB Vast Samples Skippable",
    "adsystem": "GDFP",
    "creativetype": "video/webm",
    "duration": 51,
    "linear": "linear",
    "description": "IAB Vast Samples Skippable ad",
    "creativeAdId": "",
    "adId": "24283604",
    "universalAdId": [
        {
            "universalAdIdRegistry": "AD-ID",
            "universalAdIdValue": "ABCD1234567"
        }
    ],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "file.webm"
    },
    "companions": [
        {
            "width": 300,
            "height": 250,
            "type": "html",
            "resource": "<a target=\"_blank\" id=\"32948875244\" href=\"<URL>\"><div class=\"overlayContainer\"><img src=\"<IMAGE_URL>\" height=\"250\" width=\"300\"><div class=\"overlayTextAttribution\"></div></div><iframe frameborder=\"0\" src=\"<IFRAME_URL>\" height=\"0\" width=\"0\" id=\"iframe734645111\" style=\"border: 0px; vertical-align: bottom; display: block; height: 0px; width: 0px;\"></iframe></a>"
        },
        {
            "width": 728,
            "height": 90,
            "type": "html",
            "resource": "<a target=\"_blank\" id=\"32948875364\" href=\"<URL>\"><div class=\"overlayContainer\"><img src=\"<IMAGE_URL>\" height=\"90\" width=\"728\"><div class=\"overlayTextAttribution\"></div></div><iframe frameborder=\"0\" src=\"<IFRAME_URL>\" height=\"0\" width=\"0\" id=\"iframe849947827\" style=\"border: 0px; vertical-align: bottom; display: block; height: 0px; width: 0px;\"></iframe></a>"
        }
    ],
    "type": "adCompanions"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "1wn8z1bf6tas",
    "adPlayId": "1wn8z1bf6tas",
    "offset": "pre",
    "id": "31d1d4yumxpo",
    "tag": "//playertest-cdn.longtailvideo.com/pre.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 5,
    "adschedule": {...},
    "adtitle": "JW Test Preroll",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 1 qualities",
        "video/webm has only 1 qualities"
    ],
    "mediafile": {
        "file": "//content.bitsontherun.com/videos/1EI2jHpo-52qL9xLP.mp4"
    },
    "viewable": 1,
    "creativetype": "video/mp4",
    "companions": [
        {
            "width": 300,
            "height": 250,
            "type": "static",
            "resource": "//s3.amazonaws.com/qa.jwplayer.com/~alex/300x250_companion_1.swf",
            "creativeview": [
                "http://myTrackingURL/firstCompanion"
            ],
            "click": "http://jwplayer.com/"
        },
        {
            "width": 300,
            "height": 250,
            "type": "static",
            "resource": "//s3.amazonaws.com/qa.jwplayer.com/~alex/pre_300X250.jpg",
            "click": "http://jwplayer.com/"
        },
        {
            "width": 728,
            "height": 90,
            "type": "static",
            "resource": "//s3.amazonaws.com/qa.jwplayer.com/~alex/pre_728X90.jpg",
            "click": "http://jwplayer.com/"
        }
    ],
    "type": "adCompanions"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adId string From the ad XML, identity of the ad server that provides the creative

Definition from IAB Tech Lab
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string From the ad XML, common name for the ad

Definition from IAB Tech Lab
adVerifications object From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
clickThroughUrl string From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

Possible Values:
  • googima
  • vast
companions array Available companion information

See: companions[]
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string MIME type of the current media file specified in the VAST XML
dealId string From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string From the ad XML, provides a long ad description

Definition from IAB Tech Lab
duration number From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm

Definition from IAB Tech Lab
id string Unique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
mediaFileCompliance boolean Indicates if the ad is mediaFile compliant

To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
nonComplianceReasons array Reasons why mediaFileCompliance has failed
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
request object XML HTTP request to the ad tag URL
response object XML response received from the request
sequence number Returns the order of the ad within the pod
skipoffset number Time in seconds before an ad can be skipped
tag string URL of the ad tag
type string Category of player event

This is always adCompanions for this event.
universalAdId object From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative

Definition from IAB Tech Lab
vastversion number VAST version reference in the VAST XML
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount number Waterfall count
witem number Waterfall index

companions[]

PropertyDescription
click string

URL to link to when clicking the companion



This is only available if the type is static.

creativeview arraycreativeview event tracking pixels
height numberHeight of the companion in pixels
resource stringURL to the static/iframe resource or the raw HTML content
type string

Category of creative



Possible Values:
  • html
  • iframe
  • static
width numberWidth of the companion in pixels


.on('adComplete')

Fires whenever an ad has completed playback

{
    "client": "dai",
    "viewable": 1,
    "id": "822vxuovefq0",
    "adPlayId": "g56ap7bne8u0",
    "adtitle": "External NCA1C1L1 Preroll",
    "adsystem": "GDFP",
    "creativetype": "application/x-mpegURL",
    "linear": "linear",
    "adposition": "pre",
    "type": "adComplete"
}
{
    "client": "freewheel",
    "tag": "placeholder_preroll",
    "freewheel": {
        "ad": {
            "adId": "17302931"
        }
    },
    "adposition": "pre",
    "id": "17302931",
    "linear": "linear",
    "creativetype": "video/mp4",
    "viewable": 1,
    "sequence": 1,
    "podcount": 2,
    "skipoffset": 3,
    "type": "adComplete"
}
{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "//playertest-cdn.longtailvideo.com/vast-30s-ad.xml",
    "adBreakId": "lkjkoc1j7e5q",
    "adPlayId": "lkjkoc1j7e5q",
    "id": "lkjkoc1j7e5q",
    "ima": {...},
    "adtitle": "",
    "adsystem": "Alex_Vast",
    "creativetype": "video/mp4",
    "duration": 30,
    "linear": "linear",
    "description": "",
    "creativeAdId": "",
    "adId": "232859236",
    "universalAdId": [],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "//content.jwplatform.com/videos/AEhg3fFb-bPwArWA4.mp4"
    },
    "type": "adComplete"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "a87pfdzx2s35",
    "adPlayId": "a87pfdzx2s35",
    "offset": 10,
    "id": "c2mx5xekbclh",
    "tag": "//playertest-cdn.longtailvideo.com/mid.xml",
    "adposition": "mid",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 5,
    "adschedule": {...},
    "adtitle": "",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {...},
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 2 qualities"
    ],
    "mediafile": {
        "file": "//content.bitsontherun.com/videos/tafrxQYx-bPwArWA4.mp4"
    },
    "viewable": 0,
    "creativetype": "video/mp4",
    "categories": [],
    "type": "adComplete"
}
PropertyDescription
adBreakId string

Unique ID for each ad break



If there are multiple ads in the same ad break, all of the ads will have the same
adBreakId.

adId string

From the ad XML, identity of the ad server that provides the creative



Definition from IAB Tech Lab

adPlayId string

Unique ID for each ad



If there are multiple ads in the same ad break, each ad has a different adPlayId.

adposition string

Position of an ad



Possible Values:
  • mid
  • post
  • pre
adschedule objectSettings for the ad break
adsystem string

From the ad XML, name of the ad server that returned the ad



Definition from IAB Tech Lab

adtitle string

From the ad XML, common name for the ad



Definition from IAB Tech Lab

adVerifications object

From the ad XML, lists resources and metadata required to execute third-party measurement code in
order
to verify creative playback



Definition from IAB Tech Lab

advertiser string

From the ad XML, name of the advertiser as defined by the ad serving party



Definition from IAB Tech Lab

advertiserId string

From the ad XML, optional identifier for the advertiser, provided by the ad server



Definition from IAB Tech Lab

categories array

From the ad XML, list of category codes or labels that identifies the ad content categories



Definition from IAB Tech Lab

clickThroughUrl string

From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the
ad



Definition from IAB Tech Lab

client string

Ad client that is currently being used



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean(VPAID-only) Used to tell the player to not play ads with the conditionalAd
attribute inside of the VAST response
creativeAdId string

From the ad XML, the ad server's unique identifier for the creative



Definition from IAB Tech Lab

creativeId string

From the ad XML, identifier of the ad server that provides the creative



Definition from IAB Tech Lab

creativetype stringMIME type of the current media file specified in the VAST XML
dealId string

From the ad XML, returns the first deal ID present in the wrapper chain for the current ad,
starting from the top



Definition from Google

description string

From the ad XML, provides a long ad description



Definition from IAB Tech Lab

duration number

From the ad XML, time value for the duration of the linear ad in the format
HH:MM:SS.mmm



Definition from IAB Tech Lab

freewheel object Contains the unique ad identifier within its ad.adId property
id stringUnique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the
userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string

Value of the linear attribute of the ad XML



Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object

From the ad XML, contains the video file for a linear ad



Definition from IAB Tech Lab

mediaFileCompliance boolean

Indicates if the ad is mediaFile compliant



To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
nonComplianceReasons array Reasons why mediaFileCompliance has failed
offset number | string

Position of an ad



Possible Values:
  • (Midroll){number in seconds}
  • post
  • pre
placement number

Value sent in a bid request that identifies the location of a player in accordance with updated IAB
Digital Video Guidelines



Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
podcount numberTotal number of ads in the pod
request objectXML HTTP request to the ad tag URL
response object XML response received from the request
sequence numberReturns the order of the ad within the pod
skipoffset numberTime in seconds before an ad can be skipped
tag stringURL of the ad tag
type string

Category of player event



This is always adComplete for this event.

universalAdId object

From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative



Definition from IAB Tech Lab

vastversion numberVAST version reference in the VAST XML
viewable boolean

Viewability of the player



Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount numberWaterfall count
witem numberWaterfall index


.on('adError')

Fires whenever an error prevents the ad from playing

📘

This may fire multiple times for a single ad tag if Google IMA is being used.

{
    "id": "-1",
    "message": "Ad Error: Stream initialization failed because\nHTTP status code: 400 with URL: https://pubads.g.doubleclick.net/ondemand/hls/content/1982sa3/vid/ima-test/streams?...",
    "client": "dai",
    "viewable": 1,
    "type": "adError"
}
{
    "id": "45759844",
    "client": "freewheel",
    "message": "Ad Error: wrapperUrl=https://playertest.longtailvideo.com/adtags/empty-vast-tags.xml",
    "code": "_e_io",
    "module": "VastTranslator",
    "timeLoading": 935,
    "type": "adError"
}
{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "tag": "//playertest-cdn.longtailvideo.com/assets/vast/pre-404.xml?vid_t=Bunny",
    "adBreakId": "587c5b15tpsi",
    "adPlayId": "587c5b15tpsi",
    "id": "587c5b15tpsi",
    "adposition": "pre",
    "message": "Ad Error: There was an error playing the video ad.",
    "code": 400,
    "adErrorCode": 20400,
    "sourceError": {
        "stack": "Error: Error: There was an error playing the video ad.\n    at l.getInnerError (https://imasdk.googleapis.com/js/sdkloader/ima3_debug.js:614:757)\n    at adErrorEventObject (https://player-develop-test-jenkins.longtailvideo.com/builds/lastSuccessfulBuild/archive/bin-debug/googima.js:2737:32)\n    at AdsPlayer.getAdErrorEventObject (https://player-develop-test-jenkins.longtailvideo.com/builds/lastSuccessfulBuild/archive/bin-debug/googima.js:3470:14)\n    at AdsPlayer.handleAdError (https://player-develop-test-jenkins.longtailvideo.com/builds/lastSuccessfulBuild/archive/bin-debug/googima.js:3479:35)\n    at AdsPlayer.adError (https://player-develop-test-jenkins.longtailvideo.com/builds/lastSuccessfulBuild/archive/bin-debug/googima.js:3444:12)\n    at xt (https://imasdk.googleapis.com/js/sdkloader/ima3_debug.js:306:200)\n    at l.dispatchEvent (https://imasdk.googleapis.com/js/sdkloader/ima3_debug.js:304:408)\n    at pH (https://imasdk.googleapis.com/js/sdkloader/ima3_debug.js:642:215)\n    at Z.Mc (https://imasdk.googleapis.com/js/sdkloader/ima3_debug.js:637:94)\n    at xt (https://imasdk.googleapis.com/js/sdkloader/ima3_debug.js:306:200)",
        "message": "Error: There was an error playing the video ad."
    },
    "timeLoading": 242,
    "type": "adError"
}
{
    "client": "vast",
    "placement": 1,
    "item": {
        "sources": [
            {
                "default": false,
                "type": "mp4",
                "file": "//content.bitsontherun.com/videos/bkaovAYt-52qL9xLP.mp4",
                "label": "0",
                "preload": "metadata"
            }
        ],
        "tracks": [],
        "minDvrWindow": 120,
        "file": "//content.bitsontherun.com/videos/bkaovAYt-52qL9xLP.mp4",
        "preload": "metadata",
        "allSources": [
            {
                "default": false,
                "type": "mp4",
                "file": "//content.bitsontherun.com/videos/bkaovAYt-52qL9xLP.mp4",
                "label": "0",
                "preload": "metadata"
            }
        ],
        "feedData": {},
        "chapters": {
            "defaultLanguage": "en-US",
            "timestamps": []
        }
    },
    "message": "VMAP Schema Error: No AdBreaks in VMAP",
    "code": 1002,
    "adErrorCode": 60005,
    "id": "-1",
    "vmap": "//playertest-cdn.longtailvideo.com/ads/empty-vmap.xml",
    "type": "adError"
}

Each response returns the following values.

PropertyDescription
adErrorCode integer (IMA, VAST) JWX ad error code
client string

Ad client that is currently being used



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
code integer (FreeWheel, IMA, VAST) Ad client error code
id string

(DAI) Unique ID for each ad break, typically -1



(FreeWheel) Unique ad identifier

message string

Ad error message



Possible messages
  • ad tag empty: No ad available after searching wrapped ad tags
  • error playing creative: 404 on a creative file
  • error loading ad tag: All additional ad errors
  • invalid ad tag: Invalid XML, Improperly formatted VAST syntax
  • no compatible creatives: FLV video creative or VPAID SWF is attempting to play in HTML5 player
module string(FreeWheel) Freewheel module that triggered the error
type string

Category of player event



This is always adError for this event.

viewable boolean

(DAI) Viewability of the player



Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.



When available, each response includes the following information. Additionally, IMA and VAST responses may include properties from the adBidResponse.

Property Description
adBreakId string (VAST) Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adBreaks array Array of ad break objects
adErrorCode integer (DAI, FreeWheel) JWX ad error code
adId string (IMA, VAST) Unique ID of the ad
adMessage string (VAST) Text that displays time remaining during ad playback
adPlayId string (DAI, IMA, VAST) Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of the ad

Possible Values:
  • mid
  • post
  • pre
adschedule object (VAST) Settings for the ad break
adServingId string (VAST) Unique or pseudo-unique identifier generated by the ad server for each inline VAST ad, and is passed in ad responses and tracking pixels so systems can align impression-level tracking and reconcile ad delivery across platforms
adsystem string (DAI, IMA, VAST) From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string (DAI, IMA, VAST) Common name for the ad
adVerifications object (VAST) From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string (IMA, VAST) From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string (VAST) From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
clickThroughUrl string (VAST) From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
code number (DAI) Ad client error code
companions object (VAST) Companion ads objects
conditionalAd object (VAST) Conditional ad object
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string (IMA, VAST) From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string (VAST) From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string (DAI, FreeWheel, IMA) MIME type of the current media file specified in the VAST XML
dealId string (IMA, VAST) From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string (IMA, VAST) From the ad XML, provides a long ad description

Definition from IAB Tech Lab
duration number (IMA, VAST) Length of the ad, in seconds
freewheel object (FreeWheel) Contains the unique ad identifier within its ad.adId property
id string (IMA, VAST) Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
ima object (IMA, VAST) Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
item object (VAST) Playlist item properties

See: playlist[]
jwpseg string (IMA, VAST) Comma-delimited list of audience or content segments generated for a specific media ID, and is passed in ad requests so buyers can apply targeted bidding and delivery logic
linear string (DAI, FreeWheel, IMA, VAST) Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object (IMA, VAST) From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
mediaFileCompliance boolean (VAST) Indicates if the ad is mediaFile compliant

To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
nonComplianceReasons array (VAST) Reasons why mediaFileCompliance has failed
offset number | string (IMA, VAST) Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number (IMA, VAST) Location of the ad

Possible Values:
  • article
  • banner
  • feed
  • floating
  • instream
  • interstitial
  • slider
podcount number (DAI, FreeWheel, IMA) Total number of ads in the pod
podIndex number (VAST) Position of the current ad within the ad pod
podmessage string (VAST) Text that displays time remaining during playback of an ad pod
preloadAds boolean (IMA, VAST) Pre-requests ad response for an ad break
request object (VAST) XML HTTP request to the ad tag URL
response object (VAST) XML response received from the request
sequence number Returns the order of the ad within the pod
skipoffset number (FreeWheel, VAST) Time in seconds before an ad can be skipped
skipmessage string (VAST) Used to provide a customized skip button countdown message
skiptext string (VAST) Text of the Skip button after the countdown is over
sourceError object (IMA, VAST) Location where the error was triggered in the IMA SDK
tag string (DAI, IMA, VAST) URL of the ad tag

(FreeWheel) Freewheel ad custom ID
tagIndex number (VAST) Position of the current tag within an array of fallback tags
timeLoading number (FreeWheel) Time spent loading ad, in milliseconds
timeout number (IMA, VAST) If error occurred due to timeout, the length of the timeout in milliseconds
universalAdId string (IMA) From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative
vastversion number (VAST) VAST version reference in the VAST XML
vmap object (VAST) VMAP XML
wrapperAdIds object (VAST) Array of the ad IDs for each ad within the VAST wrapper
wrapperAdSystems object (VAST) Array of the VAST wrapper elements’ ad system names
wrapperTags string (VAST) List of all wrapper tag redirects


.on('adImpression')

Fires based on the IAB definition of an ad impression

This occurs the instant a video ad begins to play.

{
    "client": "dai",
    "viewable": 1,
    "id": "z5bbhua8yw00",
    "adPlayId": "7e8jal5j9y80",
    "adtitle": "External NCA1C1L1 Preroll",
    "adsystem": "GDFP",
    "creativetype": "application/x-mpegURL",
    "linear": "linear",
    "adposition": "pre",
    "type": "adImpression"
}
{
    "client": "freewheel",
    "tag": "placeholder_preroll",
    "freewheel": {
        "ad": {
            "adId": "20747694"
        }
    },
    "adposition": "pre",
    "id": "20747694",
    "linear": "linear",
    "creativetype": "video/mp4",
    "viewable": 1,
    "timeLoading": 752,
    "type": "adImpression"
}
{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "//playertest-cdn.longtailvideo.com/vast-30s-ad.xml?vid_t=sintel",
    "adBreakId": "m26lcvab5a1o",
    "adPlayId": "m26lcvab5a1o",
    "id": "m26lcvab5a1o",
    "ima": {...},
    "adtitle": "",
    "adsystem": "Alex_Vast",
    "creativetype": "video/mp4",
    "duration": 30,
    "linear": "linear",
    "description": "",
    "creativeAdId": "",
    "adId": "232859236",
    "universalAdId": [],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "//content.jwplatform.com/videos/AEhg3fFb-bPwArWA4.mp4"
    },
    "timeLoading": 48,
    "type": "adImpression"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "u73yp6nm93y1",
    "adPlayId": "u73yp6nm93y1",
    "offset": "pre",
    "id": "1bfd53080g7t",
    "tag": "//playertest-cdn.longtailvideo.com/pre-60s.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 5,
    "adschedule": {
        "item": 1,
        "breakid": "adbreak1",
        "tags": [
            "//playertest-cdn.longtailvideo.com/pre-60s.xml"
        ],
        "offset": "pre"
    },
    "adtitle": "JW Test Preroll",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "duration": 60,
    "linear": "linear",
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 2 qualities"
    ],
    "mediafile": {
        "file": "//content.jwplatform.com/videos/zz4Abp0Z-bPwArWA4.mp4"
    },
    "viewable": 1,
    "creativetype": "video/mp4",
    "categories": [],
    "timeLoading": 154,
    "type": "adImpression"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adId string From the ad XML, identity of the ad server that provides the creative

Definition from IAB Tech Lab
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string From the ad XML, common name for the ad

Definition from IAB Tech Lab
adVerifications object From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
bidders array (IMA) Bidders which made bids on the ad slot

This is only added if header bidding occurred.

Review the bidder object to see the object properties.
categories array From the ad XML, list of category codes or labels that identifies the ad content categories

Definition from IAB Tech Lab
clickThroughUrl string From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

Possible Values:
  • dai
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string MIME type of the current media file specified in the VAST XML
dealId string From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string From the ad XML, provides a long ad description

Definition from IAB Tech Lab
duration number From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm

Definition from IAB Tech Lab
freewheel object Contains the unique ad identifier within its ad.adId property
id string Unique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
mediaFileCompliance boolean Indicates if the ad is mediaFile compliant

To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
nonComplianceReasons array Reasons why mediaFileCompliance has failed
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
request object XML HTTP request to the ad tag URL
response object XML response received from the request
sequence number Returns the order of the ad within the pod
tag string URL of the ad tag
timeLoading number Loading time of the ad in milliseconds
type string Category of player event

This is always adImpression for this event.
universalAdId object From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative

Definition from IAB Tech Lab
vastversion number VAST version reference in the VAST XML
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount number Waterfall count
witem number Waterfall index
wrapper array (VAST) Ad systems specified in any utilized ad wrappers

An index value denotes the level of the wrapper.


.on('adItem')

Fires when the VAST XML has been parsed, loaded, and is ready for display

{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "{ad_tag_url}",
    "adBreakId": "1a2b3c4d5e6f",
    "adPlayId": "1a2b3c4d5e6f",
    "id": "1a2b3c4d5e6f",
    "ima": {
        ...
    },
    "adtitle": "LinearInlineSkippable",
    "adsystem": "GDFP",
    "creativetype": "video/mp4",
    "duration": 10,
    "linear": "linear",
    "description": "LinearInlineSkippable ad",
    "creativeAdId": "",
    "adId": "123456789",
    "universalAdId": [{
        ...
    }],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "{linear_ad_video_file_url}"
    },
    "type": "adItem"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "6f5e4d3c2b1a",
    "adPlayId": "6f5e4d3c2b1a",
    "offset": "pre",
    "item": {
        ...
    },
    "type": "adItem"
}
PropertyDescription
adBreakId string

Unique ID for each ad break



If there are multiple ads in the same ad break, all of the ads will have the same
adBreakId.

adId string

From the ad XML, identity of the ad server that provides the creative



Definition from IAB Tech Lab

adPlayId string

Unique ID for each ad



If there are multiple ads in the same ad break, each ad has a different adPlayId.

adposition string

Position of an ad



Possible Values:
  • mid
  • post
  • pre
adsystem string

From the ad XML, name of the ad server that returned the ad



Definition from IAB Tech Lab

adtitle string

From the ad XML, common name for the ad



Definition from IAB Tech Lab

advertiser string

From the ad XML, name of the advertiser as defined by the ad serving party



Definition from IAB Tech Lab

client string

Ad client that is currently being used



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
creativeAdId string

From the ad XML, the ad server's unique identifier for the creative



Definition from IAB Tech Lab

creativetype stringMIME type of the current media file specified in the VAST XML
dealId string

From the ad XML, returns the first deal ID present in the wrapper chain for the current ad,
starting from the top



Definition from Google

description string

From the ad XML, provides a long ad description



Definition from IAB Tech Lab

duration number

From the ad XML, time value for the duration of the linear ad in the format
HH:MM:SS.mmm



Definition from IAB Tech Lab

id stringUnique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
item objectPlaylist item that is currently being played as the content
linear string

Value of the linear attribute of the ad XML



Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediaFile object

From the ad XML, contains the video file for a linear ad



Definition from IAB Tech Lab

offset number | string

Position of an ad



Possible Values:
  • (Midroll){number in seconds}
  • post
  • pre
placement number

Value sent in a bid request that identifies the location of a player in accordance with updated IAB
Digital Video Guidelines



Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more
information, read List: Plcmt Subtypes - Video
sequence numberReturns the order of the ad within the pod
tag stringURL of the ad tag
type string

Category of player event



This is always adItem for this event.

universalAdId object

From the ad XML, unique creative identifier that is maintained across systems for the purpose of
tracking ad creative



Definition from IAB Tech Lab

viewable boolean

Viewability of the player



Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.


.on('adLoaded')

Fires when the VAST XML has been parsed, loaded, and is ready for display

{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "{ad_tag_url}",
    "adBreakId": "1a3c2b4d5e6f",
    "adPlayId": "1a3c2b4d5e6f",
    "id": "1a3c2b4d5e6f",
    "ima": {
        ...
    },
    "adtitle": "",
    "adsystem": "GDFP",
    "creativetype": "video/mp4",
    "duration": 10,
    "linear": "linear",
    "description": "",
    "creativeAdId": "",
    "adId": "232859236",
    "universalAdId": [],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "{linear_ad_video_file_url}"
    },
    "type": "adLoaded"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "1a2b3c4d5e6f",
    "adPlayId": "1a2b3c4d5e6f",
    "offset": "pre",
    "id": "dlsjb0-test",
    "tag": "{ad_tag_url}",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "",
    "adschedule": {
        ...
    },
    "item": {
        ...
    },
    "timeLoading": 57,
    "type": "adLoaded"
}
PropertyDescription
adBreakId string

Unique ID for each ad break



If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.

adId string

From the ad XML, identity of the ad server that provides the creative



Definition derived from IAB Tech Lab

adPlayId string

Unique ID for each ad



If there are multiple ads in the same ad break, each ad has a different adPlayId.

adposition string

Position of the ad



Possible Values:
  • mid
  • post
  • pre
adschedule objectAd break information
adsystem stringFrom the ad XML, name of the ad server that returned the ad
adtitle string

From the ad XML, common name for the ad



Definition derived from IAB Tech Lab

advertiser string

From the ad XML, name of the advertiser as defined by the ad serving party



Definition derived from IAB Tech Lab

client string

The client that is currently being used



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
creativeAdId string

From the ad XML, the ad server’s unique identifier for the creative



Definition derived from IAB Tech Lab

creativetype stringMIME type of the current media file specified in the ad XML
dealId string

From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top



Definition derived from Google

description string

From the ad XML, provides a long ad description



Definition derived from IAB Tech Lab

duration number

From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm



Definition derived from IAB Tech Lab

id stringUnique ad ID
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
item objectPlaylist item that is currently being played as the content
linear string

Value of the linear attribute of the ad XML



Possible Values:
  • linear
  • nonlinear
mediaFile object

From the ad XML, contains the video file for a linear ad



Definition derived from IAB Tech Lab

offset number | string

Position of an ad



Possible Values:
  • {number in seconds} (This occurs for mid-roll ads)
  • post
  • pre
placement string

Value sent in a bid request that identifies the location of a player



Possible Values:
  • article
  • banner
  • feed
  • floating
  • instream
  • interstitial
  • slider
sequence numberReturns the order of the ad within the pod
tag stringURL of the ad tag
timeLoading integerTime the ad took to load in milliseconds
type string

Category of the player event



This is always adLoaded for the event.

universalAdId object

From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative



Definition derived from IAB Tech Lab

viewable number

Indicates if the player is viewable or not



Possible Values:
  • 0
  • 1
wcount numberWaterfall count
witem numberWaterfall index


.on('adManager')

Starting with JW 8.8.0, use .on('adsManager')

FreeWheel only. Fires when the ad manager is loaded into the player.

This event allows publishers to integrate additional FreeWheel ad manager functionality before ad playback.

Response

This event returns an object similar to the following:

{
  "adManager": {...},
  "type": "adManager"
}
PropertyDescription
adManager objectObject containing the ad manager configuration
type string

Category of the player event



This is always adManager for this event.



.on('adMeta')

(VAST) Continuously triggers when new metadata has been received from the ad by the player

Values may vary based on the ad itself.

{
    "client": "vast",
    "placement": 1,
    "adBreakId": "vy8zfpt58kw4",
    "adPlayId": "vy8zfpt58kw4",
    "offset": "pre",
    "id": "jmxfy711x9xh",
    "tag": "//playertest-cdn.longtailvideo.com/pre.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 3,
    "adschedule": {
        "item": 1,
        "breakid": "myAds",
        "tags": [
            "//playertest-cdn.longtailvideo.com/pre.xml"
        ],
        "offset": "pre"
    },
    "adtitle": "JWX Test Preroll",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "linear": "linear",
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 1 qualities",
        "video/webm has only 1 qualities"
    ],
    "mediafile": {
        "file": "//content.bitsontherun.com/videos/1EI2jHpo-52qL9xLP.mp4"
    },
    "viewable": 1,
    "creativetype": "video/mp4",
    "categories": [],
    "adMessage": "This ad will end in xx",
    "companions": [
        {
            "width": 728,
            "height": 90,
            "type": "image/jpeg",
            "source": "//s3.amazonaws.com/qa.jwplayer.com/~alex/pre_728X90.jpg",
            "trackers": {
                "creativeView": [
                    "http://myTrackingURL/firstCompanion"
                ]
            },
            "clickthrough": "http://jwplayer.com/"
        }
    ],
    "skipMessage": "Skip in xx",
    "skipText": "Skip",
    "type": "adMeta"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adId string From the ad XML, identity of the ad server that provides the creative

Definition from IAB Tech Lab
adMessage string Text that displays during ad playback

Definition from IAB Tech Lab
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string From the ad XML, common name for the ad

Definition from IAB Tech Lab
adVerifications object From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
categories array From the ad XML, list of category codes or labels that identifies the ad content categories

Definition from IAB Tech Lab
clickThroughUrl string From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

This value is always vast
companions array Available companion information

See: adMeta companions[]
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string MIME type of the current media file specified in the VAST XML
dealId string From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string From the ad XML, provides a long ad description

Definition from IAB Tech Lab
id string Unique ad identifier
linear string Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile object From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
mediaFileCompliance boolean Indicates if the ad is mediaFile compliant

To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
request object XML HTTP request to the ad tag URL
response object XML response received from the request
sequence number Returns the order of the ad within the pod
skipMessage string Used to provide a customized countdown message
skipoffset number Time in seconds before an ad can be skipped
skipText string Text of the Skip button after the countdown is over
tag string URL of the ad tag
type string Category of player event

This is always adMeta for this event.
vastversion number VAST version reference in the VAST XML
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount number Waterfall count
witem number Waterfall index

adMeta companions[]

PropertyDescription
clickthrough string

URL to link to when clicking the companion



This is only available if the type is static.

height numberHeight of the companion in pixels
source stringURL of the creative
trackers objectThird-party tracking URLs for the companion unit
type string

Category of creative



Possible Values:
  • html
  • iframe
  • static
width numberWidth of the companion in pixels


.on('adPause')

Fires whenever an ad is paused

{
    "newstate": "paused",
    "type": "adPause",
    "oldstate": "playing"
}
{
    "oldstate": "playing",
    "client": "freewheel",
    "tag": "placeholder_preroll",
    "freewheel": {
        "ad": {
            "adId": "17302931"
        }
    },
    "adposition": "pre",
    "id": "17302931",
    "linear": "linear",
    "creativetype": "video/mp4",
    "viewable": 1,
    "sequence": 1,
    "podcount": 2,
    "skipoffset": 3,
    "newstate": "paused",
    "pauseReason": "interaction",
    "type": "adPause"
}
{
    "oldstate": "playing",
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "//playertest-cdn.longtailvideo.com/vast-30s-ad.xml",
    "adBreakId": "1wskqlynd4xz",
    "adPlayId": "1wskqlynd4xz",
    "id": "1wskqlynd4xz",
    "ima": {...},
    "adtitle": "",
    "adsystem": "Alex_Vast",
    "creativetype": "video/mp4",
    "duration": 30,
    "linear": "linear",
    "description": "",
    "creativeAdId": "",
    "adId": "232859236",
    "universalAdId": [],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "//content.jwplatform.com/videos/AEhg3fFb-bPwArWA4.mp4"
    },
    "newstate": "paused",
    "pauseReason": "interaction",
    "type": "adPause"
}
{
    "oldstate": "playing",
    "client": "vast",
    "placement": 1,
    "adBreakId": "rtcr7l1md0og",
    "adPlayId": "rtcr7l1md0og",
    "offset": "pre",
    "id": "1njnx9fbk02y",
    "tag": "//playertest-cdn.longtailvideo.com/pre-60s.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 5,
    "adschedule": {...},
    "adtitle": "JW Test Preroll",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 2 qualities"
    ],
    "mediafile": {
        "file": "//content.jwplatform.com/videos/zz4Abp0Z-bPwArWA4.mp4"
    },
    "viewable": 1,
    "creativetype": "video/mp4",
    "categories": [],
    "newstate": "paused",
    "pauseReason": "interaction",
    "type": "adPause"
}
PropertyDescription
adBreakId string

Unique ID for each ad break



If there are multiple ads in the same ad break, all of the ads will have the same
adBreakId.

adId string

From the ad XML, identity of the ad server that provides the creative



Definition from IAB Tech Lab

adPlayId string

Unique ID for each ad



If there are multiple ads in the same ad break, each ad has a different adPlayId.

adposition string

Position of an ad



Possible Values:
  • mid
  • post
  • pre
adschedule objectSettings for the ad break
adsystem string

From the ad XML, name of the ad server that returned the ad



Definition from IAB Tech Lab

adtitle string

From the ad XML, common name for the ad



Definition from IAB Tech Lab

adVerifications object

From the ad XML, lists resources and metadata required to execute third-party measurement code in order
to verify creative playback



Definition from IAB Tech Lab

advertiser string

From the ad XML, name of the advertiser as defined by the ad serving party



Definition from IAB Tech Lab

advertiserId string

From the ad XML, optional identifier for the advertiser, provided by the ad server



Definition from IAB Tech Lab

categories array

From the ad XML, list of category codes or labels that identifies the ad content categories



Definition from IAB Tech Lab

clickThroughUrl string

From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad



Definition from IAB Tech Lab

client string

Ad client that is currently being used



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean(VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string

From the ad XML, the ad server's unique identifier for the creative



Definition from IAB Tech Lab

creativeId string

From the ad XML, identifier of the ad server that provides the creative



Definition from IAB Tech Lab

creativetype stringMIME type of the current media file specified in the VAST XML
dealId string

From the ad XML, returns the first deal ID present in the wrapper chain for the current ad,
starting from the top



Definition from Google

description string

From the ad XML, provides a long ad description



Definition from IAB Tech Lab

duration number

From the ad XML, time value for the duration of the linear ad in the format
HH:MM:SS.mmm



Definition from IAB Tech Lab

freewheel object Contains the unique ad identifier within its ad.adId property
id stringUnique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string

Value of the linear attribute of the ad XML



Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object

From the ad XML, contains the video file for a linear ad



Definition from IAB Tech Lab

mediaFileCompliance boolean

Indicates if the ad is mediaFile compliant



To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
newstate string

New state of the player



This is always paused for this event.

offset number | string

Position of an ad



Possible Values:
  • (Midroll){number in seconds}
  • post
  • pre
oldstate string

State of the player prior to ad pause



This is always paused for this event.

pauseReason8.7.0+ string

Reason ad playback has been paused



Possible Values:
  • clickthrough: Viewer clicked an ad
  • external: Native VPAID controls or jwplayer().pauseAd()
  • interaction: Viewer clicked the pause control on the player
placement number

Value sent in a bid request that identifies the location of a player in accordance with updated IAB
Digital Video Guidelines



Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more
information, read List: Plcmt Subtypes - Video
podcount numberTotal number of ads in the pod
request objectXML HTTP request to the ad tag URL
response object XML response received from the request
sequence numberReturns the order of the ad within the pod
skipoffset numberTime in seconds before an ad can be skipped
tag stringURL of the ad tag
type string

Category of player event



This is always adPause for this event.

universalAdId object

From the ad XML, unique creative identifier that is maintained across systems for the purpose of
tracking ad creative



Definition from IAB Tech Lab

vastversion numberVAST version reference in the VAST XML
viewable boolean

Viewability of the player



Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount numberWaterfall count
witem numberWaterfall index


.on('adPlay')

Fires whenever an ad starts playing or when an ad is unpaused

{
    "client": "dai",
    "viewable": 1,
    "id": "cfau4gxh3q00",
    "adPlayId": "of0i8kj1tkp0",
    "adtitle": "External NCA1C1L1 Preroll",
    "adsystem": "GDFP",
    "creativetype": "application/x-mpegURL",
    "linear": "linear",
    "adposition": "pre",
    "newstate": "playing",
    "oldstate": "playing",
    "type": "adPlay"
}
{
    "oldstate": "buffering",
    "client": "freewheel",
    "tag": "placeholder_preroll",
    "freewheel": {
        "ad": {
            "adId": "17302931"
        }
    },
    "adposition": "pre",
    "id": "17302931",
    "linear": "linear",
    "creativetype": "video/mp4",
    "viewable": 1,
    "sequence": 1,
    "skipoffset": 3,
    "newstate": "playing",
    "playReason": "interaction",
    "type": "adPlay"
}
{
    "oldstate": "buffering",
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "//playertest-cdn.longtailvideo.com/vast-30s-ad.xml",
    "adBreakId": "lbvj8f1bk67a",
    "adPlayId": "lbvj8f1bk67a",
    "id": "lbvj8f1bk67a",
    "ima": {...},
    "adtitle": "",
    "adsystem": "Alex_Vast",
    "creativetype": "video/mp4",
    "duration": 30,
    "linear": "linear",
    "description": "",
    "creativeAdId": "",
    "adId": "232859236",
    "universalAdId": [],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "//content.jwplatform.com/videos/AEhg3fFb-bPwArWA4.mp4"
    },
    "newstate": "playing",
    "playReason": "interaction",
    "type": "adPlay"
}
{
    "oldstate": "buffering",
    "client": "vast",
    "placement": 1,
    "adBreakId": "rtcr7l1md0og",
    "adPlayId": "rtcr7l1md0og",
    "offset": "pre",
    "id": "1njnx9fbk02y",
    "tag": "//playertest-cdn.longtailvideo.com/pre-60s.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 5,
    "adschedule": {
        "item": 1,
        "breakid": "adbreak1",
        "tags": [
            "//playertest-cdn.longtailvideo.com/pre-60s.xml"
        ],
        "offset": "pre"
    },
    "adtitle": "JW Test Preroll",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 2 qualities"
    ],
    "mediafile": {
        "file": "//content.jwplatform.com/videos/zz4Abp0Z-bPwArWA4.mp4"
    },
    "viewable": 1,
    "creativetype": "video/mp4",
    "categories": [],
    "newstate": "playing",
    "playReason": "interaction",
    "type": "adPlay"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adId string From the ad XML, identity of the ad server that provides the creative

Definition from IAB Tech Lab
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string From the ad XML, common name for the ad

Definition from IAB Tech Lab
adVerifications object From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
categories array From the ad XML, list of category codes or labels that identifies the ad content categories

Definition from IAB Tech Lab
clickThroughUrl string From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

Possible Values:
  • dai
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string MIME type of the current media file specified in the VAST XML
dealId string From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string From the ad XML, provides a long ad description

Definition from IAB Tech Lab
duration number From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm

Definition from IAB Tech Lab
freewheel object Contains the unique ad identifier within its ad.adId property
id string Unique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
newstate string New state of the player

This value will be playing.
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
oldstate string State of the player prior to ad play
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
playReason string Reason for the play

Possible Values:
  • autostart
  • external: API usage
  • interaction: Click, touch, keyboard
  • playlist: Auto-advancing
  • related-audio: Auto-advancing a Recommendations playlist
  • related-interaction: Interaction to go to a Recommendations playlist item
request object XML HTTP request to the ad tag URL
response object XML response received from the request
sequence number Returns the order of the ad within the pod
skipoffset number Time in seconds before an ad can be skipped
tag string URL of the ad tag
type string Category of player event

This is always adPlay for this event.
universalAdId object From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative

Definition from IAB Tech Lab
vastversion number VAST version reference in the VAST XML
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount number Waterfall count
witem number Waterfall index


.on('adRequest')

Fires whenever an ad is requested by the player

{
    "client": "freewheel",
    "networkid": "90750",
    "type": "adRequest"
}
{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "tag": "//playertest-cdn.longtailvideo.com/vast-30s-ad.xml",
    "adBreakId": "lbvj8f1bk67a",
    "adPlayId": "lbvj8f1bk67a",
    "id": "lbvj8f1bk67a",
    "adposition": "pre",
    "type": "adRequest"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "rtcr7l1md0og",
    "adPlayId": "rtcr7l1md0og",
    "offset": "pre",
    "id": "1njnx9fbk02y",
    "tag": "//playertest-cdn.longtailvideo.com/pre-60s.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "",
    "skipoffset": 5,
    "adschedule": {
      "item": 1,
      "breakid": "adbreak1",
      "tags": [
        "//playertest-cdn.longtailvideo.com/pre-60s.xml"
      ],
      "offset": "pre"
    },
    "item": {...},
    "type": "adRequest"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

Possible Values:
  • dai
  • freewheel
  • googima
  • vast
id string Unique ad identifier
item object Playlist item that is currently being played as the content
networkid string FreeWheel identifier of a network

Example: 90750
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
sequence number Returns the order of the ad within the pod
skipoffset number Time in seconds before an ad can be skipped
tag string URL of the ad tag
type string Category of player event

This is always adRequest for this event.
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount number Waterfall count
witem number Waterfall index


.on('adRequestedContentResume')

(IMA, VAST) Fires when one of the following events occurs: an ad completes, an error is triggered, or the ad is skipped

This event signals the transition back to content playback.

Object returned

{
    "type": "adRequestedContentResume"
}
PropertyDescription
type string

Type of event



This is always adRequestedContentResume for this event.



.on('adSchedule')

(VAST) Fires when the ad schedule is loaded and parsed by the plugin

{
    "client": "vast",
    "placement": 1,
    "item": {...},
    "tag": null,
    "adbreaks": [
        {
            "offset": "pre",
            "adbreak": {
                "item": 1,
                "breakid": "adbreak1",
                "tags": [
                    "//playertest-cdn.longtailvideo.com/pre-60s.xml"
                ]
            }
        },
        {
            "offset": 15,
            "adbreak": {
                "item": 2,
                "breakid": "adbreak2",
                "tags": [
                    "//playertest-cdn.longtailvideo.com/pre-60s.xml"
                ]
            }
        },
        {
            "offset": "post",
            "adbreak": {
                "item": 3,
                "breakid": "adbreak3",
                "tags": [
                    "//playertest-cdn.longtailvideo.com/vast-30s-ad.xml"
                ]
            }
        }
    ],
    "type": "adSchedule"
}
PropertyDescription
adbreaks arrayAn array of objects, each containing information about an ad break
client string

Ad client that is currently being used



This is always vast for this event.

item objectPlaylist item that is currently being played as the content
placement number

Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines



Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
tag stringURL of the ad tag
type string

Category of player event



This is always adSchedule for this event.



.on('adLoadedXML')

VAST only. Fires when the VAST ad client loads an ad tag. The response contains an XML parameter that exposes the XML downloaded from the tag as well as the same object properties as other ad events, such as adBreakId, adPlayId, adPosition, client, and tag.



.on('adSkipped')

Fires whenever an ad has been skipped

{
    "client": "freewheel",
    "tag": "placeholder_preroll",
    "freewheel": {
        "ad": {
            "adId": "17302931"
        }
    },
    "adposition": "pre",
    "id": "17302931",
    "linear": "linear",
    "creativetype": "video/mp4",
    "viewable": 1,
    "sequence": 1,
    "podcount": 2,
    "skipoffset": 3,
    "type": "adSkipped"
}
{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "//pubads.g.doubleclick.net/gampad/ads...etc",
    "adBreakId": "wdglp2rmb9qe",
    "adPlayId": "wdglp2rmb9qe",
    "id": "wdglp2rmb9qe",
    "ima": {...},
    "adtitle": "External NCA1C1L1 LinearInlineSkippable",
    "adsystem": "GDFP",
    "creativetype": "video/mp4",
    "duration": 10,
    "linear": "linear",
    "description": "External NCA1C1L1 LinearInlineSkippable ad",
    "creativeAdId": "",
    "adId": "697200496",
    "universalAdId": [
        {
            "universalAdIdRegistry": "GDFP",
            "universalAdIdValue": "57860459056"
        }
    ],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": ""
    },
    "type": "adSkipped"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "mlhd5f15zf6p",
    "adPlayId": "mlhd5f15zf6p",
    "offset": "pre",
    "id": "tfdpe61g5v1f",
    "tag": "//playertest-cdn.longtailvideo.com/pre-60s.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 5,
    "adschedule": {
        "item": 1,
        "breakid": "adbreak1",
        "tags": [
            "//playertest-cdn.longtailvideo.com/pre-60s.xml"
        ],
        "offset": "pre"
    },
    "adtitle": "JW Test Preroll",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "duration": 60,
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 2 qualities"
    ],
    "mediafile": {
        "file": "//content.jwplatform.com/videos/zz4Abp0Z-bPwArWA4.mp4"
    },
    "viewable": 1,
    "creativetype": "video/mp4",
    "categories": [],
    "position": 5.777861,
    "watchedPastSkipPoint": 0.7778609999999997,
    "type": "adSkipped"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adId string From the ad XML, identity of the ad server that provides the creative

Definition from IAB Tech Lab
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string From the ad XML, common name for the ad

Definition from IAB Tech Lab
adVerifications object From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
categories array From the ad XML, list of category codes or labels that identifies the ad content categories

Definition from IAB Tech Lab
clickThroughUrl string From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

Possible Values:
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string MIME type of the creative
dealId string From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string From the ad XML, provides a long ad description

Definition from IAB Tech Lab
duration number From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm

Definition from IAB Tech Lab
freewheel object Contains the unique ad identifier within its ad.adId property
id string Unique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
mediaFileCompliance boolean Indicates if the ad is mediaFile compliant

To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
nonComplianceReasons array Reasons why mediaFileCompliance has failed
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
podcount number Total number of ads in the pod
position number Current playback position in the ad creative in seconds
request object XML HTTP request to the ad tag URL
response object XML response received from the request
sequence number Returns the order of the ad within the pod
skipoffset number Time in seconds before an ad can be skipped
tag string URL of the ad tag
type string Category of player event

This is always adSkipped for this event.
universalAdId object From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative

Definition from IAB Tech Lab
vastversion number VAST version reference in the VAST XML
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
watchedPastSkipPoint number Time that elapsed while the ad was skippable before the user skipped it
wcount number Waterfall count
witem number Waterfall index


.on('adStarted')

(VAST [VPAID], FreeWheel [VPAID], IMA [All ads]) Fires when an ad creative signals to the JWX player that it is starting

{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "//playertest-cdn.longtailvideo.com/vpaid2-jwp-30s.xml?vid_t=Bunny",
    "adBreakId": "179y6cu228me",
    "adPlayId": "179y6cu228me",
    "id": "179y6cu228me",
    "ima": {...},
    "adtitle": "VPAID 2 Linear",
    "adsystem": "Ad System",
    "creativetype": "application/javascript",
    "duration": 30,
    "linear": "linear",
    "description": "VPAID 2 Linear Video Ad",
    "creativeAdId": "",
    "adId": "1234567",
    "universalAdId": [],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": "//playertest.longtailvideo.com/vpaid-2-player-test.js"
    },
    "type": "adStarted"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "hd7kj31r2jpu",
    "adPlayId": "hd7kj31r2jpu",
    "offset": "pre",
    "id": "1020ed21wj9r",
    "tag": "//playertest-cdn.longtailvideo.com/vast/adpod-first-vpaid.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Ad System",
    "wrapperAdSystem": [
        "Alex_Vast",
        "Alex_Vast"
    ],
    "wrappedTags": [
        "https://playertest.longtailvideo.com/vpaid2-jwp-30s.xml",
        "//playertest.longtailvideo.com/pre.xml",
        "//playertest.longtailvideo.com/mid.xml"
    ],
    "wrapperAdIds": [
        "lr3"
    ],
    "adschedule": {
        "item": 1,
        "tags": [
            "//playertest-cdn.longtailvideo.com/vast/adpod-first-vpaid.xml"
        ],
        "offset": "pre"
    },
    "adtitle": "VPAID 2 Linear",
    "description": "VPAID 2 Linear Video Ad",
    "adId": "1234567",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 3,
    "clickThroughUrl": "http://google.com",
    "mediaFileCompliance": true,
    "mediafile": {
        "file": "//playertest.longtailvideo.com/vpaid-2-player-test.js"
    },
    "viewable": 1,
    "podcount": 3,
    "creativetype": "application/javascript",
    "categories": [],
    "type": "adStarted"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adId string From the ad XML, identity of the ad server that provides the creative

Definition from IAB Tech Lab
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string From the ad XML, common name for the ad

Definition from IAB Tech Lab
adVerifications object From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
categories array From the ad XML, list of category codes or labels that identifies the ad content categories

Definition from IAB Tech Lab
clickThroughUrl string From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

Possible Values:
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string MIME type of the VPAID creative
dealId string From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string From the ad XML, provides a long ad description

Definition from IAB Tech Lab
duration number From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm

Definition from IAB Tech Lab
freewheel object Contains the unique ad identifier within its ad.adId property
id string Unique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
mediaFileCompliance boolean Indicates if the ad is mediaFile compliant

To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
podcount number Total number of ads in the pod
request object XML HTTP request to the ad tag URL
response object XML response received from the request
sequence number Returns the order of the ad within the pod
tag string URL of the ad tag
type string Category of player event

This is always adStarted for this event.
universalAdId object From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative

Definition from IAB Tech Lab
vastversion number VAST version reference in the VAST XML
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount number Waterfall count
witem number Waterfall index


.on('adTime')

Fires while ad playback is in progress

{
    "client": "dai",
    "viewable": 1,
    "id": "cz1a5nqne800",
    "adPlayId": "6xszr0hh2v90",
    "adtitle": "External NCA1C1L3 Midroll",
    "adsystem": "GDFP",
    "creativetype": "application/x-mpegURL",
    "linear": "linear",
    "adposition": "mid",
    "position": 0.48821499999999673,
    "duration": 10.01,
    "type": "adTime"
}
{
    "client": "freewheel",
    "tag": "placeholder_midroll",
    "freewheel": {
        "ad": {
            "adId": "17302933"
        }
    },
    "adposition": "mid",
    "id": "17302933",
    "linear": "linear",
    "creativetype": "video/mp4",
    "viewable": 1,
    "sequence": 1,
    "podcount": 2,
    "skipoffset": 3,
    "position": 3.393394,
    "duration": 30,
    "type": "adTime"
}
{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "//pubads.g.doubleclick.net/gampad/ads?sz=640x480...etc",
    "adBreakId": "1n822171mob5",
    "adPlayId": "1n822171mob5",
    "id": "1n822171mob5",
    "ima": {...},
    "adtitle": "External NCA1C1L1 LinearInlineSkippable",
    "adsystem": "GDFP",
    "creativetype": "video/mp4",
    "duration": 10,
    "linear": "linear",
    "description": "External NCA1C1L1 LinearInlineSkippable ad",
    "creativeAdId": "",
    "adId": "697200496",
    "universalAdId": [
        {
            "universalAdIdRegistry": "GDFP",
            "universalAdIdValue": "57860459056"
        }
    ],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        "file": ""
    },
    "position": 0,
    "type": "adTime"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "mlhd5f15zf6p",
    "adPlayId": "mlhd5f15zf6p",
    "offset": "pre",
    "id": "tfdpe61g5v1f",
    "tag": "//playertest-cdn.longtailvideo.com/pre-60s.xml",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Alex_Vast",
    "skipoffset": 5,
    "adschedule": {
        "item": 1,
        "breakid": "adbreak1",
        "tags": [
            "//playertest-cdn.longtailvideo.com/pre-60s.xml"
        ],
        "offset": "pre"
    },
    "adtitle": "JW Test Preroll",
    "description": "",
    "adId": "232859236",
    "adVerifications": null,
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        "location": null
    },
    "conditionalAdOptOut": false,
    "vastversion": 2,
    "clickThroughUrl": "//jwplayer.com/",
    "duration": 60,
    "mediaFileCompliance": false,
    "nonComplianceReasons": [
        "video/mp4 has only 2 qualities"
    ],
    "mediafile": {
        "file": "//content.jwplatform.com/videos/zz4Abp0Z-bPwArWA4.mp4"
    },
    "viewable": 1,
    "creativetype": "video/mp4",
    "position": 5.777861,
    "type": "adTime"
}
Property Description
adBreakId string Unique ID for each ad break

If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.
adId string From the ad XML, identity of the ad server that provides the creative

Definition from IAB Tech Lab
adPlayId string Unique ID for each ad

If there are multiple ads in the same ad break, each ad has a different adPlayId.
adposition string Position of an ad

Possible Values:
  • mid
  • post
  • pre
adschedule object Settings for the ad break
adsystem string From the ad XML, name of the ad server that returned the ad

Definition from IAB Tech Lab
adtitle string From the ad XML, common name for the ad

Definition from IAB Tech Lab
adVerifications object From the ad XML, lists resources and metadata required to execute third-party measurement code in order to verify creative playback

Definition from IAB Tech Lab
advertiser string From the ad XML, name of the advertiser as defined by the ad serving party

Definition from IAB Tech Lab
advertiserId string From the ad XML, optional identifier for the advertiser, provided by the ad server

Definition from IAB Tech Lab
clickThroughUrl string From the ad XML, URI to the advertiser's site that the media player opens when a viewer clicks the ad

Definition from IAB Tech Lab
client string Ad client that is currently being used

Possible Values:
  • dai
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeAdId string From the ad XML, the ad server's unique identifier for the creative

Definition from IAB Tech Lab
creativeId string From the ad XML, identifier of the ad server that provides the creative

Definition from IAB Tech Lab
creativetype string MIME type of the current media file specified in the VAST XML
dealId string From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top

Definition from Google
description string From the ad XML, provides a long ad description

Definition from IAB Tech Lab
duration number From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm

Definition from IAB Tech Lab
freewheel object Contains the unique ad identifier within its ad.adId property
id string Unique ad identifier
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string Value of the linear attribute of the ad XML

Possible Values:
  • linear: Video ad that interrupts video content playback
  • nonlinear Static display ad that overlays a portion of the player and does not interrupt playback
mediafile | mediaFile object From the ad XML, contains the video file for a linear ad

Definition from IAB Tech Lab
mediaFileCompliance boolean Indicates if the ad is mediaFile compliant

To be compliant, one of the following conditions must be met:
  • .m3u8
  • VPAID
  • At least three quality level per MIME type
nonComplianceReasons array Reasons why mediaFileCompliance has failed
offset number | string Position of an ad

Possible Values:
  • (Midroll) {number in seconds}
  • post
  • pre
placement number Value sent in a bid request that identifies the location of a player in accordance with updated IAB Digital Video Guidelines

Possible Values:
  • 1: Instream
  • 2: Accompanying Content
  • 3: Interstitials
  • 4: No Content / Standalone
This value is sent using the plcmt attribute in Object:Video. For more information, read List: Plcmt Subtypes - Video
position number Current playback position in the ad creative in seconds
request object XML HTTP request to the ad tag URL
response object XML response received from the request
sequence number Returns the order of the ad within the pod
skipoffset number Time in seconds before an ad can be skipped
tag string URL of the ad tag
type string Category of player event

This is always adTime for this event.
universalAdId object From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative

Definition from IAB Tech Lab
vastversion number VAST version reference in the VAST XML
viewable boolean Viewability of the player

Possible Values:
  • 0: Player is not in view.
  • 1: Player is in view.
wcount number Waterfall count
witem number Waterfall index


.on('adViewableImpression')

VAST and IMA. Fires only when both of the following conditions are met:

  • Ad has played for two consecutive seconds
  • At least 50% of the player is in the viewport.

Use the adViewableImpression to track the viewability of your ad impressions. The ad viewable impressions metric is comparable to Google's TrueView viewable impression metric.

{
    "client": "googima",
    "placement": 1,
    "viewable": 1,
    "adposition": "pre",
    "tag": "{google_ad_tag}",
    "adBreakId": "1a2b3c4d5e6f",
    "adPlayId": "1a2b3c4d5e6f",
    "id": "1a2b3c4d5e6f",
    "ima": {
        ...
    },
    "adtitle": "External Linear Inline",
    "adsystem": "GDFP",
    "creativetype": "video/mp4",
    "duration": 10,
    "linear": "linear",
    "description": "External Linear Inline ad",
    "creativeAdId": "",
    "adId": "697x312-p",
    "universalAdId": [{
        ...
    }],
    "advertiser": "",
    "dealId": "",
    "mediaFile": {
        ...
    },
    "type": "adViewableImpression"
}
{
    "client": "vast",
    "placement": 1,
    "adBreakId": "f61a2b3c4d5e",
    "adPlayId": "f61a2b3c4d5e",
    "offset": "pre",
    "id": "f61a2b3c4d5e",
    "tag": "{ad_tag_url}",
    "adposition": "pre",
    "sequence": 1,
    "witem": 1,
    "wcount": 1,
    "adsystem": "Ad System",
    "adschedule": {
        ...
    },
    "adtitle": "VPAID 2 Linear",
    "description": "VPAID 2 Linear Video Ad",
    "adId": "1234567",
    "advertiser": "",
    "advertiserId": "",
    "creativeId": "",
    "creativeAdId": "",
    "dealId": "",
    "request": {},
    "response": {
        ...
    },
    "conditionalAdOptOut": false,
    "vastversion": 3,
    "clickThroughUrl": "https://click-through-url.com",
    "mediaFileCompliance": true,
    "mediafile": {
        ...
    },
    "viewable": 1,
    "creativetype": "application/javascript",
    "type": "adViewableImpression"
}
PropertyDescription
adBreakId string

Unique ID for each ad break



If there are multiple ads in the same ad break, all of the ads will have the same adBreakId.

adId string

From the ad XML, identity of the ad server that provides the creative



Definition derived from IAB Tech Lab

adPlayId string

Unique ID for each ad



If there are multiple ads in the same ad break, each ad has a different adPlayId.

adposition string

Position of the ad



Possible Values:
  • mid
  • post
  • pre
adschedule objectAd break information
adsystem string

From the ad XML, name of the ad server that returned the ad



Definition derived from IAB Tech Lab

adtitle string

From the ad XML, common name for the ad



Definition derived from IAB Tech Lab

advertiser string

From the ad XML, name of the advertiser as defined by the ad serving party



Definition derived from IAB Tech Lab

advertiserId string

From the ad XML, optional identifier for the advertiser, provided by the ad server



Definition derived from IAB Tech Lab

clickThroughUrl string

From the ad XML, URI to the advertiser’s site that the media player opens when a viewer clicks the ad



Definition derived from IAB Tech Lab

client string

The client that is currently being used



Possible Values:
  • dai
  • freewheel
  • googima
  • vast
conditionalAdOptOut boolean (VPAID-only) Used to tell the player to not play ads with the conditionalAd attribute inside of the VAST response
creativeId string

From the ad XML, identifier of the ad server that provides the creative



Definition derived from IAB Tech Lab

creativeAdId string

From the ad XML, the ad server’s unique identifier for the creative



Definition derived from IAB Tech Lab

creativetype stringMIME type of the current media file specified in the ad XML
dealId string

From the ad XML, returns the first deal ID present in the wrapper chain for the current ad, starting from the top



Definition derived from Google

description string

From the ad XML, provides a long ad description



Definition derived from IAB Tech Lab

duration number

From the ad XML, time value for the duration of the linear ad in the format HH:MM:SS.mmm



Definition derived from IAB Tech Lab

id stringUnique ad ID
ima object Contains the currently playing ad instance from the IMA SDK, and the userRequestContext that JWX passes to the IMA SDK when requesting an ad
linear string

Value of the linear attribute of the ad XML



Possible Values:
  • linear
  • nonlinear
mediafile | mediaFile object

From the ad XML, contains the video file for a linear ad



Definition derived from IAB Tech Lab

mediaFileCompliance boolean

Indicates if the ad is mediaFile compliant



To be compliant, one of the following conditions must be met::
  • .m3u8
  • VPAID
  • At least three quality levels per MIME type
offset number | string

Position of an ad



Possible Values:
  • (Mid-roll ads) {number in seconds}
  • post
  • pre
placement string

Value sent in a bid request that identifies the location of a player



Possible Values:
  • article
  • banner
  • feed
  • floating
  • instream
  • interstitial
  • slider
request objectXML HTTP request to the ad tag URL
response object XML response received from the request
sequence numberReturns the order of the ad within the pod
tag stringURL of the ad tag
type string

Category of the player event



This is always adViewabilityImpression for the event.

universalAdId object

From the ad XML, unique creative identifier that is maintained across systems for the purpose of tracking ad creative



Definition derived from IAB Tech Lab

vastversion number

From the ad XML, official version with which the VAST response is compliant



Definition derived from IAB Tech Lab

viewable number

Indicates if the player is viewable or not



Possible Values:
  • 0
  • 1
wcount numberWaterfall count
witem numberWaterfall index


.on('adWarning')


VAST only. Signals a non-fatal warning that is not critical to the playback of an ad.

{
  "message": "Tracking events are missing breakStart, breakEnd, or error for AdBreak",
  "code": 1002,
  "adErrorCode": 70001,
  "type": "adWarning",
  "tag": "{ad_tag_url}"
}
PropertyDescription
adErrorCode number JWX ad warning code
code number VAST warning code
message stringAd error message
tag stringURL of the ad tag that produced the error
type string

Category of player event



This is always adWarning for this event.



.on('adsManager')



Fires when the ad manager is loaded into the player.

This event allows publishers to integrate additional ad manager functionality before ad playback.

❗️

Using this event to integrate additional functionality could impact ad playback.

{
  "adsManager": {...},
  "type": "adsManager",
  "videoElement": {}
}
PropertyDescription
adsManager object

Object containing the ad manager configuration



See Google's and FreeWheel's documentation for the properties returned by the respective SDK.

type string

Category of the player event



This is always adsManager for this event.

videoElement object(IMA only) Video tag used for playback


.on('beforeComplete')

Fired just before the player completes playing. Unlike the onComplete event, the player will not have moved on to either showing the replay screen or advancing to the next playlistItem, which makes this the right moment to insert post-roll ads using playAd().

ValueDescriptionType
-No value returned-


.on('beforePlay')

Fires before any of the following occur:

  • Initial playback of a single media or individual playlist item begins.
  • After a pause, media playback resumes initiated by a viewer or other mechanism.
💡

Since this event fires before .on('play'), use this event to trigger calling loadAdTag(tag) or loadAdTag(xml) to play a preroll ad when the state is idle.

{
    "playReason": "interaction",
    "state": "idle",
    "viewable": 1,
    "type": "beforePlay"
}
ValueDescription
playReason string

Reason for the play



Possible Values:
  • autostart
  • external: API usage
  • interaction: Click, touch, keyboard
  • playlist: Auto-advancing
  • related-audio: Auto-advancing a Recommendations playlist
  • related-interaction: Interaction to go to a Recommendations playlist item
state string

Playback state when the event fires



Possible Values:
  • idle Occurs before initial playback or when switching between playlist items
  • paused Occurs when playback has been resumed on a single media item
type string

Category of the event



This value is always beforePlay.

viewable boolean

Viewability of the player container



Possible Values:
  • 0: Player container is not in view
  • 1: Player container is in view

© 2007- Longtail Ad Solutions, Inc.