From 0c633d994f5f91e3f5af81d633fe6ff23de79791 Mon Sep 17 00:00:00 2001 From: slimkrazy Date: Wed, 5 Oct 2022 14:33:59 +0100 Subject: [PATCH] Pass device width and height in openRTB payload to YSSP --- modules/yahoosspBidAdapter.js | 4 +++- test/spec/modules/yahoosspBidAdapter_spec.js | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/modules/yahoosspBidAdapter.js b/modules/yahoosspBidAdapter.js index 71b1ddca2c4..51d9bd30b84 100644 --- a/modules/yahoosspBidAdapter.js +++ b/modules/yahoosspBidAdapter.js @@ -237,7 +237,9 @@ function generateOpenRtbObject(bidderRequest, bid) { device: { dnt: 0, ua: navigator.userAgent, - ip: deepAccess(bid, 'params.bidOverride.device.ip') || deepAccess(bid, 'params.ext.ip') || undefined + ip: deepAccess(bid, 'params.bidOverride.device.ip') || deepAccess(bid, 'params.ext.ip') || undefined, + w: window.screen.width, + h: window.screen.height }, regs: { ext: { diff --git a/test/spec/modules/yahoosspBidAdapter_spec.js b/test/spec/modules/yahoosspBidAdapter_spec.js index 6e52e9c57db..e0b6390832b 100644 --- a/test/spec/modules/yahoosspBidAdapter_spec.js +++ b/test/spec/modules/yahoosspBidAdapter_spec.js @@ -847,7 +847,9 @@ describe('YahooSSP Bid Adapter:', () => { expect(data.device).to.deep.equal({ dnt: 0, ua: navigator.userAgent, - ip: undefined + ip: undefined, + w: window.screen.width, + h: window.screen.height }); expect(data.regs).to.deep.equal({