google / openrtb-doubleclick

Utilities for DoubleClick Ad Exchange, including OpenRTB mapping, DoubleClick cryptography, metadata and validation
Apache License 2.0
197 stars 89 forks source link

BidExtWriter and BidExtReader lacks support for 'attribute' field. #121

Closed fredriklagerblad closed 6 years ago

fredriklagerblad commented 6 years ago

The AdxExt has support for setting bid.ext.attribute (via e.g. the AdxExt.BidExt.Builder.addAttribute() method), but when converting it to JSON the attributes set is not included. Looking at the BidExtWriter and BidExtReader one can see that it contains code for reading/writing the other bid.ext fields (e.g. 'impression_tracking_url'), but NOT the ''attribute' field.

opinali commented 6 years ago

Thanks for reporting, the JSON support for this field is missing indeed. Will be fixed very soon.

fredriklagerblad commented 6 years ago

Thanks for the fast fix! But I think there's a typo in the fix, the JSON name should be 'attribute', not 'attributes'. See the AdX spec: https://developers.google.com/ad-exchange/rtb/adx-extensions-guide (at the very bottom)

opinali commented 6 years ago

Wow the fix was actually too fast, sorry -- fixed again now.