prebid.js 7.49.0 → 7.50.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/dist/33acrossBidAdapter.js +1 -1
- package/dist/33acrossIdSystem.js +1 -1
- package/dist/adagioBidAdapter.js +1 -1
- package/dist/adbookpspBidAdapter.js +1 -1
- package/dist/adgenerationBidAdapter.js +1 -1
- package/dist/adrelevantisBidAdapter.js +1 -1
- package/dist/adtrgtmeBidAdapter.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/axonixBidAdapter.js +1 -1
- package/dist/beopBidAdapter.js +1 -1
- package/dist/bidglassBidAdapter.js +1 -1
- package/dist/big-richmediaBidAdapter.js +1 -1
- package/dist/bridgewellBidAdapter.js +1 -1
- package/dist/brightMountainMediaBidAdapter.js +1 -1
- package/dist/carodaBidAdapter.js +1 -1
- package/dist/chtnwBidAdapter.js +1 -1
- package/dist/concertBidAdapter.js +1 -1
- package/dist/confiantRtdProvider.js +1 -1
- package/dist/connectadBidAdapter.js +1 -1
- package/dist/consumableBidAdapter.js +1 -1
- package/dist/conversantAnalyticsAdapter.js +1 -1
- package/dist/conversantBidAdapter.js +1 -1
- package/dist/craftBidAdapter.js +1 -1
- package/dist/criteoBidAdapter.js +1 -1
- package/dist/cwireBidAdapter.js +1 -1
- package/dist/dependencies.json +3 -0
- package/dist/dspxBidAdapter.js +1 -1
- package/dist/eplanningBidAdapter.js +1 -1
- package/dist/feedadBidAdapter.js +1 -1
- package/dist/finativeBidAdapter.js +1 -1
- package/dist/freewheel-sspBidAdapter.js +1 -1
- package/dist/glimpseBidAdapter.js +1 -1
- package/dist/gmosspBidAdapter.js +1 -1
- package/dist/goldbachBidAdapter.js +1 -1
- package/dist/greenbidsAnalyticsAdapter.js +1 -1
- package/dist/greenbidsRtdProvider.js +1 -1
- package/dist/gridBidAdapter.js +1 -1
- package/dist/gumgumBidAdapter.js +1 -1
- package/dist/h12mediaBidAdapter.js +1 -1
- package/dist/id5IdSystem.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/justpremiumBidAdapter.js +1 -1
- package/dist/kargoBidAdapter.js +1 -1
- package/dist/konduitAnalyticsAdapter.js +1 -1
- package/dist/kueezBidAdapter.js +1 -1
- package/dist/kueezRtbBidAdapter.js +1 -1
- package/dist/kulturemediaBidAdapter.js +1 -1
- package/dist/lassoBidAdapter.js +1 -1
- package/dist/lifestreetBidAdapter.js +1 -1
- package/dist/liveIntentIdSystem.js +1 -1
- package/dist/liveyieldAnalyticsAdapter.js +1 -1
- package/dist/logicadBidAdapter.js +1 -1
- package/dist/loglyliftBidAdapter.js +1 -1
- package/dist/magniteAnalyticsAdapter.js +1 -1
- package/dist/malltvAnalyticsAdapter.js +1 -1
- package/dist/marsmediaBidAdapter.js +1 -1
- package/dist/mediafuseBidAdapter.js +1 -1
- package/dist/mediasquareBidAdapter.js +1 -1
- package/dist/mgidBidAdapter.js +1 -1
- package/dist/minutemediaBidAdapter.js +1 -1
- package/dist/minutemediaplusBidAdapter.js +1 -1
- package/dist/nexx360BidAdapter.js +1 -1
- package/dist/not-for-prod/prebid.js +131 -130
- package/dist/oguryBidAdapter.js +1 -1
- package/dist/onetagBidAdapter.js +1 -1
- package/dist/ooloAnalyticsAdapter.js +1 -1
- package/dist/optidigitalBidAdapter.js +1 -1
- package/dist/outbrainBidAdapter.js +1 -1
- package/dist/parrableIdSystem.js +1 -1
- package/dist/permutiveRtdProvider.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/retailspotBidAdapter.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/shinezBidAdapter.js +1 -1
- package/dist/silverpushBidAdapter.js +1 -0
- 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/stvBidAdapter.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/trionBidAdapter.js +1 -1
- package/dist/tripleliftBidAdapter.js +1 -1
- package/dist/ttdBidAdapter.js +1 -1
- package/dist/ucfunnelAnalyticsAdapter.js +1 -1
- package/dist/uid2IdSystem.js +1 -1
- package/dist/underdogmediaBidAdapter.js +1 -1
- package/dist/undertoneBidAdapter.js +1 -1
- package/dist/vidazooBidAdapter.js +1 -1
- package/dist/video.js +1 -1
- package/dist/videoModule.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/yieldmoBidAdapter.js +1 -1
- package/dist/yieldoneAnalyticsAdapter.js +1 -1
- package/integrationExamples/videoModule/eventsUI/eventsUI.css +205 -0
- package/integrationExamples/videoModule/eventsUI/eventsUI.js +181 -0
- package/integrationExamples/videoModule/jwplayer/eventsUI.html +295 -0
- package/integrationExamples/videoModule/videojs/eventsUI.html +319 -0
- package/libraries/video/shared/helpers.js +14 -0
- package/modules/33acrossBidAdapter.js +1 -1
- package/modules/appnexusBidAdapter.js +1 -0
- package/modules/beopBidAdapter.js +1 -0
- package/modules/confiantRtdProvider.js +15 -12
- package/modules/conversantAnalyticsAdapter.js +7 -5
- package/modules/conversantBidAdapter.js +1 -1
- package/modules/criteoBidAdapter.js +17 -1
- package/modules/gridBidAdapter.js +3 -0
- package/modules/liveIntentIdSystem.js +8 -4
- package/modules/magniteAnalyticsAdapter.js +26 -3
- package/modules/permutiveRtdProvider.js +9 -38
- package/modules/rubiconBidAdapter.js +6 -2
- package/modules/silverpushBidAdapter.js +326 -0
- package/modules/silverpushBidAdapter.md +107 -0
- package/modules/underdogmediaBidAdapter.js +2 -2
- package/modules/videoModule/adQueue.js +2 -2
- package/modules/videoModule/index.js +9 -5
- package/modules/yahoosspBidAdapter.js +6 -0
- package/modules/yahoosspBidAdapter.md +37 -0
- package/package.json +1 -1
- package/test/spec/modules/33acrossBidAdapter_spec.js +4 -3
- package/test/spec/modules/beopBidAdapter_spec.js +4 -0
- package/test/spec/modules/confiantRtdProvider_spec.js +4 -1
- package/test/spec/modules/conversantBidAdapter_spec.js +2 -1
- package/test/spec/modules/criteoBidAdapter_spec.js +109 -0
- package/test/spec/modules/gridBidAdapter_spec.js +3 -0
- package/test/spec/modules/liveIntentIdMinimalSystem_spec.js +28 -0
- package/test/spec/modules/liveIntentIdSystem_spec.js +45 -0
- package/test/spec/modules/magniteAnalyticsAdapter_spec.js +16 -36
- package/test/spec/modules/mass_spec.js +2 -0
- package/test/spec/modules/permutiveRtdProvider_spec.js +0 -20
- package/test/spec/modules/rubiconBidAdapter_spec.js +143 -67
- package/test/spec/modules/silverpushBidAdapter_spec.js +394 -0
- package/test/spec/modules/underdogmediaBidAdapter_spec.js +1 -1
- package/test/spec/modules/videoModule/shared/helpers_spec.js +22 -0
- package/test/spec/modules/yahoosspBidAdapter_spec.js +60 -1
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
# Overview
|
|
2
|
+
|
|
3
|
+
```
|
|
4
|
+
Module Name: Silverpush OpenRTB Bidder Adapter
|
|
5
|
+
Module Type: Bidder Adapter
|
|
6
|
+
Maintainer: prebid@silverpush.co
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
# Description
|
|
10
|
+
|
|
11
|
+
Prebid.JS adapter that connects to the Chocolate Ad Exchange.
|
|
12
|
+
|
|
13
|
+
*NOTE*: The Silverpush Bidder Adapter requires setup and approval before use. Please reach out to prebid@silverpush.co representative for more details.
|
|
14
|
+
|
|
15
|
+
# Bid Parameters
|
|
16
|
+
|
|
17
|
+
## Banner/Video
|
|
18
|
+
|
|
19
|
+
{: .table .table-bordered .table-striped }
|
|
20
|
+
| Name | Scope | Description | Example | Type |
|
|
21
|
+
| -------------- | ----------- | ------------------------------------------ | ------------- | ------------ |
|
|
22
|
+
| `publisherId` | required | Publisher id provided by silverpush | "123456" | String |
|
|
23
|
+
| `bidFloor` | optional | Minimum price in USD. bidFloor applies to a specific unit. For example, use the following value to set a $1.50 floor: 1.50. <br/> | 1.50 | Number |
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
# mediaTypes Parameters
|
|
29
|
+
|
|
30
|
+
## mediaTypes.banner
|
|
31
|
+
|
|
32
|
+
The following banner parameters are supported here so publishers may fully declare their banner inventory:
|
|
33
|
+
|
|
34
|
+
{: .table .table-bordered .table-striped }
|
|
35
|
+
| Name | Scope | Description | Example | Type |
|
|
36
|
+
| --------- | ------------| ----------------------------------------------------------------- | --------- | --------- |
|
|
37
|
+
| sizes | required | Avalaible sizes supported for banner ad unit | [ [300, 250], [300, 600] ] | [[Integer, Integer], [Integer, Integer]] |
|
|
38
|
+
|
|
39
|
+
## mediaTypes.video
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
The following video parameters are supported here so publishers may fully declare their video inventory:
|
|
43
|
+
|
|
44
|
+
{: .table .table-bordered .table-striped }
|
|
45
|
+
| Name | Scope | Description | Example | Type |
|
|
46
|
+
| --------- | ------------| ----------------------------------------------------------------- | --------- | --------- |
|
|
47
|
+
| context | required | instream or outstream |"outstream" | string |
|
|
48
|
+
| playerSize | required | Avalaible sizes supported for video ad unit. | [300, 250] | [Integer, Integer] |
|
|
49
|
+
| mimes | required | List of content MIME types supported by the player. | ["video/mp4"]| [String]|
|
|
50
|
+
| protocols | required | Supported video bid response protocol values. | [2,3,5,6] | [integers]|
|
|
51
|
+
| api | required | Supported API framework values. | [2] | [integers] |
|
|
52
|
+
| maxduration | required | Maximum video ad duration in seconds. | 30 | Integer |
|
|
53
|
+
| minduration | required | Minimum video ad duration in seconds. | 6 | Integer |
|
|
54
|
+
| startdelay | required | Indicates the start delay in seconds for pre-roll, mid-roll, or post-roll ad placements. | 0 | Integer |
|
|
55
|
+
| placement | required | Placement type for the impression. | 1 | Integer |
|
|
56
|
+
| minbitrate | optional | Minimum bit rate in Kbps. | 300 | Integer |
|
|
57
|
+
| maxbitrate | optional | Maximum bit rate in Kbps. | 9600 | Integer |
|
|
58
|
+
| playbackmethod | optional | Playback methods that may be in use. Only one method is typically used in practice. | [2]| [Integers] |
|
|
59
|
+
| linearity | optional | OpenRTB2 linearity. in-strea,overlay... | 1 | Integer |
|
|
60
|
+
| skip | optional | Indicates if the player will allow the video to be skipped, where 0 = no, 1 = yes . | 1 | Integer |
|
|
61
|
+
| skipafter | optional | Number of seconds a video must play before skipping is enabled; only applicable if the ad is skippable. | 5 | Integer |
|
|
62
|
+
| delivery | optional | OpenRTB2 delivery. Supported delivery methods (e.g., streaming, progressive). If none specified, assume all are supported. | 1 | [Integer] |
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
# Example
|
|
66
|
+
```javascript
|
|
67
|
+
var adUnits = [{
|
|
68
|
+
code: 'div-1',
|
|
69
|
+
mediaTypes: {
|
|
70
|
+
banner: {
|
|
71
|
+
sizes: [ [300, 250], [300,600] ]
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
bids: [{
|
|
75
|
+
bidder: 'silverpush',
|
|
76
|
+
params: {
|
|
77
|
+
publisherId: "123456",
|
|
78
|
+
bidFloor: 1.2
|
|
79
|
+
}
|
|
80
|
+
}]
|
|
81
|
+
},{
|
|
82
|
+
code: 'video-1',
|
|
83
|
+
mediaTypes: {
|
|
84
|
+
video: {
|
|
85
|
+
api: [1, 2, 4, 6],
|
|
86
|
+
mimes: ['video/mp4'],
|
|
87
|
+
context: 'instream', // or 'outstream'
|
|
88
|
+
playerSize: [ 640, 480 ],
|
|
89
|
+
protocols: [4,5,6,7],
|
|
90
|
+
placement: 1,
|
|
91
|
+
minduration: 0,
|
|
92
|
+
maxduration: 60,
|
|
93
|
+
startdelay: 0
|
|
94
|
+
}
|
|
95
|
+
},
|
|
96
|
+
bids: [
|
|
97
|
+
{
|
|
98
|
+
bidder: 'silverpush',
|
|
99
|
+
params: {
|
|
100
|
+
publisherId: "123456",
|
|
101
|
+
bidfloor: 2.5
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
]
|
|
105
|
+
}
|
|
106
|
+
];
|
|
107
|
+
```
|
|
@@ -74,7 +74,7 @@ export const spec = {
|
|
|
74
74
|
pbTimeout: config.getConfig('bidderTimeout'),
|
|
75
75
|
pbjsVersion: prebidVersion,
|
|
76
76
|
placements: [],
|
|
77
|
-
ref: deepAccess(bidderRequest, 'refererInfo.
|
|
77
|
+
ref: deepAccess(bidderRequest, 'refererInfo.page') ? bidderRequest.refererInfo.page : undefined,
|
|
78
78
|
usp: {},
|
|
79
79
|
userIds: {
|
|
80
80
|
'33acrossId': deepAccess(validBidRequests[0], 'userId.33acrossId.envelope') ? validBidRequests[0].userId['33acrossId'].envelope : undefined,
|
|
@@ -193,7 +193,7 @@ export const spec = {
|
|
|
193
193
|
creativeId: mid.mid,
|
|
194
194
|
currency: 'USD',
|
|
195
195
|
netRevenue: false,
|
|
196
|
-
ttl: mid.ttl ||
|
|
196
|
+
ttl: mid.ttl || 300,
|
|
197
197
|
meta: {
|
|
198
198
|
advertiserDomains: mid.advertiser_domains || []
|
|
199
199
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { AD_BREAK_END, AUCTION_AD_LOAD_ATTEMPT, AUCTION_AD_LOAD_QUEUED, SETUP_COMPLETE } from '../../libraries/video/constants/events.js'
|
|
2
|
-
import { getExternalVideoEventName } from '../../libraries/video/shared/helpers.js'
|
|
2
|
+
import { getExternalVideoEventName, getExternalVideoEventPayload } from '../../libraries/video/shared/helpers.js'
|
|
3
3
|
|
|
4
4
|
export function AdQueueCoordinator(videoCore, pbEvents) {
|
|
5
5
|
const storage = {};
|
|
@@ -58,6 +58,6 @@ export function AdQueueCoordinator(videoCore, pbEvents) {
|
|
|
58
58
|
|
|
59
59
|
function triggerEvent(eventName, adTagUrl, options) {
|
|
60
60
|
const payload = Object.assign({ adTagUrl }, options);
|
|
61
|
-
pbEvents.emit(getExternalVideoEventName(eventName), payload);
|
|
61
|
+
pbEvents.emit(getExternalVideoEventName(eventName), getExternalVideoEventPayload(eventName, payload));
|
|
62
62
|
}
|
|
63
63
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { config } from '../../src/config.js';
|
|
2
2
|
import { find } from '../../src/polyfill.js';
|
|
3
3
|
import * as events from '../../src/events.js';
|
|
4
|
-
import { mergeDeep } from '../../src/utils.js';
|
|
4
|
+
import { mergeDeep, logWarn } from '../../src/utils.js';
|
|
5
5
|
import { getGlobal } from '../../src/prebidGlobal.js';
|
|
6
6
|
import CONSTANTS from '../../src/constants.json';
|
|
7
7
|
import {
|
|
@@ -20,7 +20,7 @@ import { videoCoreFactory } from './coreVideo.js';
|
|
|
20
20
|
import { gamSubmoduleFactory } from './gamAdServerSubmodule.js';
|
|
21
21
|
import { videoImpressionVerifierFactory } from './videoImpressionVerifier.js';
|
|
22
22
|
import { AdQueueCoordinator } from './adQueue.js';
|
|
23
|
-
import { getExternalVideoEventName } from '../../libraries/video/shared/helpers.js'
|
|
23
|
+
import { getExternalVideoEventName, getExternalVideoEventPayload } from '../../libraries/video/shared/helpers.js'
|
|
24
24
|
|
|
25
25
|
const allVideoEvents = Object.keys(videoEvents).map(eventKey => videoEvents[eventKey]);
|
|
26
26
|
events.addEvents(allVideoEvents.concat([AUCTION_AD_LOAD_ATTEMPT, AUCTION_AD_LOAD_QUEUED, AUCTION_AD_LOAD_ABORT, BID_IMPRESSION, BID_ERROR]).map(getExternalVideoEventName));
|
|
@@ -54,7 +54,7 @@ export function PbVideo(videoCore_, getConfig_, pbGlobal_, pbEvents_, videoEvent
|
|
|
54
54
|
adQueueCoordinator.registerProvider(divId);
|
|
55
55
|
videoCore.initProvider(divId);
|
|
56
56
|
videoCore.onEvents(videoEvents, (type, payload) => {
|
|
57
|
-
pbEvents.emit(getExternalVideoEventName(type), payload);
|
|
57
|
+
pbEvents.emit(getExternalVideoEventName(type), getExternalVideoEventPayload(type, payload));
|
|
58
58
|
}, divId);
|
|
59
59
|
|
|
60
60
|
const adServerConfig = provider.adServer;
|
|
@@ -145,6 +145,10 @@ export function PbVideo(videoCore_, getConfig_, pbGlobal_, pbEvents_, videoEvent
|
|
|
145
145
|
video.context = ortbVideo.placement === PLACEMENT.INSTREAM ? 'instream' : 'outstream';
|
|
146
146
|
}
|
|
147
147
|
|
|
148
|
+
if (!video.plcmt) {
|
|
149
|
+
logWarn('Video.plcmt has not been set. Failure to set a value may result in loss of bids');
|
|
150
|
+
}
|
|
151
|
+
|
|
148
152
|
const width = ortbVideo.w;
|
|
149
153
|
const height = ortbVideo.h;
|
|
150
154
|
if (!video.playerSize && width && height) {
|
|
@@ -199,7 +203,7 @@ export function PbVideo(videoCore_, getConfig_, pbGlobal_, pbEvents_, videoEvent
|
|
|
199
203
|
|
|
200
204
|
const highestCpmBids = pbGlobal.getHighestCpmBids(adUnitCode);
|
|
201
205
|
if (!highestCpmBids.length) {
|
|
202
|
-
pbEvents.emit(getExternalVideoEventName(AUCTION_AD_LOAD_ABORT), options);
|
|
206
|
+
pbEvents.emit(getExternalVideoEventName(AUCTION_AD_LOAD_ABORT), getExternalVideoEventPayload(AUCTION_AD_LOAD_ABORT, options));
|
|
203
207
|
return;
|
|
204
208
|
}
|
|
205
209
|
|
|
@@ -223,7 +227,7 @@ export function PbVideo(videoCore_, getConfig_, pbGlobal_, pbEvents_, videoEvent
|
|
|
223
227
|
}
|
|
224
228
|
|
|
225
229
|
pbGlobal.markWinningBidAsUsed(bid);
|
|
226
|
-
pbEvents.emit(getExternalVideoEventName(eventName), { bid, adEvent: adEventPayload });
|
|
230
|
+
pbEvents.emit(getExternalVideoEventName(eventName), getExternalVideoEventPayload(eventName, { bid, adEvent: adEventPayload }));
|
|
227
231
|
}
|
|
228
232
|
|
|
229
233
|
function getBid(adPayload) {
|
|
@@ -380,6 +380,7 @@ function appendFirstPartyData(outBoundBidRequest, bid) {
|
|
|
380
380
|
const ortb2Object = bid.ortb2;
|
|
381
381
|
const siteObject = deepAccess(ortb2Object, 'site') || undefined;
|
|
382
382
|
const siteContentObject = deepAccess(siteObject, 'content') || undefined;
|
|
383
|
+
const sitePublisherObject = deepAccess(siteObject, 'publisher') || undefined;
|
|
383
384
|
const siteContentDataArray = deepAccess(siteObject, 'content.data') || undefined;
|
|
384
385
|
const appContentObject = deepAccess(ortb2Object, 'app.content') || undefined;
|
|
385
386
|
const appContentDataArray = deepAccess(ortb2Object, 'app.content.data') || undefined;
|
|
@@ -394,6 +395,11 @@ function appendFirstPartyData(outBoundBidRequest, bid) {
|
|
|
394
395
|
outBoundBidRequest.site = validateAppendObject('object', allowedSiteObjectKeys, siteObject, outBoundBidRequest.site);
|
|
395
396
|
};
|
|
396
397
|
|
|
398
|
+
if (sitePublisherObject && isPlainObject(sitePublisherObject)) {
|
|
399
|
+
const allowedPublisherObjectKeys = ['ext'];
|
|
400
|
+
outBoundBidRequest.site.publisher = validateAppendObject('object', allowedPublisherObjectKeys, sitePublisherObject, outBoundBidRequest.site.publisher);
|
|
401
|
+
}
|
|
402
|
+
|
|
397
403
|
if (siteContentObject && isPlainObject(siteContentObject)) {
|
|
398
404
|
const allowedContentStringKeys = ['id', 'title', 'series', 'season', 'genre', 'contentrating', 'language'];
|
|
399
405
|
const allowedContentNumberkeys = ['episode', 'prodq', 'context', 'livestream', 'len'];
|
|
@@ -435,6 +435,43 @@ pbjs.setConfig({
|
|
|
435
435
|
}
|
|
436
436
|
});
|
|
437
437
|
```
|
|
438
|
+
|
|
439
|
+
Notes: The first party site info is filtered and only the following specific keys are allowed in the bidRequests:
|
|
440
|
+
|
|
441
|
+
| Field | Type |
|
|
442
|
+
|-----------------------------|--------|
|
|
443
|
+
| site.name | String |
|
|
444
|
+
| site.domain | String |
|
|
445
|
+
| site.page | String |
|
|
446
|
+
| site.ref | String |
|
|
447
|
+
| site.keywords | String |
|
|
448
|
+
| site.search | String |
|
|
449
|
+
| site.cat | Array |
|
|
450
|
+
| site.sectioncat | Array |
|
|
451
|
+
| site.pagecat | Array |
|
|
452
|
+
| site.ext | Object |
|
|
453
|
+
| site.publisher.ext | Object |
|
|
454
|
+
| site.content.id | String |
|
|
455
|
+
| site.content.title | String |
|
|
456
|
+
| site.content.series | String |
|
|
457
|
+
| site.content.season | String |
|
|
458
|
+
| site.content.genre | String |
|
|
459
|
+
| site.content.contentrating | String |
|
|
460
|
+
| site.content.language | String |
|
|
461
|
+
| site.content.episode | Number |
|
|
462
|
+
| site.content.prodq | Number |
|
|
463
|
+
| site.content.context | Number |
|
|
464
|
+
| site.content.livestream | Number |
|
|
465
|
+
| site.content.len | Number |
|
|
466
|
+
| site.content.cat | Array |
|
|
467
|
+
| site.content.ext | Object |
|
|
468
|
+
| site.content.data | Array |
|
|
469
|
+
| site.content.data[].id | String |
|
|
470
|
+
| site.content.data[].name | String |
|
|
471
|
+
| site.content.data[].segment | Array |
|
|
472
|
+
| site.content.data[].ext | Object |
|
|
473
|
+
|
|
474
|
+
|
|
438
475
|
### Passing First Party "user" data:
|
|
439
476
|
```javascript
|
|
440
477
|
pbjs.setConfig({
|
package/package.json
CHANGED
|
@@ -53,7 +53,8 @@ describe('33acrossBidAdapter:', function () {
|
|
|
53
53
|
brand: 'macOS',
|
|
54
54
|
version: ['11', '6', '8']
|
|
55
55
|
},
|
|
56
|
-
model: ''
|
|
56
|
+
model: '',
|
|
57
|
+
mobile: 0
|
|
57
58
|
}
|
|
58
59
|
},
|
|
59
60
|
id: 'r1',
|
|
@@ -337,7 +338,7 @@ describe('33acrossBidAdapter:', function () {
|
|
|
337
338
|
version: ['11', '6', '8']
|
|
338
339
|
},
|
|
339
340
|
model: '',
|
|
340
|
-
mobile:
|
|
341
|
+
mobile: 0
|
|
341
342
|
}
|
|
342
343
|
}
|
|
343
344
|
}
|
|
@@ -369,7 +370,7 @@ describe('33acrossBidAdapter:', function () {
|
|
|
369
370
|
version: ['11', '6', '8']
|
|
370
371
|
},
|
|
371
372
|
model: '',
|
|
372
|
-
mobile:
|
|
373
|
+
mobile: 0
|
|
373
374
|
}
|
|
374
375
|
}
|
|
375
376
|
},
|
|
@@ -99,6 +99,8 @@ describe('BeOp Bid Adapter tests', () => {
|
|
|
99
99
|
expect(url).to.equal(ENDPOINT);
|
|
100
100
|
expect(payload.pid).to.exist;
|
|
101
101
|
expect(payload.pid).to.equal('5a8af500c9e77c00017e4cad');
|
|
102
|
+
expect(payload.gdpr_applies).to.exist;
|
|
103
|
+
expect(payload.gdpr_applies).to.equals(false);
|
|
102
104
|
expect(payload.slts[0].name).to.exist;
|
|
103
105
|
expect(payload.slts[0].name).to.equal('bellow-article');
|
|
104
106
|
expect(payload.slts[0].flr).to.equal(10);
|
|
@@ -121,6 +123,8 @@ describe('BeOp Bid Adapter tests', () => {
|
|
|
121
123
|
|
|
122
124
|
const request = spec.buildRequests(bidRequests, bidderRequest);
|
|
123
125
|
const payload = JSON.parse(request.data);
|
|
126
|
+
expect(payload.gdpr_applies).to.exist;
|
|
127
|
+
expect(payload.gdpr_applies).to.equals(true);
|
|
124
128
|
expect(payload.tc_string).to.exist;
|
|
125
129
|
expect(payload.tc_string).to.equal('BOJ8RZsOJ8RZsABAB8AAAAAZ+A==');
|
|
126
130
|
expect(payload.url).to.exist;
|
|
@@ -46,6 +46,7 @@ describe('Confiant RTD module', function () {
|
|
|
46
46
|
let listenerCallback;
|
|
47
47
|
const mockWindow = { addEventListener: (a, cb) => (listenerCallback = cb) };
|
|
48
48
|
let billableEventsCounter = 0;
|
|
49
|
+
const propertyId = 'fff';
|
|
49
50
|
|
|
50
51
|
events.on(CONSTANTS.EVENTS.BILLABLE_EVENT, (e) => {
|
|
51
52
|
if (e.vendor === 'confiant') {
|
|
@@ -57,15 +58,17 @@ describe('Confiant RTD module', function () {
|
|
|
57
58
|
}
|
|
58
59
|
});
|
|
59
60
|
|
|
60
|
-
subscribeToConfiantCommFrame(mockWindow);
|
|
61
|
+
subscribeToConfiantCommFrame(mockWindow, propertyId);
|
|
61
62
|
listenerCallback({
|
|
62
63
|
data: {
|
|
64
|
+
type: 'cnft:reportBillableEvent:' + propertyId,
|
|
63
65
|
auctionId: 'auctionId',
|
|
64
66
|
transactionId: 'transactionId'
|
|
65
67
|
}
|
|
66
68
|
});
|
|
67
69
|
listenerCallback({
|
|
68
70
|
data: {
|
|
71
|
+
type: 'cnft:reportBillableEvent:' + propertyId,
|
|
69
72
|
auctionId: 'auctionId',
|
|
70
73
|
transactionId: 'transactionId'
|
|
71
74
|
}
|
|
@@ -221,8 +221,9 @@ describe('Conversant adapter tests', function() {
|
|
|
221
221
|
|
|
222
222
|
it('Verify basic properties', function() {
|
|
223
223
|
expect(spec.code).to.equal('conversant');
|
|
224
|
-
expect(spec.aliases).to.be.an('array').with.lengthOf(
|
|
224
|
+
expect(spec.aliases).to.be.an('array').with.lengthOf(2);
|
|
225
225
|
expect(spec.aliases[0]).to.equal('cnvr');
|
|
226
|
+
expect(spec.aliases[1]).to.equal('epsilon');
|
|
226
227
|
expect(spec.supportedMediaTypes).to.be.an('array').with.lengthOf(2);
|
|
227
228
|
expect(spec.supportedMediaTypes[1]).to.equal('video');
|
|
228
229
|
});
|
|
@@ -710,6 +710,42 @@ describe('The Criteo bidding adapter', function () {
|
|
|
710
710
|
expect(ortbRequest.slots[0].native).to.equal(true);
|
|
711
711
|
});
|
|
712
712
|
|
|
713
|
+
it('should properly forward eids', function () {
|
|
714
|
+
const bidRequests = [
|
|
715
|
+
{
|
|
716
|
+
bidder: 'criteo',
|
|
717
|
+
adUnitCode: 'bid-123',
|
|
718
|
+
transactionId: 'transaction-123',
|
|
719
|
+
mediaTypes: {
|
|
720
|
+
banner: {
|
|
721
|
+
sizes: [[728, 90]]
|
|
722
|
+
}
|
|
723
|
+
},
|
|
724
|
+
userIdAsEids: [
|
|
725
|
+
{
|
|
726
|
+
source: 'criteo.com',
|
|
727
|
+
uids: [{
|
|
728
|
+
id: 'abc',
|
|
729
|
+
atype: 1
|
|
730
|
+
}]
|
|
731
|
+
}
|
|
732
|
+
],
|
|
733
|
+
params: {}
|
|
734
|
+
},
|
|
735
|
+
];
|
|
736
|
+
const request = spec.buildRequests(bidRequests, bidderRequest);
|
|
737
|
+
const ortbRequest = request.data;
|
|
738
|
+
expect(ortbRequest.user.ext.eids).to.deep.equal([
|
|
739
|
+
{
|
|
740
|
+
source: 'criteo.com',
|
|
741
|
+
uids: [{
|
|
742
|
+
id: 'abc',
|
|
743
|
+
atype: 1
|
|
744
|
+
}]
|
|
745
|
+
}
|
|
746
|
+
]);
|
|
747
|
+
});
|
|
748
|
+
|
|
713
749
|
it('should properly detect and forward native flag', function () {
|
|
714
750
|
const bidRequests = [
|
|
715
751
|
{
|
|
@@ -1543,6 +1579,73 @@ describe('The Criteo bidding adapter', function () {
|
|
|
1543
1579
|
}
|
|
1544
1580
|
});
|
|
1545
1581
|
});
|
|
1582
|
+
|
|
1583
|
+
it('should properly build a request when imp.rwdd is present', function () {
|
|
1584
|
+
const bidderRequest = {};
|
|
1585
|
+
const bidRequests = [
|
|
1586
|
+
{
|
|
1587
|
+
bidder: 'criteo',
|
|
1588
|
+
adUnitCode: 'bid-123',
|
|
1589
|
+
transactionId: 'transaction-123',
|
|
1590
|
+
mediaTypes: {
|
|
1591
|
+
banner: {
|
|
1592
|
+
sizes: [[728, 90]]
|
|
1593
|
+
}
|
|
1594
|
+
},
|
|
1595
|
+
params: {
|
|
1596
|
+
zoneId: 123,
|
|
1597
|
+
ext: {
|
|
1598
|
+
bidfloor: 0.75
|
|
1599
|
+
}
|
|
1600
|
+
},
|
|
1601
|
+
ortb2Imp: {
|
|
1602
|
+
rwdd: 1,
|
|
1603
|
+
ext: {
|
|
1604
|
+
data: {
|
|
1605
|
+
someContextAttribute: 'abc'
|
|
1606
|
+
}
|
|
1607
|
+
}
|
|
1608
|
+
}
|
|
1609
|
+
},
|
|
1610
|
+
];
|
|
1611
|
+
|
|
1612
|
+
const request = spec.buildRequests(bidRequests, bidderRequest);
|
|
1613
|
+
expect(request.data.slots[0].rwdd).to.be.not.null;
|
|
1614
|
+
expect(request.data.slots[0].rwdd).to.equal(1);
|
|
1615
|
+
});
|
|
1616
|
+
|
|
1617
|
+
it('should properly build a request when imp.rwdd is false', function () {
|
|
1618
|
+
const bidderRequest = {};
|
|
1619
|
+
const bidRequests = [
|
|
1620
|
+
{
|
|
1621
|
+
bidder: 'criteo',
|
|
1622
|
+
adUnitCode: 'bid-123',
|
|
1623
|
+
transactionId: 'transaction-123',
|
|
1624
|
+
mediaTypes: {
|
|
1625
|
+
banner: {
|
|
1626
|
+
sizes: [[728, 90]]
|
|
1627
|
+
}
|
|
1628
|
+
},
|
|
1629
|
+
params: {
|
|
1630
|
+
zoneId: 123,
|
|
1631
|
+
ext: {
|
|
1632
|
+
bidfloor: 0.75
|
|
1633
|
+
}
|
|
1634
|
+
},
|
|
1635
|
+
ortb2Imp: {
|
|
1636
|
+
rwdd: 0,
|
|
1637
|
+
ext: {
|
|
1638
|
+
data: {
|
|
1639
|
+
someContextAttribute: 'abc'
|
|
1640
|
+
}
|
|
1641
|
+
}
|
|
1642
|
+
}
|
|
1643
|
+
},
|
|
1644
|
+
];
|
|
1645
|
+
|
|
1646
|
+
const request = spec.buildRequests(bidRequests, bidderRequest);
|
|
1647
|
+
expect(request.data.slots[0].rwdd).to.be.undefined;
|
|
1648
|
+
});
|
|
1546
1649
|
});
|
|
1547
1650
|
|
|
1548
1651
|
describe('interpretResponse', function () {
|
|
@@ -1565,6 +1668,11 @@ describe('The Criteo bidding adapter', function () {
|
|
|
1565
1668
|
height: 90,
|
|
1566
1669
|
deal: 'myDealCode',
|
|
1567
1670
|
adomain: ['criteo.com'],
|
|
1671
|
+
ext: {
|
|
1672
|
+
meta: {
|
|
1673
|
+
networkName: 'Criteo'
|
|
1674
|
+
}
|
|
1675
|
+
}
|
|
1568
1676
|
}],
|
|
1569
1677
|
},
|
|
1570
1678
|
};
|
|
@@ -1587,6 +1695,7 @@ describe('The Criteo bidding adapter', function () {
|
|
|
1587
1695
|
expect(bids[0].height).to.equal(90);
|
|
1588
1696
|
expect(bids[0].dealId).to.equal('myDealCode');
|
|
1589
1697
|
expect(bids[0].meta.advertiserDomains[0]).to.equal('criteo.com');
|
|
1698
|
+
expect(bids[0].meta.networkName).to.equal('Criteo');
|
|
1590
1699
|
});
|
|
1591
1700
|
|
|
1592
1701
|
it('should properly parse a bid response with a zoneId', function () {
|
|
@@ -423,6 +423,7 @@ describe('TheMediaGrid Adapter', function () {
|
|
|
423
423
|
api: [1, 2],
|
|
424
424
|
skip: 1,
|
|
425
425
|
placement: 1,
|
|
426
|
+
plcmt: 2,
|
|
426
427
|
minduration: 0,
|
|
427
428
|
playbackmethod: 1,
|
|
428
429
|
startdelay: 0
|
|
@@ -486,6 +487,7 @@ describe('TheMediaGrid Adapter', function () {
|
|
|
486
487
|
'api': [1, 2],
|
|
487
488
|
'skip': 1,
|
|
488
489
|
'placement': 1,
|
|
490
|
+
'plcmt': 2,
|
|
489
491
|
'playbackmethod': 1,
|
|
490
492
|
'startdelay': 0
|
|
491
493
|
}
|
|
@@ -539,6 +541,7 @@ describe('TheMediaGrid Adapter', function () {
|
|
|
539
541
|
],
|
|
540
542
|
'minduration': 0,
|
|
541
543
|
'placement': 1,
|
|
544
|
+
'plcmt': 2,
|
|
542
545
|
'playbackmethod': 1,
|
|
543
546
|
'playersizes': [
|
|
544
547
|
'400x600'
|
|
@@ -73,6 +73,34 @@ describe('LiveIntentMinimalId', function() {
|
|
|
73
73
|
expect(callBackSpy.calledOnce).to.be.true;
|
|
74
74
|
});
|
|
75
75
|
|
|
76
|
+
it('should call the Identity Exchange endpoint with the privided distributorId', function() {
|
|
77
|
+
getCookieStub.returns(null);
|
|
78
|
+
let callBackSpy = sinon.spy();
|
|
79
|
+
let submoduleCallback = liveIntentIdSubmodule.getId({ params: { fireEventDelay: 1, distributorId: 'did-1111' } }).callback;
|
|
80
|
+
submoduleCallback(callBackSpy);
|
|
81
|
+
let request = server.requests[0];
|
|
82
|
+
expect(request.url).to.be.eq('https://idx.liadm.com/idex/did-1111/any?did=did-1111&resolve=nonId');
|
|
83
|
+
request.respond(
|
|
84
|
+
204,
|
|
85
|
+
responseHeader
|
|
86
|
+
);
|
|
87
|
+
expect(callBackSpy.calledOnceWith({})).to.be.true;
|
|
88
|
+
});
|
|
89
|
+
|
|
90
|
+
it('should call the Identity Exchange endpoint without the privided distributorId when appId is provided', function() {
|
|
91
|
+
getCookieStub.returns(null);
|
|
92
|
+
let callBackSpy = sinon.spy();
|
|
93
|
+
let submoduleCallback = liveIntentIdSubmodule.getId({ params: { fireEventDelay: 1, distributorId: 'did-1111', liCollectConfig: { appId: 'a-0001' } } }).callback;
|
|
94
|
+
submoduleCallback(callBackSpy);
|
|
95
|
+
let request = server.requests[0];
|
|
96
|
+
expect(request.url).to.be.eq('https://idx.liadm.com/idex/prebid/any?resolve=nonId');
|
|
97
|
+
request.respond(
|
|
98
|
+
204,
|
|
99
|
+
responseHeader
|
|
100
|
+
);
|
|
101
|
+
expect(callBackSpy.calledOnceWith({})).to.be.true;
|
|
102
|
+
});
|
|
103
|
+
|
|
76
104
|
it('should call the default url of the LiveIntent Identity Exchange endpoint, with a partner', function() {
|
|
77
105
|
getCookieStub.returns(null);
|
|
78
106
|
let callBackSpy = sinon.spy();
|
|
@@ -100,6 +100,23 @@ describe('LiveIntentId', function() {
|
|
|
100
100
|
}, 200);
|
|
101
101
|
});
|
|
102
102
|
|
|
103
|
+
it('should fire an event with the provided distributorId', function (done) {
|
|
104
|
+
liveIntentIdSubmodule.decode({}, { params: { fireEventDelay: 1, distributorId: 'did-1111' } });
|
|
105
|
+
setTimeout(() => {
|
|
106
|
+
expect(server.requests[0].url).to.match(/https:\/\/rp.liadm.com\/j\?.*did=did-1111.*&wpn=prebid.*/);
|
|
107
|
+
done();
|
|
108
|
+
}, 200);
|
|
109
|
+
});
|
|
110
|
+
|
|
111
|
+
it('should fire an event without the provided distributorId when appId is provided', function (done) {
|
|
112
|
+
liveIntentIdSubmodule.decode({}, { params: { fireEventDelay: 1, distributorId: 'did-1111', liCollectConfig: { appId: 'a-0001' } } });
|
|
113
|
+
setTimeout(() => {
|
|
114
|
+
expect(server.requests[0].url).to.match(/https:\/\/rp.liadm.com\/j\?.*aid=a-0001.*&wpn=prebid.*/);
|
|
115
|
+
expect(server.requests[0].url).to.not.match(/.*did=*/);
|
|
116
|
+
done();
|
|
117
|
+
}, 200);
|
|
118
|
+
});
|
|
119
|
+
|
|
103
120
|
it('should initialize LiveConnect and emit an event with a privacy string when decode', function(done) {
|
|
104
121
|
uspConsentDataStub.returns('1YNY');
|
|
105
122
|
gdprConsentDataStub.returns({
|
|
@@ -162,6 +179,34 @@ describe('LiveIntentId', function() {
|
|
|
162
179
|
expect(callBackSpy.calledOnceWith({})).to.be.true;
|
|
163
180
|
});
|
|
164
181
|
|
|
182
|
+
it('should call the Identity Exchange endpoint with the privided distributorId', function() {
|
|
183
|
+
getCookieStub.returns(null);
|
|
184
|
+
let callBackSpy = sinon.spy();
|
|
185
|
+
let submoduleCallback = liveIntentIdSubmodule.getId({ params: { fireEventDelay: 1, distributorId: 'did-1111' } }).callback;
|
|
186
|
+
submoduleCallback(callBackSpy);
|
|
187
|
+
let request = server.requests[0];
|
|
188
|
+
expect(request.url).to.be.eq('https://idx.liadm.com/idex/did-1111/any?did=did-1111&resolve=nonId');
|
|
189
|
+
request.respond(
|
|
190
|
+
204,
|
|
191
|
+
responseHeader
|
|
192
|
+
);
|
|
193
|
+
expect(callBackSpy.calledOnceWith({})).to.be.true;
|
|
194
|
+
});
|
|
195
|
+
|
|
196
|
+
it('should call the Identity Exchange endpoint without the privided distributorId when appId is provided', function() {
|
|
197
|
+
getCookieStub.returns(null);
|
|
198
|
+
let callBackSpy = sinon.spy();
|
|
199
|
+
let submoduleCallback = liveIntentIdSubmodule.getId({ params: { fireEventDelay: 1, distributorId: 'did-1111', liCollectConfig: { appId: 'a-0001' } } }).callback;
|
|
200
|
+
submoduleCallback(callBackSpy);
|
|
201
|
+
let request = server.requests[0];
|
|
202
|
+
expect(request.url).to.be.eq('https://idx.liadm.com/idex/prebid/any?resolve=nonId');
|
|
203
|
+
request.respond(
|
|
204
|
+
204,
|
|
205
|
+
responseHeader
|
|
206
|
+
);
|
|
207
|
+
expect(callBackSpy.calledOnceWith({})).to.be.true;
|
|
208
|
+
});
|
|
209
|
+
|
|
165
210
|
it('should call the default url of the LiveIntent Identity Exchange endpoint, with a partner', function() {
|
|
166
211
|
getCookieStub.returns(null);
|
|
167
212
|
let callBackSpy = sinon.spy();
|