Stay organized with collections
Save and categorize content based on your preferences.
A bidder can purchase inventory for multiple buyers in a single bid
response. For example, a demand-side platform (DSP) might use its bidding
application to purchase inventory for several marketers or agencies who are
buyers. This guide explains how to code your bidder to process a single request
sent on behalf of multiple buyers.
Background
In some scenarios, an ad network or agency trading desk may choose to work
with one or more DSPs. There are two options available for buyers who work
through a DSP:
The DSP purchases inventory for marketers or agencies that are
not buyers. In this case, the DSP receives one bid request
and responds with one bid. Google bills the DSP directly.
The DSP purchases inventory for marketers or agencies that are
buyers. The DSP receives one bid request including multiple billing
IDs associated with eligible buyers, and can place distinct bids for each
buyer they intend to bid on behalf of. In this model, Google bills the
buyer, not the DSP. The rest of this guide focuses on this scenario.
Setup and pretargeting
Google will send a bid request containing one or more billing IDs associated
with buyers and pretargeting configurations that targeted the impression.
These can be found with the BidRequest.imp.ext.billing_id
field.
When responding to a BidRequest that contains billing IDs from
multiple buyers, BidResponse.seatbid.bid.ext.billing_id is
required so that Google knows which account to associate with the bid. Any
response that does not set the field is filtered. The field remains optional
for any BidRequest that only includes a single billing ID.
Pretargeting example
A bidder bids on behalf of two buyers, one having a billing ID of 123, and
the other with billing ID 124. The bidder configures one pretargeting
configuration with billing ID 213 to target the English language, and another
with billing ID 231 to target personal computers. The following describes the
billing IDs that appear in bid requests for different kinds of impressions.
Impression description
Billing IDs in bid request
Japanese language content on a personal computer.
123, 124, 231
English language content on a mobile phone.
123, 124, 213
English language content on a personal computer.
123, 124, 213, 231
Example BidRequests
Below are examples of a BidRequest. You'll note that there are multiple billing IDs
in these requests because the requests are applicable to multiple accounts.
id:"n9YFp0D9qE02Q5A49bo68a"imp{id:"1"banner{w:320h:50pos:ABOVE_THE_FOLDapi:MRAID_1api:MRAID_2format{w:320h:50}}displaymanager:"GoogleMobileAds-iOS"displaymanagerver:"11.2.0"tagid:"2913643481"bidfloor:0.04bidfloorcur:"USD"secure:trueexp:3600clickbrowser:truemetric{type:"click_through_rate"value:0.0003642654628492892vendor:"EXCHANGE"}metric{type:"viewability"value:0.98vendor:"EXCHANGE"}[com.google.doubleclick.imp]{billing_id:41048190734billing_id:87998475627publisher_settings_list_id:5889715199959683550publisher_settings_list_id:3379823455061055318allowed_vendor_type:566allowed_vendor_type:113ampad:AMP_AD_NOT_ALLOWEDskadn{sourceapp:"com.google.testapp"skadnetids:"6ZVs3vs4"versions:"2.0"versions:"2.1"fidelities:VIEW_THROUGH_ADSfidelities:STOREKIT_RENDERED_ADS}creative_enforcement_settings{policy_enforcement:POLICY_ENFORCEMENT_NETWORK_AND_PLATFORM_POLICYpublisher_blocks_enforcement:PUBLISHER_BLOCKS_ENFORCEMENT_APPLIES}auction_environment:SERVER_SIDE_AUCTIONae:SERVER_SIDE_AUCTION}}app{name:"Test App"bundle:"com.google.testapp"publisher{id:"pub-6227762759521589"[com.google.doubleclick.publisher]{country:"US"}}content{url:"https://www.google.com"livestream:falselanguage:"en"}storeurl:"https://www.google.com"[com.google.doubleclick.app]{inventorypartnerdomain:"OMITTED"}}device{ua:"Mozilla/5.0 (iPhone; CPU iPhone OS 17_4_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148"ip:"192.168.1.0"geo{lat:0.0lon:0.0country:"USA"region:"TX"metro:"623"city:"Lewisville"type:IPutcoffset:-300accuracy:6225}make:"Apple"model:"iPhone13,2"os:"iOS"osv:"17.4.1"connectiontype:WIFIdevicetype:HIGHEND_PHONElmt:truehwv:"iPhone13,2"w:390h:844pxratio:3.0sua{browsers{brand:"Mozilla"version:"5"version:"0"}browsers{brand:"AppleWebKit"version:"605"version:"1"}platform{brand:"iPhone"version:"17"version:"4"}mobile:truebitness:"64"model:"iPhone"source:USER_AGENT_STRING}[com.google.doubleclick.device]{atts:2}}at:FIRST_PRICEtmax:1000cur:"USD"bcat:"IAB18-5"bcat:"IAB23-4"bapp:"359917414"bapp:"1446254576"source{schain{complete:truenodes{asi:"testssp.com"sid:"pub-1111111111111111"hp:true}ver:"1.0"}[com.google.doubleclick.source]{omidpn:"Google"omidpv:"afma-sdk-i-v11.2.0"schain{complete:1nodes{asi:"testssp.com"sid:"pub-1111111111111111"hp:1}ver:"1.0"}}}[com.google.doubleclick.bid_request]{google_query_id:"ANy-z17251-40u3eXfXPL5j3MDPa7n6Ree92uf7354o71FP67Rk5i3G30Ez7p39Ze1722D8H"fcap_scope:FREQUENCY_CAPPING_SCOPE_APPprivacy_treatments{allow_user_data_collection:true}}
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-01 UTC."],[[["Bidders can purchase ad inventory for multiple buyers using a single bid response, streamlining the buying process for demand-side platforms (DSPs)."],["When bidding for multiple buyers, the bid response must specify the billing ID (`BidResponse.seatbid.bid.ext.billing_id`) to ensure proper billing allocation."],["Bid requests will include billing IDs for all eligible buyers and any applicable pretargeting configurations, allowing bidders to tailor their bids accordingly."],["Google provides detailed examples of bid requests in OpenRTB Protobuf, OpenRTB JSON, and Google's own format, demonstrating how multiple billing IDs are incorporated."]]],["A demand-side platform (DSP) can bid on behalf of multiple buyers in a single bid request. These requests include multiple billing IDs, and pretargeting configurations. When responding, the `BidResponse` must specify the `billing_id` to indicate which buyer the bid is for, or it will be filtered. Pretargeting determines which bid requests a bidder receives. Bid requests contain multiple billing IDs, allowing the bidder to bid for various accounts.\n"]]