1plus x RTD Adapter: remove bidder specific handling enforcement (DC 3634)#10001
1plus x RTD Adapter: remove bidder specific handling enforcement (DC 3634)#10001patmmccann merged 7 commits intoprebid:masterfrom
Conversation
modules/1plusXRtdProvider.js
Outdated
| // Therefore, writing them in `site.keywords` until it's supported | ||
| // Other bidAdapters do fine with `site.content.data.segment` | ||
| const site = { | ||
| keywords: topics.join(',') |
There was a problem hiding this comment.
appnexus takes in keywords as key=value pairs, e.g. "segmentName=segmentValue,otherName=otherValue"
To do the equivalent of the previous revision, which was using setConfig({appnexusAuctionKeywords: {1plusX}}), I believe you want your keywords to be in the form 1plusX=topic1,1plusX=topic2, etc.
modules/1plusXRtdProvider.js
Outdated
| const updatedBidderConfig = updateBidderConfig(bidder, ortb2Updates, bidderConfigs); | ||
| if (updatedBidderConfig) { | ||
| setAppnexusAudiences(segments); | ||
| config.setBidderConfig({ |
There was a problem hiding this comment.
since version 7 this is not the correct way to add first party data, see this for some more info (including the yellow warning about this pattern specifically).
The first argument to getBidRequestData contains an ortb2Fragments object that you can augment, the logic will stay very similar but instead of doing setBidderConfig({config: {ortb2: myUpdatedFPD}}) it should do mergeDeep(ortb2Fragments.bidder[bidderCode], myUpdatedFPD) for each bidderCode you want to pass data to; or merge into ortb2Fragments.global directly if that's appropriate.
The issue with using setBidderConfig is that it won't take effect until the next auction (since v7).
|
I tried making the changes but I'm stuck I'll resume my work on this during the week |
|
Hi @dgirardi |
| const bidderConfigCopy = mergeDeep({}, bidderConfigs[bidder]); | ||
| export const updateBidderConfig = (bidder, ortb2Updates, biddersOrtb2) => { | ||
| const { siteKeywords, siteContentData, userData } = ortb2Updates; | ||
| const bidderConfig = deepAccess(biddersOrtb2, bidder); |
There was a problem hiding this comment.
bidderConfig can be undefined here, if you are the first to set it up for a particular bidder. You want to change this to
const bidderConfig = biddersOrtb2[bidder] = biddersOrtb2[bidder] || {}There was a problem hiding this comment.
Then, right before this line, I'll do a:
mergeDeep(biddersOrtb2, { [bidder]: {} });
That way I'll be sure to set something in the bidderConfig.
If I did
const bidderConfig = biddersOrtb2[bidder] = biddersOrtb2[bidder] || {}
I would set values to an object I'll lose after exiting the function
modules/1plusXRtdProvider.js
Outdated
| return bidderConfigCopy; | ||
| }; | ||
|
|
||
| const setAppnexusAudiences = (audiences) => { |
There was a problem hiding this comment.
this is no longer needed since appnexus now also picks it up from site.keywords as you have set them up.
package-lock.json
Outdated
| "": { | ||
| "name": "prebid.js", | ||
| "version": "7.48.0-pre", | ||
| "version": "7.51.0-pre", |
There was a problem hiding this comment.
I suggest leaving this change out of the PR since all it's likely to do is generate merge conflicts.
There was a problem hiding this comment.
This file sneaked in the commit, I'll change it back to previous value
|
Hi @dgirardi |
* master: Colossus Bid Adapter: gpp support (prebid#10096) Increment version to 8.1.0-pre Prebid 8.0.0 release Prebid 8: initial release (prebid#10071) Increment version to 7.54.1-pre Prebid 7.54.0 release Update topicsFpdModule.js (prebid#9990) Added GPP support (prebid#10094) Teads Bid Adapter:Remove auctionId from since it is not used anymore (prebid#10098) HypeLab Bid Adapter: Initial Release (prebid#10003) Oxxion Rtd Module: listen onBidResponseEvent instead of onAuctionEndEvent (prebid#10083) PubMatic Analytics Adapter : Added extra fields in tracker for analytics (prebid#10090) AdHash Bidder Adapter: update for brand safety (prebid#10087) videojsVideoProvider: use contrib-ads event names (prebid#10081) Increment version to 7.54.0-pre Prebid 7.53.0 release Add bidgency alias (prebid#10077) Weborama RTD Module : start Bidder specific handling removal (prebid#10005) ZetaGlobalSspBidAdapter: change logic around mediaType (prebid#10074) add tmax to sovrnBidAdapter (prebid#10059) Mediasquare Bid Adapter: Avoid to run bidwon event on video impressions (prebid#10068) FreePass User ID Module : initial release (prebid#9814) Conceptx Bid Adapter : initial release (prebid#9835) beOp BidAdapter: FirstPartyData management and ingest Permutive segments (prebid#9947) StroeerCore Bid Adapter: add price floor support (prebid#9962) YieldlabBidAdapter updated native asset mapping (prebid#9989) Mediasquare Bid Adapter: handle context for video bids (prebid#10055) Add new alias - Apester (prebid#10057) Criteo Bid Adapter: Pass outstream video renderer method (prebid#10054) Add: Viously GVL ID (prebid#10061) 1plus x RTD Adapter: remove bidder specific handling enforcement (DC 3634) (prebid#10001) Sirdata RTD Module : bidder specific handling removal (prebid#9970) feat: pass video.plcmt [PB-1736] (prebid#10058) Update adkernelBidAdapter.js (prebid#10056) Eskimi Bid Adapter: Added support for video (prebid#9985) Richaudience Bid Adapter : add compability with GPID (prebid#9928) Add GVL ID for pairId userId submodule. (prebid#10053) Update nexx360BidAdapter.js (prebid#10042) Logicad Bid Adapter: Add topics and uach support (prebid#10045) change session_id fallback to bidderRequestId (prebid#10047) ZetaGlobalSsp Bid Adapter : process array of sizes (prebid#10039) AdagioBidAdapter: change outstream renderer (prebid#10035) update greenbids analytics endpoint (prebid#10037) ID5 User Id module - get whole ext object from server response (prebid#10036) Criteo Bid Adapter : Bump fastbid version to 136 (prebid#9973) UID2 & EUID Modules: Add support for EUID and prefer localStorage for both modules. (prebid#9968) Schain module: do not share schain objects across different bid requests (prebid#10021) airgridRtdProvider: use provided tag insertion method `loadExternalScript` (prebid#9901) Increment version to 7.53.0-pre Prebid 7.52.0 release Yahoo ConnectId - fixed tests. (prebid#10033) Core & Multiple modules: activity controls (prebid#9802) Yahoo ConnectId - gpp consent module usage. (prebid#10022) Yahoo bid adapter: User sync pixels, consent signals update (prebid#10028) Core: fix `markWinningBidAsUsed` to set bid as winning and not just rendered (prebid#10014) Adriver Id System: add cfa param to url (prebid#10024) Undertone Bid Adapter : added GPP and video placements (prebid#10016) Oxxion Analytics Adapter : initial adapter release (prebid#9682) Connect id : storage duration updates and no longer require puid or he to be set (prebid#9965) Update ad generation adapter 1.6.0: update userSync (prebid#9984) fix module type (prebid#10019) Stv Bid Adapter: add schain support (prebid#10010) GrowthCode RTD : initial release (prebid#9852) ShareThrough Bid Adapter : fix playerSize (prebid#10011) chore: update default video placement value [PB-1560] (prebid#9948) Smartadserver Bid Adapter: support GPID (prebid#10004) Criteo Adapter: Add support of bcat/badv/bapp (prebid#10013) Zeta Global SSP Bid Adapter: Added support for video.plcmt (prebid#10009) Pair Id System: less noisy errors (prebid#9998) Increment version to 7.52.0-pre Prebid 7.51.0 release Appnexus Bid Adapter: added uol as an alias (prebid#10002) Adquery Bid Adapter : added bid request: version and bidPageUrl (prebid#9946) MinuteMedia Bid Adapter: support sua and plcmt params (prebid#9997) Adkernel Bid Adapter: add didnadisplay alias (prebid#10000) Adrino Bid Adapter: pass adUnitCode to adserver (prebid#9993)
…3634) (prebid#10001) * 1plus x RTD Adapter: remove bidder specific handling enforcement (DC 3634) * linting * Requested changes addressed * Fix test setTargetingDataToConfig * Requested changes addressed * fix lint error * default bidder config to {} before updating it
Type of change
Bugfix
Feature
New bidder adapter
Code style update (formatting, local variables)
Refactoring (no functional changes, no api changes)
Build related changes
CI related changes
Does this change affect user-facing APIs or examples documented on http://prebid.org?
Other : Fulfilling new requirement for Prebid v8
Description of change
Updates ortb2 user data setting method to conform the spec
A draft of this work has been done here #9952
Other information