PSA: Extra supported format for Protected Audience size macros

36 views
Skip to first unread message

Garrett Tanzer

unread,
Oct 16, 2023, 2:32:38 PM10/16/23
to blink-dev
Hi blink-dev,

PSA:

In the Protected Audience API within the Privacy Sandbox, there is an opt-in feature that allows you to macro the size of the ad that wins the auction into the ad’s url, like:

https://ad.com?width={%AD_WIDTH%}&height={%AD_HEIGHT%}

(See https://github.com/WICG/turtledove/pull/417 for more details.)

To be more consistent with other types of macros in Protected Audience, like those used by deprecatedReplaceInURN and registerAdMacro, in M119 we’re adding the ability to use ${AD_WIDTH} and ${AD_HEIGHT} as the format for the macros in addition to the current format.

This is backwards compatible because the old format will continue to work. Technically, there could be changes in behavior for ads that have already opted in to the size macroing and erroneously use ${AD_WIDTH} or ${AD_HEIGHT} rather than {%AD_WIDTH%} and {%AD_HEIGHT%}: before the macros wouldn’t work, and now they will. This seems exceedingly unlikely, and is more like a bug fix.

More references:
ChromeStatus (https://chromestatus.com/feature/5140606359175168)
Reply all
Reply to author
Forward
0 new messages