prebid.js 7.3.0 → 7.6.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/.circleci/config.yml +11 -6
- 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/adnuntiusBidAdapter.js +1 -1
- package/dist/adotBidAdapter.js +1 -1
- package/dist/adpod.js +1 -1
- package/dist/adrelevantisBidAdapter.js +1 -1
- package/dist/adrinoBidAdapter.js +1 -1
- package/dist/adtelligentBidAdapter.js +1 -1
- package/dist/adxcgBidAdapter.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/atsAnalyticsAdapter.js +1 -1
- package/dist/axonixBidAdapter.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/byDataAnalyticsAdapter.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/craftBidAdapter.js +1 -1
- package/dist/criteoBidAdapter.js +1 -1
- package/dist/debugging-standalone.js +1 -1
- package/dist/debugging.js +1 -1
- package/dist/dspxBidAdapter.js +1 -1
- package/dist/eplanningBidAdapter.js +1 -1
- package/dist/finativeBidAdapter.js +1 -1
- package/dist/gdprEnforcement.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/hadronIdSystem.js +1 -1
- package/dist/hadronRtdProvider.js +1 -1
- package/dist/id5IdSystem.js +1 -1
- package/dist/imRtdProvider.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/kargoAnalyticsAdapter.js +1 -1
- package/dist/kargoBidAdapter.js +1 -1
- package/dist/konduitAnalyticsAdapter.js +1 -1
- package/dist/kueezBidAdapter.js +1 -1
- package/dist/lassoBidAdapter.js +1 -1
- 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/mediasquareBidAdapter.js +1 -1
- package/dist/mgidBidAdapter.js +1 -1
- package/dist/minutemediaBidAdapter.js +1 -1
- package/dist/missenaBidAdapter.js +1 -1
- package/dist/newspassidBidAdapter.js +1 -0
- package/dist/nextMillenniumBidAdapter.js +1 -1
- package/dist/not-for-prod/prebid.js +131 -127
- package/dist/oguryBidAdapter.js +1 -1
- package/dist/onetagBidAdapter.js +1 -1
- package/dist/ooloAnalyticsAdapter.js +1 -1
- package/dist/openxOrtbBidAdapter.js +1 -0
- package/dist/outbrainBidAdapter.js +1 -1
- package/dist/parrableIdSystem.js +1 -1
- package/dist/pixfutureBidAdapter.js +1 -1
- package/dist/prebid-core.js +2 -2
- package/dist/priceFloors.js +1 -1
- package/dist/pubCommonId.js +1 -1
- package/dist/publinkIdSystem.js +1 -1
- package/dist/pubmaticBidAdapter.js +1 -1
- package/dist/pubwiseAnalyticsAdapter.js +1 -1
- package/dist/pubxaiAnalyticsAdapter.js +1 -1
- package/dist/pxyzBidAdapter.js +1 -1
- package/dist/quantcastBidAdapter.js +1 -1
- package/dist/rasBidAdapter.js +1 -0
- 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/sharedIdSystem.js +1 -1
- package/dist/sharethroughAnalyticsAdapter.js +1 -1
- package/dist/sharethroughBidAdapter.js +1 -1
- package/dist/shinezBidAdapter.js +1 -0
- package/dist/sizeMappingV2.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/taboolaBidAdapter.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/underdogmediaBidAdapter.js +1 -1
- package/dist/undertoneBidAdapter.js +1 -1
- package/dist/ventesBidAdapter.js +1 -1
- package/dist/vidazooBidAdapter.js +1 -1
- package/dist/videobyteBidAdapter.js +1 -1
- package/dist/visxBidAdapter.js +1 -1
- package/dist/vrtcalBidAdapter.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/gulpfile.js +1 -1
- package/karma.conf.maker.js +3 -1
- package/modules/adgenerationBidAdapter.js +24 -1
- package/modules/adnuntiusBidAdapter.js +26 -8
- package/modules/adotBidAdapter.js +13 -4
- package/modules/adrinoBidAdapter.js +10 -2
- package/modules/adrinoBidAdapter.md +6 -0
- package/modules/adtelligentBidAdapter.js +2 -1
- package/modules/appnexusBidAdapter.js +3 -3
- package/modules/atsAnalyticsAdapter.js +4 -5
- package/modules/byDataAnalyticsAdapter.js +172 -74
- package/modules/byDataAnalyticsAdapter.md +5 -6
- package/modules/consumableBidAdapter.js +12 -1
- package/modules/criteoBidAdapter.js +7 -1
- package/modules/cwireBidAdapter.md +1 -1
- package/modules/debugging/bidInterceptor.js +1 -1
- package/modules/debugging/index.js +2 -1
- package/modules/eplanningBidAdapter.js +82 -97
- package/modules/gdprEnforcement.js +8 -14
- package/modules/gridNMBidAdapter.js +45 -4
- package/modules/hadronAnalyticsAdapter.md +5 -5
- package/modules/hadronIdSystem.js +18 -5
- package/modules/hadronIdSystem.md +15 -11
- package/modules/hadronRtdProvider.js +14 -1
- package/modules/hadronRtdProvider.md +17 -13
- package/modules/imRtdProvider.js +0 -8
- package/modules/insticatorBidAdapter.js +9 -0
- package/modules/ixBidAdapter.js +462 -58
- package/modules/ixBidAdapter.md +95 -5
- package/modules/kargoAnalyticsAdapter.js +88 -6
- package/modules/kargoAnalyticsAdapter.md +33 -0
- package/modules/kargoBidAdapter.js +1 -2
- package/modules/minutemediaBidAdapter.js +1 -0
- package/modules/missenaBidAdapter.js +20 -2
- package/modules/newspassidBidAdapter.js +649 -0
- package/modules/nextMillenniumBidAdapter.js +17 -1
- package/modules/oguryBidAdapter.js +2 -0
- package/modules/openxBidAdapter.md +3 -1
- package/modules/openxOrtbBidAdapter.js +349 -0
- package/modules/openxOrtbBidAdapter.md +105 -0
- package/modules/priceFloors.js +1 -1
- package/modules/pubCommonId.js +1 -2
- package/modules/pubxaiAnalyticsAdapter.js +6 -1
- package/modules/rasBidAdapter.js +149 -0
- package/modules/rasBidAdapter.md +50 -0
- package/modules/readpeakBidAdapter.js +15 -6
- package/modules/relaidoBidAdapter.js +19 -4
- package/modules/seedtagBidAdapter.js +37 -1
- package/modules/sharedIdSystem.js +11 -5
- package/modules/sharethroughBidAdapter.js +9 -24
- package/modules/shinezBidAdapter.js +435 -0
- package/modules/shinezBidAdapter.md +76 -0
- package/modules/taboolaBidAdapter.js +1 -1
- package/modules/taboolaBidAdapter.md +3 -3
- package/modules/ventesBidAdapter.js +1 -1
- package/modules/ventesBidAdapter.md +1 -1
- package/modules/vrtcalBidAdapter.js +35 -0
- package/package.json +1 -1
- package/plugins/pbjsGlobals.js +2 -1
- package/src/storageManager.js +4 -5
- package/test/spec/modules/adgenerationBidAdapter_spec.js +52 -4
- package/test/spec/modules/adnuntiusBidAdapter_spec.js +126 -14
- package/test/spec/modules/adotBidAdapter_spec.js +12 -9
- package/test/spec/modules/adrinoBidAdapter_spec.js +22 -0
- package/test/spec/modules/appnexusBidAdapter_spec.js +165 -156
- package/test/spec/modules/byDataAnalyticsAdapter_spec.js +74 -24
- package/test/spec/modules/consumableBidAdapter_spec.js +75 -0
- package/test/spec/modules/criteoBidAdapter_spec.js +15 -5
- package/test/spec/modules/debugging_mod_spec.js +7 -0
- package/test/spec/modules/eplanningBidAdapter_spec.js +58 -18
- package/test/spec/modules/gdprEnforcement_spec.js +53 -100
- package/test/spec/modules/gridNMBidAdapter_spec.js +32 -0
- package/test/spec/modules/hadronIdSystem_spec.js +2 -2
- package/test/spec/modules/imRtdProvider_spec.js +0 -1
- package/test/spec/modules/insticatorBidAdapter_spec.js +22 -1
- package/test/spec/modules/ixBidAdapter_spec.js +470 -10
- package/test/spec/modules/kargoAnalyticsAdapter_spec.js +42 -0
- package/test/spec/modules/kargoBidAdapter_spec.js +1 -0
- package/test/spec/modules/minutemediaBidAdapter_spec.js +3 -0
- package/test/spec/modules/missenaBidAdapter_spec.js +36 -14
- package/test/spec/modules/newspassidBidAdapter_spec.js +1793 -0
- package/test/spec/modules/nextMillenniumBidAdapter_spec.js +20 -0
- package/test/spec/modules/openxOrtbBidAdapter_spec.js +1303 -0
- package/test/spec/modules/pubxaiAnalyticsAdapter_spec.js +5 -0
- package/test/spec/modules/rasBidAdapter_spec.js +190 -0
- package/test/spec/modules/readpeakBidAdapter_spec.js +1 -0
- package/test/spec/modules/relaidoBidAdapter_spec.js +29 -2
- package/test/spec/modules/seedtagBidAdapter_spec.js +29 -0
- package/test/spec/modules/sharethroughBidAdapter_spec.js +4 -4
- package/test/spec/modules/shinezBidAdapter_spec.js +479 -0
- package/test/spec/modules/taboolaBidAdapter_spec.js +1 -1
- package/test/spec/modules/ventesBidAdapter_spec.js +2 -2
- package/test/spec/modules/vrtcalBidAdapter_spec.js +17 -0
- package/webpack.conf.js +1 -1
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
# Overview
|
|
2
|
+
|
|
3
|
+
```
|
|
4
|
+
Module Name: Ringier Axel Springer Bidder Adapter
|
|
5
|
+
Module Type: Bidder Adapter
|
|
6
|
+
Maintainer: support@ringpublishing.com
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
# Description
|
|
10
|
+
|
|
11
|
+
Module that connects to Ringer Axel Springer demand sources.
|
|
12
|
+
Only banner format is supported.
|
|
13
|
+
|
|
14
|
+
# Test Parameters
|
|
15
|
+
```js
|
|
16
|
+
var adUnits = [{
|
|
17
|
+
code: 'test-div-ad',
|
|
18
|
+
mediaTypes: {
|
|
19
|
+
banner: {
|
|
20
|
+
sizes: [[300, 250], [300, 600]]
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
bids: [{
|
|
24
|
+
bidder: 'ras',
|
|
25
|
+
params: {
|
|
26
|
+
network: '4178463',
|
|
27
|
+
site: 'test',
|
|
28
|
+
area: 'areatest',
|
|
29
|
+
slot: 'slot'
|
|
30
|
+
}
|
|
31
|
+
}]
|
|
32
|
+
}];
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
# Parameters
|
|
36
|
+
|
|
37
|
+
| Name | Scope | Type | Description | Example
|
|
38
|
+
| --- | --- | --- | --- | ---
|
|
39
|
+
| network | required | String | Specific identifier provided by RAS | `"4178463"`
|
|
40
|
+
| site | required | String | Specific identifier name (case-insensitive) that is associated with this ad unit and provided by RAS | `"example_com"`
|
|
41
|
+
| area | required | String | Ad unit category name; only case-insensitive alphanumeric with underscores and hyphens are allowed | `"sport"`
|
|
42
|
+
| slot | required | String | Ad unit placement name (case-insensitive) provided by RAS | `"slot"`
|
|
43
|
+
| pageContext | optional | Object | Web page context data | `{}`
|
|
44
|
+
| pageContext.dr | optional | String | Document referrer URL address | `"https://example.com/"`
|
|
45
|
+
| pageContext.du | optional | String | Document URL address | `"https://example.com/sport/football/article.html?id=932016a5-02fc-4d5c-b643-fafc2f270f06"`
|
|
46
|
+
| pageContext.dv | optional | String | Document virtual address as slash-separated path that may consist of any number of parts (case-insensitive alphanumeric with underscores and hyphens); first part should be the same as `site` value and second as `area` value; next parts may reflect website navigation | `"example_com/sport/football"`
|
|
47
|
+
| pageContext.keyWords | optional | String[] | List of keywords associated with this ad unit; only case-insensitive alphanumeric with underscores and hyphens are allowed | `["euro", "lewandowski"]`
|
|
48
|
+
| pageContext.keyValues | optional | Object | Key-values associated with this ad unit (case-insensitive); following characters are not allowed in the values: `" ' = ! + # * ~ ; ^ ( ) < > [ ] & @` | `{}`
|
|
49
|
+
| pageContext.keyValues.ci | optional | String | Content unique identifier | `"932016a5-02fc-4d5c-b643-fafc2f270f06"`
|
|
50
|
+
| pageContext.keyValues.adunit | optional | String | Ad unit name | `"example_com/sport"`
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {logError, replaceAuctionPrice} from '../src/utils.js';
|
|
2
|
-
import {registerBidder} from '../src/adapters/bidderFactory.js';
|
|
3
|
-
import {config} from '../src/config.js';
|
|
4
|
-
import {
|
|
1
|
+
import { logError, replaceAuctionPrice, triggerPixel, isStr } from '../src/utils.js';
|
|
2
|
+
import { registerBidder } from '../src/adapters/bidderFactory.js';
|
|
3
|
+
import { config } from '../src/config.js';
|
|
4
|
+
import { NATIVE, BANNER } from '../src/mediaTypes.js';
|
|
5
5
|
|
|
6
6
|
export const ENDPOINT = 'https://app.readpeak.com/header/prebid';
|
|
7
7
|
|
|
@@ -64,8 +64,16 @@ export const spec = {
|
|
|
64
64
|
};
|
|
65
65
|
},
|
|
66
66
|
|
|
67
|
-
interpretResponse: (response, request) =>
|
|
68
|
-
bidResponseAvailable(request, response)
|
|
67
|
+
interpretResponse: (response, request) => {
|
|
68
|
+
return bidResponseAvailable(request, response)
|
|
69
|
+
},
|
|
70
|
+
|
|
71
|
+
onBidWon: (bid) => {
|
|
72
|
+
if (bid.burl && isStr(bid.burl)) {
|
|
73
|
+
bid.burl = replaceAuctionPrice(bid.burl, bid.cpm);
|
|
74
|
+
triggerPixel(bid.burl);
|
|
75
|
+
}
|
|
76
|
+
},
|
|
69
77
|
};
|
|
70
78
|
|
|
71
79
|
function bidResponseAvailable(bidRequest, bidResponse) {
|
|
@@ -103,6 +111,7 @@ function bidResponseAvailable(bidRequest, bidResponse) {
|
|
|
103
111
|
bid.ad = idToBidMap[id].adm
|
|
104
112
|
bid.width = idToBidMap[id].w
|
|
105
113
|
bid.height = idToBidMap[id].h
|
|
114
|
+
bid.burl = idToBidMap[id].burl
|
|
106
115
|
}
|
|
107
116
|
if (idToBidMap[id].adomain) {
|
|
108
117
|
bid.meta = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { deepAccess, logWarn, getBidIdParameter, parseQueryStringParameters, triggerPixel, generateUUID, isArray } from '../src/utils.js';
|
|
1
|
+
import { deepAccess, logWarn, getBidIdParameter, parseQueryStringParameters, triggerPixel, generateUUID, isArray, isNumber } from '../src/utils.js';
|
|
2
2
|
import { registerBidder } from '../src/adapters/bidderFactory.js';
|
|
3
3
|
import { BANNER, VIDEO } from '../src/mediaTypes.js';
|
|
4
4
|
import { Renderer } from '../src/Renderer.js';
|
|
@@ -6,7 +6,7 @@ import { getStorageManager } from '../src/storageManager.js';
|
|
|
6
6
|
|
|
7
7
|
const BIDDER_CODE = 'relaido';
|
|
8
8
|
const BIDDER_DOMAIN = 'api.relaido.jp';
|
|
9
|
-
const ADAPTER_VERSION = '1.0.
|
|
9
|
+
const ADAPTER_VERSION = '1.0.8';
|
|
10
10
|
const DEFAULT_TTL = 300;
|
|
11
11
|
const UUID_KEY = 'relaido_uuid';
|
|
12
12
|
|
|
@@ -44,7 +44,10 @@ function buildRequests(validBidRequests, bidderRequest) {
|
|
|
44
44
|
let height = 0;
|
|
45
45
|
|
|
46
46
|
if (hasVideoMediaType(bidRequest) && isVideoValid(bidRequest)) {
|
|
47
|
-
|
|
47
|
+
let playerSize = getValidSizes(deepAccess(bidRequest, 'mediaTypes.video.playerSize'));
|
|
48
|
+
if (playerSize.length === 0) {
|
|
49
|
+
playerSize = getValidSizes(deepAccess(bidRequest, 'params.video.playerSize'));
|
|
50
|
+
}
|
|
48
51
|
width = playerSize[0][0];
|
|
49
52
|
height = playerSize[0][1];
|
|
50
53
|
mediaType = VIDEO;
|
|
@@ -253,7 +256,10 @@ function isBannerValid(bid) {
|
|
|
253
256
|
}
|
|
254
257
|
|
|
255
258
|
function isVideoValid(bid) {
|
|
256
|
-
|
|
259
|
+
let playerSize = getValidSizes(deepAccess(bid, 'mediaTypes.video.playerSize'));
|
|
260
|
+
if (playerSize.length === 0) {
|
|
261
|
+
playerSize = getValidSizes(deepAccess(bid, 'params.video.playerSize'));
|
|
262
|
+
}
|
|
257
263
|
if (playerSize.length > 0) {
|
|
258
264
|
const context = deepAccess(bid, 'mediaTypes.video.context');
|
|
259
265
|
if (context && context === 'outstream') {
|
|
@@ -300,6 +306,15 @@ function getValidSizes(sizes) {
|
|
|
300
306
|
if ((width >= 300 && height >= 250)) {
|
|
301
307
|
result.push([width, height]);
|
|
302
308
|
}
|
|
309
|
+
} else if (isNumber(sizes[i])) {
|
|
310
|
+
const width = sizes[0];
|
|
311
|
+
const height = sizes[1];
|
|
312
|
+
if (width == 1 && height == 1) {
|
|
313
|
+
return [[1, 1]];
|
|
314
|
+
}
|
|
315
|
+
if ((width >= 300 && height >= 250)) {
|
|
316
|
+
return [[width, height]];
|
|
317
|
+
}
|
|
303
318
|
}
|
|
304
319
|
}
|
|
305
320
|
}
|
|
@@ -147,6 +147,36 @@ function buildBidResponse(seedtagBid) {
|
|
|
147
147
|
return bid;
|
|
148
148
|
}
|
|
149
149
|
|
|
150
|
+
/**
|
|
151
|
+
*
|
|
152
|
+
* @returns Measure time to first byte implementation
|
|
153
|
+
* @see https://web.dev/ttfb/
|
|
154
|
+
* https://developer.mozilla.org/en-US/docs/Web/API/Navigation_timing_API
|
|
155
|
+
*/
|
|
156
|
+
function ttfb() {
|
|
157
|
+
const ttfb = (() => {
|
|
158
|
+
// Timing API V2
|
|
159
|
+
try {
|
|
160
|
+
const entry = performance.getEntriesByType('navigation')[0];
|
|
161
|
+
return Math.round(entry.responseStart - entry.startTime);
|
|
162
|
+
} catch (e) {
|
|
163
|
+
// Timing API V1
|
|
164
|
+
try {
|
|
165
|
+
const entry = performance.timing;
|
|
166
|
+
return Math.round(entry.responseStart - entry.fetchStart);
|
|
167
|
+
} catch (e) {
|
|
168
|
+
// Timing API not available
|
|
169
|
+
return 0;
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
})();
|
|
173
|
+
|
|
174
|
+
// prevent negative or excessive value
|
|
175
|
+
// @see https://github.com/googleChrome/web-vitals/issues/162
|
|
176
|
+
// https://github.com/googleChrome/web-vitals/issues/137
|
|
177
|
+
return ttfb >= 0 && ttfb <= performance.now() ? ttfb : 0;
|
|
178
|
+
}
|
|
179
|
+
|
|
150
180
|
export function getTimeoutUrl (data) {
|
|
151
181
|
let queryParams = '';
|
|
152
182
|
if (
|
|
@@ -195,7 +225,9 @@ export const spec = {
|
|
|
195
225
|
timeout: bidderRequest.timeout,
|
|
196
226
|
version: '$prebid.version$',
|
|
197
227
|
connectionType: getConnectionType(),
|
|
198
|
-
|
|
228
|
+
auctionStart: bidderRequest.auctionStart || Date.now(),
|
|
229
|
+
ttfb: ttfb(),
|
|
230
|
+
bidRequests: _map(validBidRequests, buildBidRequest),
|
|
199
231
|
};
|
|
200
232
|
|
|
201
233
|
if (payload.cmp) {
|
|
@@ -204,6 +236,10 @@ export const spec = {
|
|
|
204
236
|
payload['cd'] = bidderRequest.gdprConsent.consentString;
|
|
205
237
|
}
|
|
206
238
|
|
|
239
|
+
if (bidderRequest.uspConsent) {
|
|
240
|
+
payload['uspConsent'] = bidderRequest.uspConsent
|
|
241
|
+
}
|
|
242
|
+
|
|
207
243
|
const payloadString = JSON.stringify(payload)
|
|
208
244
|
return {
|
|
209
245
|
method: 'POST',
|
|
@@ -5,13 +5,13 @@
|
|
|
5
5
|
* @requires module:modules/userId
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import {
|
|
8
|
+
import { parseUrl, buildUrl, triggerPixel, logInfo, hasDeviceAccess, generateUUID } from '../src/utils.js';
|
|
9
9
|
import {submodule} from '../src/hook.js';
|
|
10
|
-
import {coppaDataHandler} from '../src/adapterManager.js';
|
|
10
|
+
import { coppaDataHandler } from '../src/adapterManager.js';
|
|
11
11
|
import {getStorageManager} from '../src/storageManager.js';
|
|
12
12
|
|
|
13
|
-
const
|
|
14
|
-
export const storage = getStorageManager({moduleName: 'pubCommonId'
|
|
13
|
+
const GVLID = 887;
|
|
14
|
+
export const storage = getStorageManager({gvlid: GVLID, moduleName: 'pubCommonId'});
|
|
15
15
|
const COOKIE = 'cookie';
|
|
16
16
|
const LOCAL_STORAGE = 'html5';
|
|
17
17
|
const OPTOUT_NAME = '_pubcid_optout';
|
|
@@ -74,6 +74,11 @@ export const sharedIdSystemSubmodule = {
|
|
|
74
74
|
*/
|
|
75
75
|
name: 'sharedId',
|
|
76
76
|
aliasName: 'pubCommonId',
|
|
77
|
+
/**
|
|
78
|
+
* Vendor id of prebid
|
|
79
|
+
* @type {Number}
|
|
80
|
+
*/
|
|
81
|
+
gvlid: GVLID,
|
|
77
82
|
|
|
78
83
|
/**
|
|
79
84
|
* decode the stored id value for passing to bid requests
|
|
@@ -88,7 +93,8 @@ export const sharedIdSystemSubmodule = {
|
|
|
88
93
|
return undefined;
|
|
89
94
|
}
|
|
90
95
|
logInfo(' Decoded value PubCommonId ' + value);
|
|
91
|
-
|
|
96
|
+
const idObj = {'pubcid': value};
|
|
97
|
+
return idObj;
|
|
92
98
|
},
|
|
93
99
|
/**
|
|
94
100
|
* performs action to obtain id
|
|
@@ -4,7 +4,7 @@ import { config } from '../src/config.js';
|
|
|
4
4
|
import { BANNER, VIDEO } from '../src/mediaTypes.js';
|
|
5
5
|
import { createEidsArray } from './userId/eids.js';
|
|
6
6
|
|
|
7
|
-
const VERSION = '4.1.
|
|
7
|
+
const VERSION = '4.1.1';
|
|
8
8
|
const BIDDER_CODE = 'sharethrough';
|
|
9
9
|
const SUPPLY_ID = 'WYu2BXv1';
|
|
10
10
|
|
|
@@ -34,9 +34,8 @@ export const sharethroughAdapterSpec = {
|
|
|
34
34
|
cur: ['USD'],
|
|
35
35
|
tmax: timeout,
|
|
36
36
|
site: {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
page: deepAccess(bidderRequest, 'refererInfo.page') || window.location.href,
|
|
37
|
+
domain: deepAccess(bidderRequest, 'refererInfo.domain', window.location.hostname),
|
|
38
|
+
page: deepAccess(bidderRequest, 'refererInfo.page', window.location.href),
|
|
40
39
|
ref: deepAccess(bidderRequest, 'refererInfo.ref'),
|
|
41
40
|
...firstPartyData.site,
|
|
42
41
|
},
|
|
@@ -66,7 +65,7 @@ export const sharethroughAdapterSpec = {
|
|
|
66
65
|
|
|
67
66
|
req.user = nullish(firstPartyData.user, {});
|
|
68
67
|
if (!req.user.ext) req.user.ext = {};
|
|
69
|
-
req.user.ext.eids =
|
|
68
|
+
req.user.ext.eids = createEidsArray(deepAccess(bidRequests[0], 'userId')) || [];
|
|
70
69
|
|
|
71
70
|
if (bidderRequest.gdprConsent) {
|
|
72
71
|
const gdprApplies = bidderRequest.gdprConsent.gdprApplies === true;
|
|
@@ -181,21 +180,12 @@ export const sharethroughAdapterSpec = {
|
|
|
181
180
|
});
|
|
182
181
|
},
|
|
183
182
|
|
|
184
|
-
getUserSyncs: (syncOptions, serverResponses
|
|
185
|
-
const
|
|
186
|
-
const syncs = [];
|
|
187
|
-
const shouldCookieSync = syncOptions.pixelEnabled &&
|
|
188
|
-
serverResponses.length > 0 &&
|
|
189
|
-
serverResponses[0].body &&
|
|
190
|
-
serverResponses[0].body.cookieSyncUrls;
|
|
191
|
-
|
|
192
|
-
if (shouldCookieSync) {
|
|
193
|
-
serverResponses[0].body.cookieSyncUrls.forEach(url => {
|
|
194
|
-
syncs.push({ type: 'image', url: url + syncParams });
|
|
195
|
-
});
|
|
196
|
-
}
|
|
183
|
+
getUserSyncs: (syncOptions, serverResponses) => {
|
|
184
|
+
const shouldCookieSync = syncOptions.pixelEnabled && deepAccess(serverResponses, '0.body.cookieSyncUrls') !== undefined;
|
|
197
185
|
|
|
198
|
-
return
|
|
186
|
+
return shouldCookieSync
|
|
187
|
+
? serverResponses[0].body.cookieSyncUrls.map(url => ({ type: 'image', url: url }))
|
|
188
|
+
: [];
|
|
199
189
|
},
|
|
200
190
|
|
|
201
191
|
// Empty implementation for prebid core to be able to find it
|
|
@@ -244,11 +234,6 @@ function getBidRequestFloor(bid) {
|
|
|
244
234
|
return floor !== null ? floor : bid.params.floor;
|
|
245
235
|
}
|
|
246
236
|
|
|
247
|
-
function userIdAsEids(bidRequest) {
|
|
248
|
-
const eids = createEidsArray(deepAccess(bidRequest, 'userId')) || [];
|
|
249
|
-
return eids;
|
|
250
|
-
}
|
|
251
|
-
|
|
252
237
|
function getProtocol() {
|
|
253
238
|
return window.location.protocol;
|
|
254
239
|
}
|