Integrating Kaltura with VAST adTag URL

Printer-friendly version

The Kaltura player has a flexible string substitution system for evaluating ad tag URLs prior to requesting the ads from the ad server. This enables ad requests to include content metadata for better ad targeting. Both the ad stitching and client side "VAST" plugin work and evaluate URLs in the same way. 

For example your VAST plugin config may look like the following: 

vast: {
    ...
    'prerollUrl' : 'http://adserver.com/videoId={mediaProxy.entry.id}&cache_break={utility.random}'
    ...
}

This configuration would then be evaluated substituting the entry.id with the current content unique identifier and utility.random with a random number when the ad request is made. 

Arbitrary player state properties can be used in evaluations. These are detailed in the player api page.  Not all evaluations are available  for server side ad stitching. The properties available are detailed as follows: 

Property

Description

Supported in server side evaluations

configProxy

The player configuration object. Allows access to all UI vars and plugin properties

 yes

duration

Current video duration in seconds

 no

isHTML5

A flag specifying if the current player is an HTML5 player (Universal player)

 no

mediaProxy.entry

Returns all entry properties for the currently active entry.

 yes

mediaProxy.entryCuePoints

Array of cue points if defined for the current media

 no

mediaProxy.entryMetadata

Metadata object for the current entry

 yes

mediaProxy.isLive

Returns true, if the current entries live broadcast is active.

 no

mediaProxy.isOffline

Returns true if the current entries live broadcast is offline.

 no

mediaProxy.kalturaMediaFlavorArray

An array holding all available flavors for the current media

 no

playerStatusProxy.kdpStatus

The player status. Can be "empty" or "ready"

 no

playerStatusProxy.loadTime

The time it took to load the player on the page

 no

playlistAPI.dataProvider

The data provider of a play list holding all the entries for this list

 no

sequenceProxy.activePluginMetadata

Metadata object of the plugin currently playing the ads sequence

 no

sequenceProxy.duration

The total duration of the current ad set.

 no

sequenceProxy.isInSequence

A flag specifying if the player is currently playing ads

 no

sequenceProxy.skipOffsetRemaining

During ad playback, the time remaining until the Skip button appears

 no

sequenceProxy.timeRemaining

Time remaining until the end of the current ads sequence

 no

utility.nativeAdId

The native device identifier, AdvertisingIdentifier for Apple and AdvertisingIdClient for Android

Only supported in native player SDK

utility.random

Utility for generating a random number

 yes

utility.referrer_host

Retrieve the referrer host

 yes

utility.referrer_url

Retrieve the referrer URL

 yes

utility.timestamp

Utility for generating the current time stamp

 yes

video.player.currentTime

The current video time in seconds

 no

video.volume

The volume of the currently playing video (0-1)

 no

mediaSession.userIPaddress

The client ip address originating the request

Server only

mediaSession.userAgent

 The client software originating the request

Server only

Document type: 
(12727 reads)