openrtb / OpenRTB

Documentation and issue tracking for the OpenRTB Project
BSD 2-Clause "Simplified" License
854 stars 143 forks source link

Standard Click URL Macro #13

Open aroslov opened 9 years ago

aroslov commented 9 years ago

Background

Most RTB platforms track clicks in ad markup using some kind of click URL macro. But names for these macro are not standard and bidder must adopt different bidding templates and/or configurations for different platforms, which increases integration time and creates unnecessary configuration options.

Proposal

New Macro

Introduce standard click macro to be used inside win notice URL and in bid.adm (to be added to section 4.4 of the protocol):

Macro Description
${CLICK_URL} Click URL of the exchange. The URL must allow to be suffixed with an optional URL value (URL encoded) to be used in chains of click redirections. For example, ${CLICK_URL}http%3A%2F%2Fiab.net

Encoding

Introduce new encoding suffix (in addition to :B64), specifically for URL encoding of values, e.g. :U

Backwards Compatibility

For smooth transition, exchanges are advised to support both existing custom click macro and new CLICK_URL macro with/without encoding.

erikdubbelboer commented 9 years ago

With the encoding you mean ${CLICK_URL:B64}? I would suggest using something like ${CLICK_URL_B64} since : is not allowed if it's not URL encoded, which might happen if the macro is somehow not replaced (misspelled for example).

aroslov commented 9 years ago

Yes, ${CLICK_URL:B64} or a more common with URL encoding ${CLICK_URL:U}

Usage of :x and :B64 example are described in current OpenRTB specs, see section "4.4 Substitution Macros".

A misspelled macro should ideally be picked up at the integration testing phase. Btw, the list of reserved URI symbols also includes $, so there is no guarantee that a ${CLICK_URL_B64} macro will work (see http://tools.ietf.org/html/rfc3986#section-2.2).

Niek commented 9 years ago

+1, not supporting a click URL macro makes it impossible to track clicks on the supply side.