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

Support imp.ext.prebid.bidder.<bidder> as a new place for bidder parameters #976

Merged
merged 13 commits into from
Jan 29, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions docs/bidders/appnexus.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,13 @@ that would match with the test creative.
}]
},
"ext": {
"appnexus": {
"placementId": 13144370
}
}
"prebid": {
"bidder":{
"appnexus": {
"placementId": 13144370
}
}
}
}
}]
```
22 changes: 15 additions & 7 deletions docs/bidders/openx.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,13 @@ If you have any questions regarding setting up, please reach out to your account
]
},
"ext": {
"openx": {
"delDomain": "mobile-d.openx.net",
"unit": "541028953"
"prebid": {
"bidder":{
"openx": {
"delDomain": "mobile-d.openx.net",
"unit": "541028953"
}
}
}
}
}
Expand All @@ -56,10 +60,14 @@ If you have any questions regarding setting up, please reach out to your account
]
},
"ext": {
"openx": {
"unit": "540949380",
"delDomain": "sademo-d.openx.net"
},
"prebid": {
"bidder":{
"openx": {
"unit": "540949380",
"delDomain": "sademo-d.openx.net"
}
}
}
}
}
```
10 changes: 7 additions & 3 deletions docs/bidders/pubmatic.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,13 @@ and sizes that would match with the test creative.
]
},
"ext":{
"pubmatic":{
"publisherId":“156276”,
"adSlot":"pubmatic_test"
"prebid": {
"bidder"{
"pubmatic":{
"publisherId":“156276”,
"adSlot":"pubmatic_test"
}
}
}
}
}
Expand Down
16 changes: 10 additions & 6 deletions docs/bidders/pubnative.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ Please see [documentation](https://developers.pubnative.net/docs/prebid-adding-p

## Configuration

- bidder should be always set to "pubnative" (`imp.ext.pubnative`)
- zone_id (int) should be always set to 1, unless special use case agreed with our account manager. (`imp.ext.pubnative.zone_id`)
- app_auth_token (string) is unique per publisher app. Please contact our account manager to obtain yours. (`imp.ext.pubnative.app_auth_token`)
- bidder should be always set to "pubnative" (`imp.ext.prebid.bidder.pubnative`)
- zone_id (int) should be always set to 1, unless special use case agreed with our account manager. (`imp.ext.prebid.bidder.pubnative.zone_id`)
- app_auth_token (string) is unique per publisher app. Please contact our account manager to obtain yours. (`imp.ext.prebid.bidder.pubnative.app_auth_token`)

An example is illustrated in a section below.

Expand Down Expand Up @@ -44,9 +44,13 @@ The following json can be used to do a request to prebid server for verifying it
]
},
"ext": {
"pubnative": {
"zone_id": 1,
"app_auth_token": "b620e282f3c74787beedda34336a4821"
"prebid": {
"bidder": {
"pubnative": {
"zone_id": 1,
"app_auth_token": "b620e282f3c74787beedda34336a4821"
}
}
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions docs/developers/add-new-bidder.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Throughout the rest of this document, substitute `{bidder}` with the name you've
Bidders may define their own APIs for Publishers pass custom values. It is _strongly encouraged_ that these not
duplicate values already present in the [OpenRTB 2.5 spec](https://www.iab.com/wp-content/uploads/2016/03/OpenRTB-API-Specification-Version-2-5-FINAL.pdf).

Publishers will send values for these parameters in `request.imp[i].ext.{bidder}` of
Publishers will send values for these parameters in `request.imp[i].ext.prebid.bidder.{bidder}` of
[the Auction endpoint](../endpoints/openrtb2/auction.md). Prebid Server will preprocess these so that
your bidder will access them at `request.imp[i].ext.bidder`--regardless of what your `{bidder}` name is.

Expand Down Expand Up @@ -134,7 +134,7 @@ We expect to see at least 90% code coverage on each bidder.

Then `POST` an OpenRTB Request to `http://localhost:8080/openrtb2/auction`.

If at least one `request.imp[i].ext.{bidder}` is defined in your Request, then your bidder should be called.
If at least one `request.imp[i].ext.prebid.bidder.{bidder}` is defined in your Request, then your bidder should be called.

To test user syncs, [save a UID](../endpoints/setuid.md) using the FamilyName of your Bidder.
The next time you use `/openrtb2/auction`, the OpenRTB request sent to your Bidder should have
Expand Down
16 changes: 12 additions & 4 deletions docs/developers/stored-requests.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,12 @@ Add the file `stored_imps/{id}.json` and populate it with some [Imp](https://www
]
},
"ext": {
"appnexus": {
"placement_id": 10433394
"prebid": {
"bidder": {
"appnexus": {
"placement_id": 10433394
}
}
}
}
}
Expand Down Expand Up @@ -83,8 +87,12 @@ You can also store _part_ of the Imp on the server. For example:
]
},
"ext": {
"appnexus": {
"placement_id": 10433394
"prebid": {
"bidder": {
"appnexus": {
"placement_id": 10433394
}
}
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion docs/endpoints/info/bidders.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## `GET /info/bidders`

This endpoint returns a list of active Bidders supported by Prebid Server.
These are the core values allowed to be used as `request.imp[i].ext.{bidder}`
These are the core values allowed to be used as `request.imp[i].ext.prebid.bidder.{bidder}`
keys in [Auction](../openrtb2/auction.md) requests.

For detailed info about a specific Bidder, use [`/info/bidders/{bidderName}`](bidders/bidderName.md)
Expand Down
2 changes: 1 addition & 1 deletion docs/endpoints/info/bidders/bidderName.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ The fields hold the following information:

If `capabilities.app` or `capabilities.site` do not exist, then this Bidder does not support that platform.
OpenRTB Requests which define a `request.app` or `request.site` property will fail if a
`request.imp[i].ext.{bidderName}` exists for a Bidder which doesn't support them.
`request.imp[i].ext.prebid.bidder.{bidderName}` exists for a Bidder which doesn't support them.


## `GET /info/bidders/all`
Expand Down
16 changes: 10 additions & 6 deletions docs/endpoints/openrtb2/amp.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,16 @@ An example Stored Request is given below:
"id": "some-impression-id",
"banner": {}, // The sizes are defined is set by your AMP tag query params
"ext": {
"appnexus": {
// Insert parameters here
},
"rubicon": {
// Insert parameters here
}
"prebid": {
"bidder": {
"appnexus": {
// Insert parameters here
},
"rubicon": {
// Insert parameters here
}
}
}
}
}
]
Expand Down
30 changes: 19 additions & 11 deletions docs/endpoints/openrtb2/auction.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,12 @@ The following is a "hello world" request which fetches the [Prebid sample ad](ht
]
},
"ext": {
"appnexus": {
"placement_id": 10433394
"prebid": {
"bidder": {
"appnexus": {
"placement_id": 10433394
}
}
}
}
}
Expand Down Expand Up @@ -107,11 +111,11 @@ These fall under the `ext` property of JSON objects.

If `ext` is defined on an object, Prebid Server uses the following conventions:

1. `ext` in "Request objects" uses `ext.prebid` and/or `ext.{anyBidderCode}`.
1. `ext` in "Request objects" uses `ext.prebid` and/or `ext.prebid.bidder.{anyBidderCode}`.
2. `ext` on "Response objects" uses `ext.prebid` and/or `ext.bidder`.
The only exception here is the top-level `BidResponse`, because it's bidder-independent.

`ext.{anyBidderCode}` and `ext.bidder` extensions are defined by bidders.
`ext.prebid.bidder.{anyBidderCode}` and `ext.bidder` extensions are defined by bidders.
`ext.prebid` extensions are defined by Prebid Server.

Exceptions are made for extensions with "standard" recommendations:
Expand Down Expand Up @@ -289,11 +293,15 @@ This can be used to request bids from the same Bidder with different params. For
"mimes": ["video/mp4"]
},
"ext": {
"appnexus: {
"placement_id": 123
},
"districtm": {
"placement_id": 456
"prebid": {
"bidder": {
"appnexus: {
"placement_id": 123
},
"districtm": {
"placement_id": 456
}
}
}
}
}
Expand Down Expand Up @@ -324,7 +332,7 @@ For example, if the Request defines an alias like this:
}
```

then any `imp.ext.appnexus` params will actually go to the **rubicon** adapter.
then any `imp.ext.prebid.bidder.appnexus` params will actually go to the **rubicon** adapter.
It will become impossible to fetch bids from Appnexus within that Request.

#### Bidder Response Times
Expand Down Expand Up @@ -757,7 +765,7 @@ This section describes the ways in which Prebid Server **breaks** the OpenRTB sp
Prebid Server returns a 400 on requests which define `wseat` or `bseat`.
We may add support for these in the future, if there's compelling need.

Instead, an impression is only offered to a bidder if `bidrequest.imp[i].ext.{bidderName}` exists.
Instead, an impression is only offered to a bidder if `bidrequest.imp[i].ext.prebid.bidder.{bidderName}` exists.

This supports publishers who want to sell different impressions to different bidders.

Expand Down
Loading