Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolution of OpenRTB macros in Prebid Server #1804

Closed
bretg opened this issue Apr 13, 2021 · 2 comments
Closed

Resolution of OpenRTB macros in Prebid Server #1804

bretg opened this issue Apr 13, 2021 · 2 comments

Comments

@bretg
Copy link
Contributor

bretg commented Apr 13, 2021

OpenRTB defines that certain macros should be resolved in the ad markup, win notice, and billing notice URLs.

Though there are 9 macros defined, I've received several complaints in the past 6 months about just one: AUCTION_PRICE. Prebid Server doesn't resolve any macros, instead relying on the rendering routines:

  1. Prebid.js resolves AUCTION_PRICE with bid.cpm, which is the real bid post-currency conversion and post-bidadjustment
  2. AMP and App: The Prebid Universal Creative resolves AUCTION_PRICE with hb_pb, which is the quantized bid post-currency conversion and post-bidadjustment

Nothing in Prebid handles any other OpenRTB macro. Nor does it support the Base64 encoding extension ${AUCTION_PRICE:B64}

Further, neither Prebid.js nor the PUC abide by the definition of AUCTION_PRICE in the standard, which is "Clearing price using the same currency and units as the bid."

How should Prebid interpret "clearing price"

There's no real "clearing price" available in our first-price header bidding world. The ad server could value each bid however it wants.

Options:

  1. original bid price
  2. post-bidadjustment, but before currency conversion

In discussing this internally, we believe option 1 is the best. Setting AUCTION_PRICE to post-bidadjustment could create a downward spiral of billing discrepancies.

What should Prebid Server should do about OpenRTB macros:

  1. Make them the responsibility of each bid adapter that cares: if they want AUCTION_PRICE to be their bid price, just resolve it in the adapter. We also suggest AUCTION_CURRENCY.

  2. Update PBS to place the original bid in the cache. What's cached right now in PBC is just "price", which is the post-currency, post-bidadjustment price. We could add "ext.origbidcpm" to what's cached, then update PUC to prefer this value over hb_pb. Update PBJS to look for this value from PBS.

    2a) If we choose post-bidadjustment, name it seatbid.bid.ext.adjbidcpm.

  3. Make a step towards PBS being a full-on SSP -- give it PBS macro support to resolve in adm, burl, nurl.

  • ${AUCTION_ID} - BidRequest.id attribute.

  • ${AUCTION_BID_ID} - BidResponse.bidid attribute.

  • ${AUCTION_IMP_ID} - imp.id attribute

  • ${AUCTION_SEAT_ID} - seatbid.bid.seat

  • ${AUCTION_AD_ID} - seatbid.bid.adid

  • ${AUCTION_PRICE} - orig bid: pre-currency conversion, pre-adjustment.

  • ${AUCTION_CURRENCY} - bid currency

  • ${AUCTION_MBR} - clearance price / bid price

  • AUCTION_LOSS - huge can of worms. Out of scope.

    3a) Configure PBS to resolve macros only for certain adapters so it doesn't waste CPU cycles for those bidders that don't need this service.

Proposal

The proposal is that we go with the first option -- there are very few bid adapters that require these macros, so they should be responsible for resolving their own values.

In the future, if Prebid Server moves towards SSP functionality, it might make sense to build a module to resolve these macros in a full SSP-like way as laid out in the third option.

The implication here is that the following bid adapters that utilize AUCTION_PRICE should consider how they want it resolved in the AMP and App scenarios.:

The Prebid Server team is suggesting a simple change to your bid adapters: just scan your creatives before returning them to PBS-core and resolve whichever macros you require. This will be more accurate and in accordance with OpenRTB than what's happening now in the Prebid Universal Creative.

We will give a couple of weeks for community feedback on this.

@bretg
Copy link
Contributor Author

bretg commented Apr 19, 2021

Met with the Prebid Server committee last Friday. We agreed:

  1. AUCTION_PRICE in Prebid is the original bid price
  2. the initial solution is for affected bid adapters is fix user sync macro for index #1 above. i.e. bid adapters should be resolving macros relevant to them.

@SyntaxNode SyntaxNode added the Intent to implement An issue describing a plan for a major feature. These are intended for community feedback label Apr 19, 2021
@bretg
Copy link
Contributor Author

bretg commented May 14, 2021

Discussed in committee again - we agreed to close this issue. Bidders that need to resolve AUCTION_PRICE in PBS should do so with a PR.

@bretg bretg closed this as completed May 14, 2021
@SyntaxNode SyntaxNode removed the Intent to implement An issue describing a plan for a major feature. These are intended for community feedback label May 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants