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

Feature Request: allow publishers to configure bid filtering on .meta fields #6453

Closed
patmmccann opened this issue Mar 22, 2021 · 8 comments
Closed
Assignees

Comments

@patmmccann
Copy link
Collaborator

Type of issue

Feature request

Description

The discussion on #3115 is currently around the ability for bid filtering on meta fields. Publishers may want to filter particular values of meta fields (eg banned advertisers or incomplete dchains) or when they are missing (no dchain or advertiserDomain at all). Publishers may want this ability via modules or via setConfig. This issue is to give that discussion a home and allow for the closing of #3115

@Slind14
Copy link
Contributor

Slind14 commented Mar 22, 2021

Isn't this pretty simple to do with just a few lines of code using the getBidResponses and markWinningBidAsUsed to remove it.

To avoid hurting performance one needs to do these blocks server side no? Otherwise, bids get rejected and the second-highest bid at the exchange never makes it to prebid.

So to properly use this, one needs to track and monitor rejected bids as well. At this point, the few lines of code are nothing in comparison to the coding required for tracking and monitoring.

Am I missing something?

@patmmccann
Copy link
Collaborator Author

I think publisher logic here might be arbitrarily complex and there's an opportunity for a module, but I think you are right for simple cases.

@Slind14
Copy link
Contributor

Slind14 commented Mar 22, 2021

If it is arbitrarily complex won't a module be limiting publishers and in the end custom code will prevail?

I'm not trying to find the negatives here, just wondering if there is an actual use case where it makes sense to have a module.

@patmmccann
Copy link
Collaborator Author

I am imagining the geoedge and future related module(s) might include this feature

@patmmccann
Copy link
Collaborator Author

Would you mind hashing out your example a bit more if you think we can close this with doc?

@Slind14
Copy link
Contributor

Slind14 commented Mar 22, 2021

pbjs.requestBids({
    bidsBackHandler: (bids) => {
        // loop through ad units
        Object.entries(bids).forEach(([adUnit, bids]) => {
            // invalidate blocked ads
            bids.forEach(bid => {
                if (isBlockScopedAd(bid.meta)) {
                    pbjs.markWinningBidAsUsed({ adId: bid.adId });
                }
            })
        });
        // continue normal logic
    },
});

Alternatively, one could loop do a while loop with getHighestCpmBids() ...

@allanjun
Copy link
Collaborator

Hi,

I'd say it would be important to provide publishers (and eventually bidders) visibility on the filtration rate. IMO this could be done on two ways:

  • Adding post-bid filtering events to Prebid Analytics, so that publishers can see filtrarion rate per buyer and report top offenders
  • Adding a Loss URL mechanism to buyers so they can receive RT feedback

If there is enough Publisher demand for .meta validation features (maybe after prebid 5.0), would make sense to package this into a dedicated module to easy this job (examples: to enforce adomain, bid.cat, bid > bidfloor, meta ids)

Allan

@gglas
Copy link

gglas commented Apr 14, 2021

Going to push analytics events + further module enhancements, will document @Slind14's code snippet in examples for publishers to utilize if they so desire.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants