Skip to content

Commit

Permalink
add id5id to prebid server bid adapter (prebid#4468)
Browse files Browse the repository at this point in the history
  • Loading branch information
smenzer authored and sa1omon committed Nov 28, 2019
1 parent 4904963 commit 8f453cf
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion modules/prebidServerBidAdapter/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -698,7 +698,7 @@ const OPEN_RTB_PROTOCOL = {
}

const bidUserId = utils.deepAccess(bidRequests, '0.bids.0.userId');
if (bidUserId && typeof bidUserId === 'object' && (bidUserId.tdid || bidUserId.pubcid || bidUserId.parrableid || bidUserId.lipb)) {
if (bidUserId && typeof bidUserId === 'object' && (bidUserId.tdid || bidUserId.pubcid || bidUserId.parrableid || bidUserId.lipb || bidUserId.id5id)) {
utils.deepSetValue(request, 'user.ext.eids', []);

if (bidUserId.tdid) {
Expand Down Expand Up @@ -746,6 +746,15 @@ const OPEN_RTB_PROTOCOL = {
}
request.user.ext.eids.push(liveIntent);
}

if (bidUserId.id5id) {
request.user.ext.eids.push({
source: 'id5-sync.com',
uids: [{
id: bidUserId.id5id,
}]
});
}
}

if (bidRequests && bidRequests[0].gdprConsent) {
Expand Down

0 comments on commit 8f453cf

Please sign in to comment.