Migrating to Authorized Buyers' Real-time Bidding API

Enable the API

Similar to the Ad Exchange Buyer and Ad Exchange Buyer II APIs, you will need to enable the Real-time Bidding API before you can start working with it. You can do so with the following steps:

  1. Go to the Google API Console Enabled APIs page, and select the project you use for accessing the Ad Exchange Buyer or Ad Exchange Buyer II APIs.
  2. Click the + ENABLE APIS AND SERVICES link.
  3. In the search box, type "Real-time Bidding API", and press Enter.
  4. In the search results, select Real-time Bidding API.
  5. Click the ENABLE button to enable the Real-time Bidding API.
  6. You should now be able to access the Real-time Bidding API with credentials created under this project.

Update your OAuth 2.0 credentials

Existing OAuth 2.0 workflows configured with the API scope for the existing Ad Exchange Buyer APIs will need to be adjusted for use with the Real-time Bidding API, which has the following new scope:

https://www.googleapis.com/auth/realtime-bidding

It is recommended that the Service Account OAuth 2.0 flow is used to access the API. All supported OAuth 2.0 flows will need to specify the new API scope when requesting a token from Google in order for the tokens to have permission to access the Real-time Bidding API.

Mapping Ad Exchange Buyer API resources to the Real-time Bidding API

Bidder and Buyer-level resources

The Real-time Bidding API has been restructured to better align with Google API design practices and more clearly define the API calls available to bidders and the buyers that they bid on behalf of. All resources will exist either under the bidders or buyers root-level resources.

In general, API calls made under bidders will involve configuration of real-time bidding settings, or viewing results for a particular resource across all buyer accounts associated with the bidder—as a concrete example, the bidders.creatives.list method could return creatives for all buyer accounts associated with the bidder. In contrast, API calls made under buyers will be on behalf of an individual buyer—the buyers.creatives.list method would return all creatives for an individual buyer.

Resource names

Similar to the Ad Exchange Buyer II API, this API will use resource names as unique identifiers. The resource ID specified for a bidder or buyer will be their Authorized Buyers account ID.

Creatives

Resource methods

Ad Exchange Buyer API method name Real-time Bidding API equivalent
addDeal N/A: A creative will be associated with a deal when it is specified in a bid response for a deal.
get buyers.creatives.get
insert buyers.creatives.create
list bidders.creatives.list or buyers.creatives.list
listDeals N/A: Deals are now listed in the Creative.dealIds[] field.
removeDeal N/A

Resource fields

Ad Exchange Buyer API field name Real-time Bidding API equivalent
accountId Creative.accountId
buyerCreativeId Creative.creativeId
creativeStatusIdentityType N/A: This field has been sunset.
agencyId Creative.agencyId
version Creative.version
apiUploadTimestamp Creative.apiUpdateTime
HTMLSnippet Creative.html.snippet
nativeAd Creative.native
videoURL Creative.video.videoUrl
videoVastXML Creative.video.videoVastXml
clickThroughUrl Creative.declaredClickThroughUrls
adChoicesDestinationUrl Creative.adChoicesDestinationUrl
impressionTrackingUrl Creative.impressionTrackingUrls
vendorType Creative.declaredVendorIds and Creative.creativeServingDecision.detectedVendorIds
attribute Creative.declaredAttributes
width Creative.html.width
height Creative.html.height
advertiserName Creative.advertiserName
dealsStatus Creative.creativeServingDecision.dealsPolicyCompliance
openAuctionStatus Creative.creativeServingDecision.networkPolicyCompliance
servingRestrictions Creative.creativeServingDecision
advertiserId Creative.creativeServingDecision.detectedAdvertisers.advertiserId
sensitiveCategories Creative.creativeServingDecision.detectedSensitiveCategories
restrictedCategories Creative.restrictedCategories
productCategories Creative.creativeServingDecision.detectedProductCategories
languages Creative.creativeServingDecision.detectedLanguages
detectedDomains Creative.creativeServingDecision.detectedDomains
corrections N/A: Detected fields now describe corrections.
filteringReasons N/A: This should be obtained from either the RTB Breakout UI, or RTB Troubleshooting API.