Advanced macro glossary

AdButler supports a wide variety of macros that are useful for passing targeting information to ad networks and RTB integrations.

Macro: Used internally in AdButler when implementing tags. Macros are placed in the Custom HTML / third party script body, Destination URLs, or Tracking URLs.

Parameter: These are used by passing them to an AdButler request, either directly through the requesting URL or via a custom field in the Asynchronous JavaScript zone tag.

[ADVERTISING_ID]
[APP_BUNDLE_NAME]
[APP_NAME]
[APP_PACKAGE_NAME]
[APP_STORE_URL]
[CARRIER_CODE]
[CARRIER_COUNTRY]
[CARRIER_NAME]
[CONSENT]
[COPPA_COMPLIANT]
[DEVICE_MAKE]
[DEVICE_MODEL]
[DEVICE_TYPE]
[DO_NOT_TRACK]
[GDPR]
[LANGUAGE]
[LATITUDE]
[LONGITUDE]
[NETWORK_TYPE]
[OS_NAME]
[OS_VERSION]
[SCREEN_DENSITY]
[SCREEN_HEIGHT]
[SCREEN_WIDTH]
[USER_AGE]
[USER_GENDER]
[USER_YEAR_OF_BIRTH]
[US_PRIVACY]


Advertising ID

Fills in the device's Advertising ID.

Macros Parameter Example
[ADVERTISING_ID] [ADVERTISING_ID_ENCODED] aduid 96bd03b6-defc-4203-83d3-dc1c730801f7

Application Bundle / Package Name

Fills in the application's bundle name or package name (depending on the device/OS).

Macros Parameter Example
[APP_BUNDLE_NAME] [APP_BUNDLE_NAME_ENCODED] [APP_PACKAGE_NAME] [APP_PACKAGE_NAME_ENCODED] appcode com.package.mypackage

Application Name

Fills in the application's name.

Macros Parameter Example
[APP_NAME] [APP_NAME_ENCODED] appname Google Play Music

App Store URL

Fills in the URL to the app's page in the Google Play or Apple App store.

Macros Parameter Example
[APP_STORE_URL] [APP_STORE_URL_ENCODED] storeurl https://play.google.com/store/apps/details?id=sample_app

Carrier Code

Fills in the code of the device's SIM's operator.

Macro Parameter Example
[CARRIER_CODE] carriercode 412 20

Carrier Country

Fills in the country code of the device's SIM's operator.

Macros Parameter Example
[CARRIER_COUNTRY] [CARRIER_COUNTRY_ENCODED] carriercountry CA

Carrier Name

Fills in the name of the device's SIM's operator.

Macros Parameter Example
[CARRIER_NAME] [CARRIER_NAME_ENCODED] carrier Bell Networks

Fills in the TCF-compliant GDPR consent string.

Macro Parameter Example
[CONSENT] gdpr_consent_string BOeLqXmOeLqXmAtABBENCL-AAAAmB7_______9______5uz_Ov_v_f__33e8__9v_l_7_-__u-33d4-_1vf99yfm1-7ftr3tp_87ues2_Xur__59__3z3_9phPrsks9Kg

COPPA Compliance

A flag that indicates if the app is COPPA-compliant.

Macro Parameter Example
[COPPA_COMPLIANT] coppa 1

Device Make

Fills in the device manufacturer.

Macros Parameter Example
[DEVICE_MAKE] [DEVICE_MAKE_ENCODED] dvmake Samsung

Device Model

Fills in the model number.

Macros Parameter Example
[DEVICE_MODEL] [DEVICE_MODEL_ENCODED] dvmodel SM-A520W

Device Type

Fills in the device type if applicable.

Macros Parameter Example
[DEVICE_TYPE] [DEVICE_TYPE_ENCODED] dvtype phone/tablet

Do Not Track

A flag that indicates whether the user's data should be tracked or not (1 = enabled, 0 = disabled).

Macro Parameter Example
[DO_NOT_TRACK] dnt 0

GDPR Applies

A flag that indicates whether GDPR applies to the user or not (1 = yes, 0 = no, Empty = unknown).

Macro Parameter Example
[GDPR] gdpr_applies 1

Language

Fills in the user's language setting.

Macros Parameter Example
[LANGUAGE] [LANGUAGE_ENCODED] lang en_CA

Latitude

Fills in the device's current latitude.

Macro Parameter Example
[LATITUDE] lat 48.424497

Longitude

Fills in the device's current longitude.

Macro Parameter Example
[LONGITUDE] long -123.369506

Network Connection Type

Fills in the device's current connection type: WIFI, 2G, 3G, or 4G.

Macro Parameter Example
[NETWORK_TYPE] network WIFI

Operating System

Fills in the name of the device's operating system.

Macros Parameter Example
[OS_NAME] [OS_NAME_ENCODED] os Android

Operating System Version

Fills in the version number of the device's operating system.

Macros Parameter Example
[OS_VERSION] [OS_VERSION_ENCODED] osv 7.0.0

Device Screen Density

Fills in the pixel density of the device's screen.

Macro Parameter Example
[SCREEN_DENSITY] spr 3

Device Screen Height

Fills in the height of the device's screen (absolute, in pixels).

Macro Parameter Example
[SCREEN_HEIGHT] sh 640

Device Screen Width

Fills in the width of the device's screen (absolute, in pixels).

Macro Parameter Example
[SCREEN_WIDTH] sw 360

User Age

Fills in the user's age in years.

Macro Parameter Example
[USER_AGE] age 24

User Gender

Fills in the user's gender (male or female).

Macro Parameter Example
[USER_GENDER] gender female

User Year of Birth

Fills in the user's year of birth.

Macro Parameter Example
[USER_YEAR_OF_BIRTH] yob 1993

US Privacy (CCPA)

Fills in the string that indicates the user's privacy selection under CCPA.

Macro Parameter Example
[US_PRIVACY] us_privacy 1YNN

Can't find what you're looking for?

Send us an email

hello@adbutler.com

Visit the blog

For more ad serving tips, industry news and AdButler insights.