prebid.js 7.2.0 → 7.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/dependabot.yml +6 -0
- package/.github/workflows/issue_tracker.yml +5 -0
- package/.github/workflows/release-drafter.yml +6 -0
- package/README.md +35 -0
- package/dist/33acrossBidAdapter.js +1 -1
- package/dist/adagioBidAdapter.js +1 -1
- package/dist/adbookpspBidAdapter.js +1 -1
- package/dist/adgenerationBidAdapter.js +1 -1
- package/dist/adkernelBidAdapter.js +1 -1
- package/dist/adqueryBidAdapter.js +1 -1
- package/dist/adrelevantisBidAdapter.js +1 -1
- package/dist/adxcgBidAdapter.js +1 -1
- package/dist/adyoulikeBidAdapter.js +1 -1
- package/dist/ajaBidAdapter.js +1 -1
- package/dist/amxBidAdapter.js +1 -1
- package/dist/amxIdSystem.js +1 -1
- package/dist/appierAnalyticsAdapter.js +1 -1
- package/dist/appnexusBidAdapter.js +1 -1
- package/dist/asoBidAdapter.js +1 -1
- package/dist/audiencerunBidAdapter.js +1 -1
- package/dist/axonixBidAdapter.js +1 -1
- package/dist/bidglassBidAdapter.js +1 -1
- package/dist/big-richmediaBidAdapter.js +1 -1
- package/dist/bluebillywigBidAdapter.js +1 -1
- package/dist/bridgewellBidAdapter.js +1 -1
- package/dist/brightMountainMediaBidAdapter.js +1 -1
- package/dist/concertBidAdapter.js +1 -1
- package/dist/connectadBidAdapter.js +1 -1
- package/dist/consumableBidAdapter.js +1 -1
- package/dist/conversantBidAdapter.js +1 -1
- package/dist/cpexIdSystem.js +1 -1
- package/dist/craftBidAdapter.js +1 -1
- package/dist/criteoBidAdapter.js +1 -1
- package/dist/dianomiBidAdapter.js +1 -0
- package/dist/dspxBidAdapter.js +1 -1
- package/dist/eplanningBidAdapter.js +1 -1
- package/dist/finativeBidAdapter.js +1 -0
- package/dist/fpdModule.js +1 -1
- package/dist/glimpseBidAdapter.js +1 -1
- package/dist/gmosspBidAdapter.js +1 -1
- package/dist/goldbachBidAdapter.js +1 -1
- package/dist/gridBidAdapter.js +1 -1
- package/dist/gridNMBidAdapter.js +1 -1
- package/dist/gumgumBidAdapter.js +1 -1
- package/dist/h12mediaBidAdapter.js +1 -1
- package/dist/id5IdSystem.js +1 -1
- package/dist/impactifyBidAdapter.js +1 -1
- package/dist/improvedigitalBidAdapter.js +1 -1
- package/dist/inmarBidAdapter.js +1 -1
- package/dist/insticatorBidAdapter.js +1 -1
- package/dist/ixBidAdapter.js +1 -1
- package/dist/jixieBidAdapter.js +1 -1
- package/dist/justpremiumBidAdapter.js +1 -1
- package/dist/konduitAnalyticsAdapter.js +1 -1
- package/dist/kueezBidAdapter.js +1 -1
- package/dist/lassoBidAdapter.js +1 -0
- package/dist/liveyieldAnalyticsAdapter.js +1 -1
- package/dist/logicadBidAdapter.js +1 -1
- package/dist/loglyliftBidAdapter.js +1 -1
- package/dist/malltvAnalyticsAdapter.js +1 -1
- package/dist/marsmediaBidAdapter.js +1 -1
- package/dist/mediafuseBidAdapter.js +1 -1
- package/dist/mediakeysBidAdapter.js +1 -1
- package/dist/medianetBidAdapter.js +1 -1
- package/dist/mediasquareBidAdapter.js +1 -1
- package/dist/mgidBidAdapter.js +1 -1
- package/dist/minutemediaBidAdapter.js +1 -1
- package/dist/nativoBidAdapter.js +1 -1
- package/dist/not-for-prod/prebid.js +119 -115
- package/dist/oguryBidAdapter.js +1 -1
- package/dist/onetagBidAdapter.js +1 -1
- package/dist/ooloAnalyticsAdapter.js +1 -1
- package/dist/outbrainBidAdapter.js +1 -1
- package/dist/parrableIdSystem.js +1 -1
- package/dist/pixfutureBidAdapter.js +1 -1
- package/dist/prebid-core.js +1 -1
- package/dist/publinkIdSystem.js +1 -1
- package/dist/pubmaticBidAdapter.js +1 -1
- package/dist/pubwiseAnalyticsAdapter.js +1 -1
- package/dist/pxyzBidAdapter.js +1 -1
- package/dist/quantcastBidAdapter.js +1 -1
- package/dist/readpeakBidAdapter.js +1 -1
- package/dist/relaidoBidAdapter.js +1 -1
- package/dist/rhythmoneBidAdapter.js +1 -1
- package/dist/riseBidAdapter.js +1 -1
- package/dist/rubiconAnalyticsAdapter.js +1 -1
- package/dist/rubiconBidAdapter.js +1 -1
- package/dist/seedingAllianceBidAdapter.js +1 -1
- package/dist/seedtagBidAdapter.js +1 -1
- package/dist/sharethroughAnalyticsAdapter.js +1 -1
- package/dist/sharethroughBidAdapter.js +1 -1
- package/dist/smaatoBidAdapter.js +1 -1
- package/dist/smartadserverBidAdapter.js +1 -1
- package/dist/smartxBidAdapter.js +1 -1
- package/dist/smilewantedBidAdapter.js +1 -1
- package/dist/sonobiBidAdapter.js +1 -1
- package/dist/sovrnAnalyticsAdapter.js +1 -1
- package/dist/sovrnBidAdapter.js +1 -1
- package/dist/sspBCBidAdapter.js +1 -1
- package/dist/sublimeBidAdapter.js +1 -1
- package/dist/synacormediaBidAdapter.js +1 -1
- package/dist/targetVideoBidAdapter.js +1 -1
- package/dist/teadsBidAdapter.js +1 -1
- package/dist/tncIdSystem.js +1 -0
- package/dist/trionBidAdapter.js +1 -1
- package/dist/tripleliftBidAdapter.js +1 -1
- package/dist/ttdBidAdapter.js +1 -1
- package/dist/ucfunnelAnalyticsAdapter.js +1 -1
- package/dist/underdogmediaBidAdapter.js +1 -1
- package/dist/undertoneBidAdapter.js +1 -1
- package/dist/userId.js +1 -1
- package/dist/vidazooBidAdapter.js +1 -1
- package/dist/videobyteBidAdapter.js +1 -1
- package/dist/visxBidAdapter.js +1 -1
- package/dist/vuukleBidAdapter.js +1 -1
- package/dist/widespaceBidAdapter.js +1 -1
- package/dist/winrBidAdapter.js +1 -1
- package/dist/yahoosspBidAdapter.js +1 -1
- package/dist/yieldlabBidAdapter.js +1 -1
- package/dist/yieldmoBidAdapter.js +1 -1
- package/dist/yieldoneAnalyticsAdapter.js +1 -1
- package/dist/yieldoneBidAdapter.js +1 -1
- package/governance.md +5 -11
- package/gulpHelpers.js +1 -1
- package/modules/.submodules.json +1 -0
- package/modules/33acrossBidAdapter.js +5 -1
- package/modules/adkernelBidAdapter.js +2 -1
- package/modules/adqueryBidAdapter.js +5 -1
- package/modules/cpexIdSystem.js +7 -8
- package/modules/dianomiBidAdapter.js +369 -0
- package/modules/dianomiBidAdapter.md +73 -0
- package/modules/finativeBidAdapter.js +235 -0
- package/modules/finativeBidAdapter.md +45 -0
- package/modules/fpdModule/index.js +6 -5
- package/modules/gumgumBidAdapter.js +2 -0
- package/modules/gumgumBidAdapter.md +19 -1
- package/modules/lassoBidAdapter.js +133 -0
- package/modules/lassoBidAdapter.md +29 -0
- package/modules/medianetBidAdapter.js +9 -5
- package/modules/nativoBidAdapter.js +19 -7
- package/modules/riseBidAdapter.js +1 -0
- package/modules/sonobiBidAdapter.js +28 -9
- package/modules/sovrnBidAdapter.js +16 -10
- package/modules/tncIdSystem.js +63 -0
- package/modules/tncIdSystem.md +33 -0
- package/modules/userId/eids.js +12 -0
- package/modules/userId/eids.md +7 -0
- package/modules/userId/userId.md +17 -0
- package/modules/yieldlabBidAdapter.js +4 -0
- package/modules/yieldmoBidAdapter.js +20 -2
- package/modules/yieldoneBidAdapter.js +12 -1
- package/package.json +1 -1
- package/src/adloader.js +1 -0
- package/src/prebid.js +4 -1
- package/test/spec/modules/33acrossBidAdapter_spec.js +39 -0
- package/test/spec/modules/cpexIdSystem_spec.js +5 -5
- package/test/spec/modules/dianomiBidAdapter_spec.js +1223 -0
- package/test/spec/modules/eids_spec.js +26 -1
- package/test/spec/modules/finativeBidAdapter_spec.js +186 -0
- package/test/spec/modules/fpdModule_spec.js +28 -1
- package/test/spec/modules/gumgumBidAdapter_spec.js +5 -0
- package/test/spec/modules/lassoBidAdapter_spec.js +177 -0
- package/test/spec/modules/medianetBidAdapter_spec.js +24 -1
- package/test/spec/modules/nativoBidAdapter_spec.js +67 -17
- package/test/spec/modules/riseBidAdapter_spec.js +3 -0
- package/test/spec/modules/sonobiBidAdapter_spec.js +38 -23
- package/test/spec/modules/sovrnBidAdapter_spec.js +39 -5
- package/test/spec/modules/tncIdSystem_spec.js +109 -0
- package/test/spec/modules/userId_spec.js +6 -3
- package/test/spec/modules/yieldlabBidAdapter_spec.js +4 -0
- package/test/spec/modules/yieldmoBidAdapter_spec.js +15 -2
- package/test/spec/modules/yieldoneBidAdapter_spec.js +43 -2
- package/test/spec/unit/pbjs_api_spec.js +23 -0
|
@@ -49,6 +49,9 @@ export const spec = {
|
|
|
49
49
|
if (sizes.length > 0) {
|
|
50
50
|
adslotSizes.push(bid.params.adslotId + ':' + sizes.join('|'))
|
|
51
51
|
}
|
|
52
|
+
if (bid.params.extId) {
|
|
53
|
+
query.id = bid.params.extId;
|
|
54
|
+
}
|
|
52
55
|
if (bid.params.targeting) {
|
|
53
56
|
query.t = createTargetingString(bid.params.targeting)
|
|
54
57
|
}
|
|
@@ -165,6 +168,7 @@ export const spec = {
|
|
|
165
168
|
}
|
|
166
169
|
|
|
167
170
|
if (isNative(bidRequest, adType)) {
|
|
171
|
+
// there may be publishers still rely on it
|
|
168
172
|
const url = `${ENDPOINT}/d/${matchedBid.id}/${bidRequest.params.supplyId}/?ts=${timestamp}${extId}${gdprApplies}${gdprConsent}${pvId}`
|
|
169
173
|
bidResponse.adUrl = url
|
|
170
174
|
bidResponse.mediaType = NATIVE
|
|
@@ -25,6 +25,7 @@ const TIME_TO_LIVE = 300;
|
|
|
25
25
|
const NET_REVENUE = true;
|
|
26
26
|
const BANNER_SERVER_ENDPOINT = 'https://ads.yieldmo.com/exchange/prebid';
|
|
27
27
|
const VIDEO_SERVER_ENDPOINT = 'https://ads.yieldmo.com/exchange/prebidvideo';
|
|
28
|
+
const PB_COOKIE_ASSIST_SYNC_ENDPOINT = `https://ads.yieldmo.com/pbcas`;
|
|
28
29
|
const OUTSTREAM_VIDEO_PLAYER_URL = 'https://prebid-outstream.yieldmo.com/bundle.js';
|
|
29
30
|
const OPENRTB_VIDEO_BIDPARAMS = ['mimes', 'startdelay', 'placement', 'startdelay', 'skipafter', 'protocols', 'api',
|
|
30
31
|
'playbackmethod', 'maxduration', 'minduration', 'pos', 'skip', 'skippable'];
|
|
@@ -177,8 +178,25 @@ export const spec = {
|
|
|
177
178
|
return bids;
|
|
178
179
|
},
|
|
179
180
|
|
|
180
|
-
getUserSyncs: function
|
|
181
|
-
|
|
181
|
+
getUserSyncs: function(syncOptions, serverResponses, gdprConsent = {}, uspConsent = '') {
|
|
182
|
+
const syncs = [];
|
|
183
|
+
const gdprFlag = `&gdpr=${gdprConsent.gdprApplies ? 1 : 0}`;
|
|
184
|
+
const gdprString = `&gdpr_consent=${encodeURIComponent((gdprConsent.consentString || ''))}`;
|
|
185
|
+
const usPrivacy = `us_privacy=${encodeURIComponent(uspConsent)}`;
|
|
186
|
+
const pbCookieAssistSyncUrl = `${PB_COOKIE_ASSIST_SYNC_ENDPOINT}?${usPrivacy}${gdprFlag}${gdprString}`;
|
|
187
|
+
|
|
188
|
+
if (syncOptions.iframeEnabled) {
|
|
189
|
+
syncs.push({
|
|
190
|
+
type: 'iframe',
|
|
191
|
+
url: pbCookieAssistSyncUrl + '&type=iframe'
|
|
192
|
+
});
|
|
193
|
+
} else if (syncOptions.pixelEnabled) {
|
|
194
|
+
syncs.push({
|
|
195
|
+
type: 'image',
|
|
196
|
+
url: pbCookieAssistSyncUrl + '&type=image'
|
|
197
|
+
});
|
|
198
|
+
}
|
|
199
|
+
return syncs;
|
|
182
200
|
}
|
|
183
201
|
};
|
|
184
202
|
registerBidder(spec);
|
|
@@ -31,6 +31,8 @@ export const spec = {
|
|
|
31
31
|
const transactionId = bidRequest.transactionId;
|
|
32
32
|
const unitCode = bidRequest.adUnitCode;
|
|
33
33
|
const timeout = config.getConfig('bidderTimeout');
|
|
34
|
+
const language = window.navigator.language;
|
|
35
|
+
const screenSize = window.screen.width + 'x' + window.screen.height;
|
|
34
36
|
const payload = {
|
|
35
37
|
v: 'hb1',
|
|
36
38
|
p: placementId,
|
|
@@ -40,7 +42,9 @@ export const spec = {
|
|
|
40
42
|
tid: transactionId,
|
|
41
43
|
uc: unitCode,
|
|
42
44
|
tmax: timeout,
|
|
43
|
-
t: 'i'
|
|
45
|
+
t: 'i',
|
|
46
|
+
language: language,
|
|
47
|
+
screen_size: screenSize
|
|
44
48
|
};
|
|
45
49
|
|
|
46
50
|
const mediaType = getMediaType(bidRequest);
|
|
@@ -69,6 +73,13 @@ export const spec = {
|
|
|
69
73
|
payload.imuid = imuid;
|
|
70
74
|
}
|
|
71
75
|
|
|
76
|
+
// DACID
|
|
77
|
+
const dacId = deepAccess(bidRequest, 'userId.dacId.id');
|
|
78
|
+
if (isStr(dacId) && !isEmpty(dacId)) {
|
|
79
|
+
payload.dac_id = dacId;
|
|
80
|
+
payload.fuuid = dacId;
|
|
81
|
+
}
|
|
82
|
+
|
|
72
83
|
return {
|
|
73
84
|
method: 'GET',
|
|
74
85
|
url: ENDPOINT_URL,
|
package/package.json
CHANGED
package/src/adloader.js
CHANGED
package/src/prebid.js
CHANGED
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
adUnitsFilter, flatten, getHighestCpm, isArrayOfNums, isGptPubadsDefined, uniques, logInfo,
|
|
6
6
|
contains, logError, isArray, deepClone, deepAccess, isNumber, logWarn, logMessage, isFn,
|
|
7
7
|
transformAdServerTargetingObj, bind, replaceAuctionPrice, replaceClickThrough, insertElement,
|
|
8
|
-
inIframe, callBurl, createInvisibleIframe, generateUUID, unsupportedBidderMessage, isEmpty, mergeDeep
|
|
8
|
+
inIframe, callBurl, createInvisibleIframe, generateUUID, unsupportedBidderMessage, isEmpty, mergeDeep, deepSetValue
|
|
9
9
|
} from './utils.js';
|
|
10
10
|
import { listenMessagesFromCreative } from './secureCreatives.js';
|
|
11
11
|
import { userSync } from './userSync.js';
|
|
@@ -616,6 +616,9 @@ export const startAuction = hook('async', function ({ bidsBackHandler, timeout:
|
|
|
616
616
|
|
|
617
617
|
adUnit.transactionId = generateUUID();
|
|
618
618
|
|
|
619
|
+
// Populate ortb2Imp.ext.tid with transactionId. Specifying a transaction ID per item in the ortb impression array, lets multiple transaction IDs be transmitted in a single bid request.
|
|
620
|
+
deepSetValue(adUnit, 'ortb2Imp.ext.tid', adUnit.transactionId)
|
|
621
|
+
|
|
619
622
|
bidders.forEach(bidder => {
|
|
620
623
|
const adapter = bidderRegistry[bidder];
|
|
621
624
|
const spec = adapter && adapter.getSpec && adapter.getSpec();
|
|
@@ -387,6 +387,45 @@ describe('33acrossBidAdapter:', function () {
|
|
|
387
387
|
|
|
388
388
|
describe('isBidRequestValid:', function() {
|
|
389
389
|
context('basic validation', function() {
|
|
390
|
+
it('returns true for valid bidder name values', function() {
|
|
391
|
+
const validBidderName = [
|
|
392
|
+
'33across',
|
|
393
|
+
'33across_mgni'
|
|
394
|
+
];
|
|
395
|
+
|
|
396
|
+
validBidderName.forEach((bidderName) => {
|
|
397
|
+
const bid = {
|
|
398
|
+
bidder: bidderName,
|
|
399
|
+
params: {
|
|
400
|
+
siteId: 'sample33xGUID123456789'
|
|
401
|
+
}
|
|
402
|
+
};
|
|
403
|
+
|
|
404
|
+
expect(spec.isBidRequestValid(bid)).to.be.true;
|
|
405
|
+
});
|
|
406
|
+
});
|
|
407
|
+
|
|
408
|
+
it('returns false for invalid bidder name values', function() {
|
|
409
|
+
const invalidBidderName = [
|
|
410
|
+
undefined,
|
|
411
|
+
'33',
|
|
412
|
+
'33x',
|
|
413
|
+
'thirtythree',
|
|
414
|
+
''
|
|
415
|
+
];
|
|
416
|
+
|
|
417
|
+
invalidBidderName.forEach((bidderName) => {
|
|
418
|
+
const bid = {
|
|
419
|
+
bidder: bidderName,
|
|
420
|
+
params: {
|
|
421
|
+
siteId: 'sample33xGUID123456789'
|
|
422
|
+
}
|
|
423
|
+
};
|
|
424
|
+
|
|
425
|
+
expect(spec.isBidRequestValid(bid)).to.be.false;
|
|
426
|
+
});
|
|
427
|
+
});
|
|
428
|
+
|
|
390
429
|
it('returns true for valid guid values', function() {
|
|
391
430
|
// NOTE: We ignore whitespace at the start and end since
|
|
392
431
|
// in our experience these are common typos
|
|
@@ -16,21 +16,21 @@ describe('cpexId module', function () {
|
|
|
16
16
|
|
|
17
17
|
describe('getId()', function () {
|
|
18
18
|
it('should return the uid when it exists in cookie', function () {
|
|
19
|
-
getCookieStub.withArgs('
|
|
19
|
+
getCookieStub.withArgs('czaid').returns('cpexIdTest');
|
|
20
20
|
const id = cpexIdSubmodule.getId();
|
|
21
|
-
expect(id).to.be.deep.equal({
|
|
21
|
+
expect(id).to.be.deep.equal({ id: 'cpexIdTest' });
|
|
22
22
|
});
|
|
23
23
|
|
|
24
24
|
cookieTestCasesForEmpty.forEach(testCase => it('should not return the uid when it doesnt exist in cookie', function () {
|
|
25
|
-
getCookieStub.withArgs('
|
|
25
|
+
getCookieStub.withArgs('czaid').returns(testCase);
|
|
26
26
|
const id = cpexIdSubmodule.getId();
|
|
27
|
-
expect(id).to.be.
|
|
27
|
+
expect(id).to.be.undefined;
|
|
28
28
|
}));
|
|
29
29
|
});
|
|
30
30
|
|
|
31
31
|
describe('decode()', function () {
|
|
32
32
|
it('should return the uid when it exists in cookie', function () {
|
|
33
|
-
getCookieStub.withArgs('
|
|
33
|
+
getCookieStub.withArgs('czaid').returns('cpexIdTest');
|
|
34
34
|
const decoded = cpexIdSubmodule.decode();
|
|
35
35
|
expect(decoded).to.be.deep.equal({ cpexId: 'cpexIdTest' });
|
|
36
36
|
});
|