Send feedback on this topic

Pixel URL Macros

You can add the following macros as key-value pairs within a pixel URL:

Macro Replaced by
$_BK_UUID Obfuscated Oracle Data Cloud unique user ID (BKUUID). The BKUUID is a 16-character alphanumeric identifier that may include upper-case and lower-case letters and some special characters. For example: dXF+DNR/99YjF70X
$_BK_UUID_NOSLASH Returns the BKUUID with dashes (-) instead of slashes (/). For example: dXF+DNR-99YjF70X
$ADID The Android user's Google Advertising ID

For more details, see MAID paste-a-pixel campaigns.

$CAMPAIGNS The list of recently winning campaign IDs
To limit the number of items in one call, append parentheses with a number, for example: $CAMPAIGNS(5)
$CATEGORIES The list of tag category numbers matching this campaign win

By default, items are separated by vertical bar ("|") characters. To change the separator, append square brackets with the separator character you want to use, for example: $CATEGORIES[,].

To change the separator and limit the number of items in a tag call, use the parentheses with the limit first, and then use the square brackets with the separator, for example: $CATEGORIES(8)[,]. The opposite order will not work.

$COLO Returns the ID of the colocation server that the user hits
Used only for the user data API.
$COUNTRY_CODE_UPPER The ISO 3166-1 alpha-2 country code of the user
$DMP_Audience_Name_Macro The name of the audience targeted and won by the campaign
$IDFA The iOS user's identifier for advertising (IDFA)

For more details, see MAID paste-a-pixel campaigns.

$LEAF_CATEGORIES A list of category IDs matching the campaign win not including parent nodes (only includes the lowest categories in the tree)
This macro is otherwise the same as the $CATEGORIES macro.
$PCATSTIME The time when the data was collected on the user
$PRICE Win price for this campaign
$RAND A dynamically-generated, random 32-bit unsigned integer value, which can be used to avoid browser caching ("cache busting")
$REPEAT_VISITOR(siteID)
  • Returns a 0 if the user has never been seen on the partner's site IDs called in the macro
  • Returns a 1 if the user has been seen on the partner's site IDs called in the macro
  • Returns nothing for invalid sites or sites for which the user does not have access
  • Returns new visitor indication for all site IDs for the partner if no siteID is listed is listed in the macro

To list multiple siteIDs, separate the siteIDs by a comma. For example ($REPEAT_VISITOR(1234,9876, 3241).

Multiple site IDs are treated as an OR condition:

  • If the user has never been seen on any of the site IDs, 0 is returned.
  • If the user has been seen on any of the sites listed, 1 is returned.
$TIMESTAMP The current Unix time (in seconds since Jan. 1 1970 UTC) when the campaign win occurred
$URL_ARG(field, inDelims, outDelim, minVal, maxVal, T|R) Reformatted key-value pairs (phints) in an Oracle Data Cloud tag URL or referrer URL
See $URL_ARG macro.
$URL_ENCODED_ARG(keyName) Returns the value of the named phint matching keyName in the argument passed. This macro requires the campaign and site to be owned by the same partner. For example:
  • Pixel URL: http://sometag.example.com?foo=$URL_ENCODED_ARG(url_arg)
  • Oracle Data Cloud tag call: http://tags.bluekai.com/site/4712?ret=html&phint=url_arg%3DPHINT_PASSED&limit=10&r=43132838&url_arg=URL_PASSED
  • Result: http://sometag.example.com?foo=URL_PASSED|phint_passed

Important: This macro does not work for redirects using done=.

$URL_ARG macro

The $URL_ARG(field, inDelims, outDelim, minVal, maxVal, T|R) macro parses and transforms the key-value pairs (phints) in an Oracle Data Cloud tag URL or referrer URL to a new format. This macro takes the following comma-separated parameters:

Parameter Description
field The name of the key to be parsed and transformed.
inDelims Enter one or more delimiters in the inbound URL that you want to transform. If the key only has one value, you do not need to enter a delimiter. The following delimiters must be expressed as literal values:
  • COLON
  • COMMA
  • DASH
  • SEMICOLON
  • UNDERSCORE
  • VERTBAR
minVal
maxVal
Specify the range of values to be transformed and sent. For example:
  • For just the first value, enter 0 for both parameters.
  • For just the first two values, enter 0 for the inDelims parameter and enter 1 for the outDelim parameter.
  • For just the second value in a key that has five values, enter 1 for both the inDelims and outDelim parameters.
  • For all the values starting from the second value, enter 1 for the inDelims parameter.
  • For just the last value in a key that has three values, enter 2 for both the inDelims and outDelim parameters.
outDelim Enter the delimiter to be used in the outbound URL to separate the key's values. This outbound delimiter will replace all the delimiters you entered in the inDelims parameter. You can only enter one delimiter. If the key only has one value, do not enter a delimiter. You must enter the delimiter as a literal value.
T | R Specifies from which part of the inbound request to get the attribute to be converted.
  • T (the default): The Oracle Data Cloud tag URL
  • R: The URL of the previous web page from which a link was followed

Examples:

URL_ARG macro URL Result
test, COMMA, DASH, 0, 2, R http://abc.com/def?test=all,that&test=jazz,plays all-that-jazz
test, UNDERSCORE|VERTBAR, COMMA, 2, 3, T http://tags.bluekai.com/site/1234?ret=html&test=abc_def|xyz_pdq xyz,pdq

Related

Creating a campaign

App macros