Prebid Server
Prebid Server (PBS) is the open-source server-side header bidding engine maintained by Prebid.org, with Go and Java implementations. A host company runs it: PBS takes one OpenRTB request, fans it out to bidder adapters, and returns a merged response. This profile follows the documented /openrtb2/auction endpoint and the Go implementation, PBS-Go.
Direction and version
A client such as Prebid.js, a mobile SDK, or another server posts a request to the PBS /openrtb2/auction endpoint, and PBS returns one response that combines its bidders' bids.
OpenRTB 2.x JSON that accepts 2.5 and 2.6 fields; PBS moves 2.6 fields back to their 2.5 ext locations for bidders that only support 2.5. Prebid's own flags under ext.prebid are JSON true or false.
The RTBlint profile prebid-server checks requests and responses against the published contract.
Rules beyond the OpenRTB spec
- PBS refuses
wseatandbseat. A bidder only sees an impression that names it inimp.ext.prebid.bidder(or the deprecatedimp.ext.{bidder}). - A stored request object in
ext.prebid.storedrequestorimp.ext.prebid.storedrequestmust carry a non-emptyid. PBS merges the stored content into the request before the auction, so stored fields may be absent from the raw payload. - PBS-Go uses only the first currency in
curand drops the rest. A missingcuris treated as USD. - Multibid
maxbidsis clamped to 1 through 9. PBS-Go ignores multibid entries withoutmaxbidsor without a bidder selector. ext.prebid.cachemust ask forbids,vastxml, or both.- An alias in
ext.prebid.aliasescannot map a bidder code to itself. Each key inext.prebid.aliasgvlidsmust name a declared alias and carry a positive GVL ID. - Price granularity is a legacy name (low, med, medium, high, auto, dense) or a custom object with strictly increasing ranges and positive increments. PBS-Go accepts precision from 0 to 15.
bid.ext.prebid.typenames the bid's media type. It must agree withbid.mtypeand with a media object the impression offered.- PBS fills a missing Native request asset
idfrom the asset's position in the array, so request assets may omit it.
Documented extensions
| Path | Meaning |
|---|---|
imp.ext.prebid.bidder | Bidder parameters keyed by bidder code; it also selects which bidders get the impression. |
ext.prebid.storedrequest | ID of a stored request that PBS merges into this one. |
imp.ext.prebid.storedauctionresponse | A stored response that replaces the live auction for the impression. |
ext.prebid.targeting | Ad server targeting options such as price granularity and winner keys. |
ext.prebid.cache | Server-side caching of bids or VAST XML. |
ext.prebid.aliases | Bidder aliases mapped to their adapter codes. |
ext.prebid.multibid | How many bids a bidder may return per impression. |
ext.prebid.currency.rates | Custom currency conversion rates for the request. |
ext.prebid.channel | Integration channel, such as pbjs, with a required name. |
user.ext.prebid.buyeruids | Bidder user IDs keyed by bidder code. |
bid.ext.prebid.type | Media type of the bid: banner, video, native, or audio. |
bid.ext.prebid.targeting | Ad server targeting keys PBS generated for the bid. |
What the validator checks for this profile
openrtb.profile.prebid.alias_noopPBS aliases must not map a bidder code to itself.openrtb.profile.prebid.alias_not_declaredA PBS alias GVL ID must reference a declared request alias.openrtb.profile.prebid.cache_type_requiredPBS cache configuration requires bids or vastxml.openrtb.profile.prebid.currency_truncatedPBS-Go uses only the first request currency and drops subsequent entries.openrtb.profile.prebid.media_not_offeredThe PBS bid marker ext.prebid.type=the field references an impression without that media object. Stored-request media cannot be resolved locally.openrtb.profile.prebid.media_type_mismatchThe PBS ext.prebid.type marker contradicts the bid's mtype.openrtb.profile.prebid.multibid_normalizedPBS-Go clamps maxbids to the supported range 1 through 9.
Validate against this contract
Open the tester with the Prebid Server profile, or run:
rtblint validate --profile prebid-server request.json