--- title: "Using Macros" slug: "using-macros" tags: ["macros"] updated: 2025-10-02T21:18:46Z published: 2025-10-02T21:18:46Z canonical: "help.tritondigital.com/using-macros" --- > ## Documentation Index > Fetch the complete documentation index at: https://help.tritondigital.com/llms.txt > Use this file to discover all available pages before exploring further. # Using Macros in TAP A macro is a **placeholder** typically used in a third-party tracker URL (audio impression pixel) that Triton's ad server replaces with a specific value at time of delivery. This is done to dynamically populate third-party tracker and attribution service URL query parameters with values specific to that ad, content, or user. > [!NOTE] > Also see: [Macros for Buyers](/user/docs/macros-for-buyers) ## Triton Digital Macro Format > [!NOTE] > Macros are not case sensitive but it is preferred and recommended to use **ALL UPPERCASE**. You might have to edit your macros so they conform to the Triton Digital `@MACRO@` format. Some formats automatically convert to the Triton Digital format, so you can use them as-is (see list below). Otherwise you must manually edit them to `@MACRO@` before pasting them into your pixel/clickout URL. For example, if the URL contains a macro such as `_IP_` you need to manually change it to `@IP@`. To use a macro as a query parameter when making an on-demand call, any special character should be URL-encoded. For example, use `%25` instead of `%`. **Formats that automatically convert to** `@MACRO@` **format are:** - `%%MACRO%%` - `${MACRO}` - `[MACRO]` > [!NOTE] > Macro format symbols are [URL encoded](https://en.wikipedia.org/wiki/URL_encoding) when they appear in the address bar of a web browser. ## Triton Digital Targeting Macros The tables below include the most commonly used Triton Digital macros for targeting. > [!NOTE] > Other macros also exist for more specialized use; for more information, speak with your Triton Digital Solutions Specialist or Client Success Manager. ### **Content Macros for Podcast** | **Macro Name** | **RSS Field** | **Description** | **Example Value** | | --- | --- | --- | --- | | **C.SERIES-TITLE** | channel/title | Content series title. | SMALL TOWN MURDER | | **C.SERIES-TYPE** | channel/itunes:type | Content series type Valid values: "episodic" or "serial." | EPISODIC | | **C.ITUNES-CAT** | channel/itunes:category | Podcast category. | ARTS | | **C.ITUNES-SUBCAT** | channel/itunes:category/itunes:category | Podcast sub-category (first one defined). | BOOKS | | **C.EPISODE-SEASON** | channel/item/itunes:season | Season number. | 1 | | **C.EPISODE-NUMBER** | channel/item/itunes:episode | Episode number. | 232 | | **C.EPISODE-TITLE** | channel/item/itunes:title ELSE channel/item/title | Episode title. | #232 - A STRANGE WAY TO TORTURE - LAUREL, DELAWARE | | **C.EPISODE-URL** | channel/item/enclosure/url | Episode origin URL mapped from enclosure URL. | https://omny.fm/shows/small-town-murder/232-a-strange-way-to-torture-laurel-delaware.mp3 | | **C.EPISODE-TYPE** | channel/item/itunes:type | Type of episode Valid values: "full", "trailer", or "bonus." | FULL | | **C.PUBDATE** | channel/item/pubdate | Publication Date. | TUE, 28 SEP 2021 22:01:00 +0000 | | **C.EPISODE-ID-RAW** | channel/item/guid | Episode unique ID (from RSS feed) - max 1024 characters. | 97095c68-aa62-40dc-930b-adb100c34ec8 | | **C.EPISODE-ID-RSS** | channel/item/guid | Episode unique ID (from RSS feed) - hashed. | efb909f5beceae6e9bae7270d132b258 | | **C.EPISODE-ID-TRITON** | --- | Episode unique ID (Triton-generated). | 893583-a53e9705a731ef20ed0401ae8fd7 | **Player/Listener Macros** | **Macro Name** | **Description** | **Example Value** | | --- | --- | --- | | **P.CITY** | Listener city | PORTLAND | | **P.COUNTRY** | Listener country | US | | **P.DMA** | Listener DMA | 501 | | **P.GAM-PALN** | Publisher-generated nonce (unique serial number to make transaction unique). Used to pass the gam-paln value from the publisher to Google Ad Manager (GAM). It should contain a “nonce” value that is usually generated by the GAM PAL SDK. If using an exernal VAST file from GAM, the publisher receives a string from Google (usually a JWT token) and must then pass it to Triton Digital in a parameter (`gam-paln`). The publisher must then ensure that the VAST file contains the string: `?givn=${p.gam-paln}` | | | **P.MSA** | Listener MSA (*See TAP Explore* [*MSA Usage Notes*](/user/docs/creating-reports#msa-usage-notes)) | 5600 | | **P.REGION** | Listener region (*such as US state or Canadian province*) | or | | **P.TTAG** | [Custom targeting tag](/v1/docs/custom-ttag-targeting) (*can be a comma separated string*) | FOO,BAR | **Other supported macro** | **Macro Name** | **Description** | **Example Value** | | --- | --- | --- | | ***Inventory Macros*** | | **BUYER_ID** | The advertiser ID for the flight. | 12345 | | **CAMPAIGN_ID** | The numerical ID of the campaign. | 884461 | | **IAB_CATEGORIES_TO_EXCLUDE** | A comma-separated list of IAB categories that the publisher wants to exclude in the ad request | IAB2-2,IAB24 | | **PUB_ID** | The numerical ID of the publisher as assigned by Triton Digital. | 5679 | | **PUB_NAME** | The name of the publisher. | BLORK_RADIO | | **STATION_ID** | The numerical ID of the station as assigned by Triton Digital. | 12345 | | **STATION_NAME** | The name of station. | KSADFM | | ***Listener Macros*** | | **AD_ID** | The mobile advertising ID (iOS or Android; i.e., an IDFA or AdID). | | | **COOKIE** | The Triton Digital Cookie ID. | | | **GAID** | The Google Advertising ID (Android devices). | | | **IDFA** | The Apple IDFA (iOS devices). | | | **IP** | The IP address of the device. | | | **USERAGENT** | The User-Agent header of the device. | | | ***Transient Macros*** | | **CACHEBUSTER** | A random string for cache busting. The string is always a positive integer with a fixed length of 9 digits. | | | **RANDOM** | A random string for cache busting. | | | **TIMESTAMP** | Unix timestamp in seconds. | | ## Regulatory Macros Triton Digital supports the following IAB-defined privacy-related macros: - `${GDPR}` - `${GDPR_CONSENT_XXXXX}` *(where XXXXX is the tracking vendor's numeric ID where the macro is being used)* - `${US_PRIVACY}` - `${GPP_STRING_XXXXX}` *(where XXXXX is the tracking vendor's numeric ID where the macro is being used)* - `${GPP_STRING}` - `${GPP_SID}` These macros are expected on third-party tags to share the privacy choices of listeners. For more information, refer to the IAB format specifications: - [GDPR](https://github.com/InteractiveAdvertisingBureau/GDPR-Transparency-and-Consent-Framework/blob/master/TCFv2/IAB%20Tech%20Lab%20-%20Consent%20string%20and%20vendor%20list%20formats%20v2.md#how-does-a-url-based-service-process-the-tc-string-when-it-cant-execute-javascript) - [US Privacy](https://github.com/InteractiveAdvertisingBureau/USPrivacy/blob/master/CCPA/US%20Privacy%20String.md#url-parameters) - [GPP](https://github.com/InteractiveAdvertisingBureau/Global-Privacy-Platform/blob/main/Core/Consent%20String%20Specification.md#how-does-a-%5B%E2%80%A6%5D-javascript)