diff --git a/modules/pubmaticBidAdapter.js b/modules/pubmaticBidAdapter.js index ec87563d4c2..b5ecd784a6c 100644 --- a/modules/pubmaticBidAdapter.js +++ b/modules/pubmaticBidAdapter.js @@ -1031,6 +1031,8 @@ export const spec = { br.ttl = 300; br.referrer = parsedReferrer; br.ad = bid.adm; + br.pm_seat = seatbidder.seat || null; + br.pm_dspid = bid.ext && bid.ext.dspid ? bid.ext.dspid : null if (requestData.imp && requestData.imp.length > 0) { requestData.imp.forEach(req => { if (bid.impid === req.id) { diff --git a/test/spec/modules/pubmaticBidAdapter_spec.js b/test/spec/modules/pubmaticBidAdapter_spec.js index 3ad33d5f66c..cf7d98948e2 100644 --- a/test/spec/modules/pubmaticBidAdapter_spec.js +++ b/test/spec/modules/pubmaticBidAdapter_spec.js @@ -89,6 +89,7 @@ describe('PubMatic adapter', function () { bidRequests = [firstBid, secoundBid]; firstResponse = { + 'seat': 'seat-id', 'bid': [{ 'id': '74858439-49D7-4169-BA5D-44A046315B2F', 'impid': '23acc48ad47af5', @@ -2589,6 +2590,8 @@ describe('PubMatic adapter', function () { expect(response[0].meta.clickUrl).to.equal('blackrock.com'); expect(response[0].referrer).to.include(data.site.ref); expect(response[0].ad).to.equal(bidResponses.body.seatbid[0].bid[0].adm); + expect(response[0].pm_seat).to.equal(bidResponses.body.seatbid[0].seat); + expect(response[0].pm_dspid).to.equal(bidResponses.body.seatbid[0].bid[0].ext.dspid); expect(response[1].requestId).to.equal(bidResponses.body.seatbid[1].bid[0].impid); expect(response[1].cpm).to.equal((bidResponses.body.seatbid[1].bid[0].price).toFixed(2)); @@ -2608,6 +2611,8 @@ describe('PubMatic adapter', function () { expect(response[1].meta.clickUrl).to.equal('hivehome.com'); expect(response[1].referrer).to.include(data.site.ref); expect(response[1].ad).to.equal(bidResponses.body.seatbid[1].bid[0].adm); + expect(response[1].pm_seat).to.equal(bidResponses.body.seatbid[1].seat || null); + expect(response[1].pm_dspid).to.equal(bidResponses.body.seatbid[1].bid[0].ext.dspid); }); it('should check for dealChannel value selection', function () {