Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pre-auction filters and pbAdslot support #4539

Merged
merged 68 commits into from
Jan 15, 2020

Conversation

idettman
Copy link
Contributor

@idettman idettman commented Dec 5, 2019

Type of change

  • Feature

Description of change

Pre-auction filters and pbadslot support

  1. The pbAdSlot attribute is added to the Prebid Ad Unit in the First Party Data context
var AdUnit={
   code: "40989gjr9e98ajrosiero",
   fpd: {
     context: {
        pbAdSlot: "/1111111/homepage/med-rect-2"
     }
   },
};
  1. define pre-auction filter function
var setPbAdSlot = function setPbAdSlot(adunits) {
    console.log('setPbAdSlot called');
    // ... logic to find and set fpd.context.pbAdSlot for each AdUnit ...
};
pbjs.onEvent('onBeforeRequestBids', setPbAdSlot);
  1. The Prebid Server Bid Adapter must pass the Prebid AdSlot through the OpenRTB request in imp[].ext.context.data.adslot
{
  imp: [{
    ext: {
      context: {
        data: {
          adslot: "/1111111/homepage/med-rect-2"
        }
      }
    }
  }]
}

Other information

#4149

nakamoto and others added 30 commits February 16, 2019 21:30
# Conflicts:
#	modules/advangelistsBidAdapter.js
#	test/spec/modules/advangelistsBidAdapter_spec.js
Copy link
Collaborator

@bretg bretg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @idettman - we added in an 'fpd' level at some point that didn't get reflected in pbAdSlot.

modules/prebidServerBidAdapter/index.js Outdated Show resolved Hide resolved
modules/rubiconBidAdapter.js Outdated Show resolved Hide resolved
modules/rubiconBidAdapter.js Outdated Show resolved Hide resolved
src/adapterManager.js Outdated Show resolved Hide resolved
test/spec/modules/prebidServerBidAdapter_spec.js Outdated Show resolved Hide resolved
test/spec/modules/prebidServerBidAdapter_spec.js Outdated Show resolved Hide resolved
test/spec/modules/prebidServerBidAdapter_spec.js Outdated Show resolved Hide resolved
test/spec/modules/prebidServerBidAdapter_spec.js Outdated Show resolved Hide resolved
test/spec/modules/rubiconBidAdapter_spec.js Outdated Show resolved Hide resolved
@bretg
Copy link
Collaborator

bretg commented Jan 4, 2020

Docs PR prebid/prebid.github.io#1728

@bretg bretg removed the needs docs label Jan 4, 2020
@idettman idettman requested a review from bretg January 7, 2020 18:19
@idettman idettman assigned harpere and unassigned idettman and msm0504 Jan 7, 2020
Copy link
Collaborator

@harpere harpere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One question

modules/rubiconBidAdapter.js Show resolved Hide resolved
@idettman idettman requested a review from harpere January 13, 2020 19:09
Isaac Dettman added 4 commits January 13, 2020 16:04
# Conflicts:
#	modules/prebidServerBidAdapter/index.js
#	modules/rubiconBidAdapter.js
#	test/spec/modules/prebidServerBidAdapter_spec.js
Copy link
Collaborator

@harpere harpere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the tests for this PR are failing

@harpere harpere merged commit fa13966 into prebid:master Jan 15, 2020
idettman pushed a commit to rubicon-project/Prebid.js that referenced this pull request Jan 17, 2020
* Add microadBidAdapter

* Remove unnecessary encodeURIComponent from microadBidAdapter

* Submit Advangelists Prebid Adapter

* Submit Advangelists Prebid Adapter 1.1

* Correct procudtion endpoint for prebid

* analytics update with wrapper name

* reverted error merge

* update changed default value of netRevenue to true

* add beforeRequestBids event

* add pbAdSlot support to pbs adapter

* update jsdoc comment for on before request bids event

* add pbAdSlot support to rubicon adapter

* added more tests

* update code comment

* add api test, update event to emit from adapterManager

* add multi-bid api test

* added pbAdSlot to rubicon bid adapter video bid request

* added ext to server video path in rp adapter pbAdSlot

* fix for pb video ortb path

* fix for consistency with pb server

* update obj path to fpd.context.pbAdSlot

* add leading slash removal to all outputs of pbAslot

* revert to previous branch reviewed

* revert to previous branch reviewed

* fix merge errors

(cherry picked from commit fa13966)
harpere pushed a commit that referenced this pull request Jan 17, 2020
* Pre-auction filters and pbAdslot support (#4539)

* Add microadBidAdapter

* Remove unnecessary encodeURIComponent from microadBidAdapter

* Submit Advangelists Prebid Adapter

* Submit Advangelists Prebid Adapter 1.1

* Correct procudtion endpoint for prebid

* analytics update with wrapper name

* reverted error merge

* update changed default value of netRevenue to true

* add beforeRequestBids event

* add pbAdSlot support to pbs adapter

* update jsdoc comment for on before request bids event

* add pbAdSlot support to rubicon adapter

* added more tests

* update code comment

* add api test, update event to emit from adapterManager

* add multi-bid api test

* added pbAdSlot to rubicon bid adapter video bid request

* added ext to server video path in rp adapter pbAdSlot

* fix for pb video ortb path

* fix for consistency with pb server

* update obj path to fpd.context.pbAdSlot

* add leading slash removal to all outputs of pbAslot

* revert to previous branch reviewed

* revert to previous branch reviewed

* fix merge errors

(cherry picked from commit fa13966)

* updated tests to use server.js for xhr
@robertrmartinez robertrmartinez deleted the add-pbadslot branch July 5, 2023 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature needs 2nd review Core module updates require two approvals from the core team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants