Skip to content

Commit 6e13ea0

Browse files
innaynoamtzuberinoamtzuLaslo ChechurOronW
authored
MinuteMedia BidAdapter : add support for gpp (prebid#11052)
* add Rise adapter * fixes * change param isOrg to org * Rise adapter * change email for rise * fix circle failed * bump * bump * bump * remove space * Upgrade Rise adapter to 5.0 * added isWrapper param * addes is_wrapper parameter to documentation * added is_wrapper to test * removed isWrapper * Rise Bid Adapter: support Coppa param (#24) * MinuteMedia Bid Adapter: support Coppa param (#25) * Revert "MinuteMedia Bid Adapter: support Coppa param (#25)" (#26) This reverts commit 66c4e7b. * bump * update coppa fetch * setting coppa param update * update Coppa tests * update test naming * Rise Bid Adapter: support plcmt and sua (#27) * update minuteMediaBidAdapter - support missing params (#29) * support gpp for minutemedia adapter * removed spaces * removed extra character --------- Co-authored-by: Noam Tzuberi <[email protected]> Co-authored-by: noamtzu <[email protected]> Co-authored-by: Noam Tzuberi <[email protected]> Co-authored-by: Laslo Chechur <[email protected]> Co-authored-by: OronW <[email protected]> Co-authored-by: lasloche <[email protected]> Co-authored-by: YakirLavi <[email protected]> Co-authored-by: YakirLavi <[email protected]> Co-authored-by: Inna Yaretsky <>
1 parent 16ee425 commit 6e13ea0

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

modules/minutemediaBidAdapter.js

+8
Original file line numberDiff line numberDiff line change
@@ -460,6 +460,14 @@ function generateGeneralParams(generalObject, bidderRequest) {
460460
generalParams.gdpr_consent = bidderRequest.gdprConsent.consentString;
461461
}
462462

463+
if (bidderRequest.gppConsent) {
464+
generalParams.gpp = bidderRequest.gppConsent.gppString;
465+
generalParams.gpp_sid = bidderRequest.gppConsent.applicableSections;
466+
} else if (bidderRequest.ortb2?.regs?.gpp) {
467+
generalParams.gpp = bidderRequest.ortb2.regs.gpp;
468+
generalParams.gpp_sid = bidderRequest.ortb2.regs.gpp_sid;
469+
}
470+
463471
if (generalBidParams.ifa) {
464472
generalParams.ifa = generalBidParams.ifa;
465473
}

test/spec/modules/minutemediaBidAdapter_spec.js

+16
Original file line numberDiff line numberDiff line change
@@ -301,6 +301,22 @@ describe('minutemediaAdapter', function () {
301301
expect(request.data.params).to.have.property('gdpr_consent', 'test-consent-string');
302302
});
303303

304+
it('should not send the gpp param if gppConsent is false in the bidRequest', function () {
305+
const bidderRequestWithGPP = Object.assign({gppConsent: false}, bidderRequest);
306+
const request = spec.buildRequests(bidRequests, bidderRequestWithGPP);
307+
expect(request.data.params).to.be.an('object');
308+
expect(request.data.params).to.not.have.property('gpp');
309+
expect(request.data.params).to.not.have.property('gpp_sid');
310+
});
311+
312+
it('should send the gpp param if gppConsent is true in the bidRequest', function () {
313+
const bidderRequestWithGPP = Object.assign({gppConsent: {gppString: 'test-consent-string', applicableSections: [7]}}, bidderRequest);
314+
const request = spec.buildRequests(bidRequests, bidderRequestWithGPP);
315+
expect(request.data.params).to.be.an('object');
316+
expect(request.data.params).to.have.property('gpp', 'test-consent-string');
317+
expect(request.data.params.gpp_sid[0]).to.be.equal(7);
318+
});
319+
304320
it('should have schain param if it is available in the bidRequest', () => {
305321
const schain = {
306322
ver: '1.0',

0 commit comments

Comments
 (0)