This guide is for publishers looking to add ServerBid to their Prebid.js wrapper.

How ServerBid Works with Prebid.js

  1. Prebid.js makes a request to ServerBid, who then makes a request to an exchange. This is recorded as a Request.

  2. If the exchange responds with a bid, that bid competes in a ServerBid auction against bids from other exchanges and is tracked as a Bid.

  3. If the bid wins the ServerBid auction, ServerBid returns the ad to Prebid.js.

  4. If the ad wins, Prebid.js sends it to your ad server.

  5. If your ad server renders the ad, it’s recorded as an Impression.

Integration Process

  1. Download the ServerBid Prebid adapter from the Prebid download site. Select the adapter version that corresponds to your version of Prebid.
  2. Provide the parameters for the placements and demand partners you wish to access through ServerBid in our UI. The UI will provide two key inputs: your networkId, which is the same for every site on which you wish to implement ServerBid, and a siteId for each site you have submitted through the UI.
  3. Register a new bidder for ServerBid in your Prebid.js. Use the bidder code serverbid, and for params, add the networkId, siteId and zoneIds (optional) provided by ServerBid. [See instructions below]
  4. Enable SmartSync (optional) and IframeSync (mandatory). [See instructions below]
  5. Provide support@serverbid.com with a test URL so we can check requests and responses.

Some demand partners, namely PubMatic and Index Exchange, require special settings within your account before they can recognize requests from ServerBid. Talk to your account manager before sending your placement parameters.

Register the ServerBid Prebid.js Adapter

To register your ServerBid adapter in your Prebid.js setup, refer to the Prebid.js documentation on adding bidders.

Here is a sample adUnits object that places bids to ServerBid for the placement:

var adUnits = [{
        code: 'div-gpt-ad-1460505748561-0',
        sizes: [[300, 250], [300,600]],
        bids: [{
            bidder: 'serverbid',
            params: {
               networkId: '9969',
               siteId: '12345', //this is provided by ServerBid for your site
               zoneIds: [123456] //this is provided by ServerBid if needed

Configure code and sizes as instructed by Prebid. These parameters are not used by ServerBid. The following parameters are used by ServerBid:

Varies by Site?
Always serverbid
Always 9969    
Numeric ID from ServerBid
Numeric ID from ServerBid, if needed to differentiate placements of otherwise identical IDs

 Note: ServerBid does not use tagIds

Enabling SmartSync

SmartSync syncs a user's data with all partners associated with your ServerBid account before making a bid request to those partners, thus minimizing ramp period and ensuring maximum fill rate.

If you are downloaded the ServerBid adapter prior to February 2018, use these instructions.

For adapters downloaded during or after February 2018:
Put the following code in the <head> of your site, before your Prebid code. Replace the {siteId} with the 6-digit siteId we provide for the site once we have configured it in our system.

<script type="text/javascript" src="https://s.zkcdn.net/ss/{siteId}.js">

Enabling IframeSync

IframeSync syncs a user's data with all demand partners associated with your ServerBid adapter when making a bid request to those partners. User syncing is critical to maximizing CPM and fill, so IframeSync is a must for any successful ServerBid implementation.

To enable Iframe Sync in Prebid, update your prebid.js request to set iframeEnabled: true

Example below:

userSync: {
iframeEnabled: true

Note: If syncing is not enabled and you have Prebid debugging turned on, you should see a warning indicating it needs to be turned on.

Recap / Setup Checklist

  1. Placement parameters for your demand partners have been submitted to ServerBid for setup.
  2. NetworkID for your account, and SiteID for each site, were provided by ServerBid and configured in the adapter.
  3. iFrameSync was enabled, and SmartSync (optional) has been enabled.
  4. You have provided a URL where ServerBid can test the implementation

Additional Resources

Have questions? Email us at support@serverbid.com.