Ad Campaign / Targeting Rule Macros (Placeholders)


What are Ad Campaign / Targeting Rule Placeholder Macros?

When an ad is requested by a player, the relevant Ad server (DSP) usually requires additional information on the viewer and browser session taking place in order to retrieve suitable ads. For example, the DSP can identify the session geographic location using the IP address and fetch relevant ads for that country.

Using our placeholder macros you can enter a parameter placeholder that will be automatically populated by our Player and/or CDN (Delivery Service), that intern will provide the Ad Server with the relevant info it needs for targeting and/or advertising restrictions.


Supported Ad Campaign / Targeting Rule Placeholder Macros

The following table describes all available placeholder macros you can declare in your Ad Campaign URL


Macro Name Placeholder Resolved by
Cache buster [CACHE_BUSTER] Player
Timestamp (Current UNIX miliseconds)  [TIMESTAMP] Player
Page URL [URL] Player
Double encoded page URL [DE_URL] Player
Percent in video [VIDEO_PERCENT] Player
Video area width [CONTAINER_WIDTH] Player
Video area height [CONTAINER_HEIGHT] Player
Video description [VIDEO_DESCRIPTION] Player, DS
Video duration [VIDEO_DURATION] Player
Video GUID [VIDEO_ID] Player, DS
Video playback position in playlist [PLAYLIST_SEQUENCE] DS
Video URL (a link to the Delivery Service) [VIDEO_FILE_URL] Player
Video title [VIDEO_TITLE] Player, DS
Video keywords [VIDEO_KEYWORDS] DS
Video details page [VIDEO_DETAIL_PAGE] Player
Video metadata [META:${eplace_this_with_video_field_json_property}] DS
Playlist ID [BID] Player
RSS Item ID (GUID) Non encoded [DE_RSS_ID] DS
Player company name [PLAYER_COMPANY] DS 
Player company ID [PLAYER_COMPANY_ID] DS 
Player White labeler company name [PLAYER_COMPANY_WL] DS 
Player White labeler company ID [PLAYER_COMPANY_WL_ID] DS 
Is the Player set to Autoplay (1=true ; 0=false) [AUTOPLAY] Player 
Is the Player muted (1=true ; 0=false) [MUTED] Player

Page domain

Autoplay (1 when player set up to autoplay, 0 otherwise) [AUTOPLAY] Player
Muted (0 — sound on, 1 — sound off) [MUTED] Player
Alpha-3 country geo code
Device type (computer, mobile, tablet, game_console, dmr, unknown)
OS Manufacturer
OS Version
OS Platform
User IP address
Buyer company id [BCID] DS
User Agent [USER_AGENT] DS
Latitude of the device [LOCATION_LAT]   Player
Longitude of the device  [LOCATION_LON]   Player 
Apply G.D.P.R  [GDPR] Player
G.D.P.R Consent [GDPR_CONSENT] Player





How to Declare a Placeholder Macro in your Ad Campaign URL

Let's take the following Ad Campaign URL for example:

In this ad request URL, we have three query string parameters with blank values named X,Y and Z.
All three parameters need to be resolved for the Ad Server to return a valid ad response to the player.

Note: The query string parameter names here are just an example and each Ad Server has it's own onse and descriptions on the values that they require.

  • ip - Requires the IP of the sessions viewing the player.
  • url - Requires the URL of the page where the player is embedded in.
  • title - Requires the title of the video being watched.

In order to automatically substitue X,Y and Z with the actual data provdied by the user session, we can enter the following Placeholder Macros: [IP_ADDR], [URL] and [VIDEO_TITLE].[IP_ADDR]&url=[URL]&title=[VIDEO_TITLE]

Important! All placeholder macros must be declared between square brackets for the Player and CDN to resolve automatically. 

By placing the Placeholder Macros into our ad URL, our Player/Delivery service will resolve them dynamically for each session when the player is loaded and viewed.

Note: DS stands for "Delivery Service", our server side endpoint that serves Players and Videos. 

Have more questions? Submit a request