Skip to content

Commit 0ad3244

Browse files
bjorn-lwmsmeza
andauthored
Livewrapped Bidder: add support for ortb2imp (#11026)
* Added support for the Price Floors Module * Use the ad server's currency when getting prices from the floors module * Default to USD if the ad server's currency can't be retrieved * Set the default currency at the right place * Added tests and made a minor change in how device width and height are calculated * Only include flrCur when ad requests contain floors * Use ortb native * Read ortb2imp --------- Co-authored-by: msmeza <[email protected]>
1 parent d000ec8 commit 0ad3244

File tree

2 files changed

+190
-38
lines changed

2 files changed

+190
-38
lines changed

modules/livewrappedBidAdapter.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import {config} from '../src/config.js';
44
import {find} from '../src/polyfill.js';
55
import {BANNER, NATIVE, VIDEO} from '../src/mediaTypes.js';
66
import {getStorageManager} from '../src/storageManager.js';
7-
import { convertOrtbRequestToProprietaryNative } from '../src/native.js';
87

98
/**
109
* @typedef {import('../src/adapters/bidderFactory.js').BidRequest} BidRequest
@@ -52,9 +51,6 @@ export const spec = {
5251
* @return ServerRequest Info describing the request to the server.
5352
*/
5453
buildRequests: function(bidRequests, bidderRequest) {
55-
// convert Native ORTB definition to old-style prebid native definition
56-
bidRequests = convertOrtbRequestToProprietaryNative(bidRequests);
57-
5854
const userId = find(bidRequests, hasUserId);
5955
const pubcid = find(bidRequests, hasPubcid);
6056
const publisherId = find(bidRequests, hasPublisherId);
@@ -236,9 +232,9 @@ function bidToAdRequest(bid, currency) {
236232
adUnitId: bid.params.adUnitId,
237233
callerAdUnitId: bid.params.adUnitName || bid.adUnitCode || bid.placementCode,
238234
bidId: bid.bidId,
239-
transactionId: bid.ortb2Imp?.ext?.tid,
240235
formats: getSizes(bid).map(sizeToFormat),
241236
flr: getBidFloor(bid, currency),
237+
rtbData: bid.ortb2Imp,
242238
options: bid.params.options
243239
};
244240

0 commit comments

Comments
 (0)