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

Prebid SDK support for Stored Responses #228

Closed
bszekely1 opened this issue Aug 6, 2019 · 2 comments
Closed

Prebid SDK support for Stored Responses #228

bszekely1 opened this issue Aug 6, 2019 · 2 comments

Comments

@bszekely1
Copy link
Contributor

bszekely1 commented Aug 6, 2019

Type of issue

Intent to implement

Description

The goal of this intent to implement is to provide SDK support for stored responses as designed in Prebid Server issue 861. A stored responses will allow developers and support engineers received a static creative response setup in the Prebid Server store datastore, used for testing.

SDK Public API

This section will cover the public API in the SDK to expose setting the stored response(s). A developer can pass one ore more stored response IDs, depending on expected behavior.

Single Stored Auction Response ID

The single stored response allows for a developer to pass a single response ID, expecting the same response each time.

Prebid.shared.storedAuctionResponse="stored_response_id"

Multiple Stored Bid Response IDs

Multiple stored responses allows a developer to specify one or more bidders to respond to Prebid server with a static bid response, allowing for an auction to occur with all bid responses.

Prebid.shared.storedbidresponse(key: "BidderA", value: "1234567")

Prebid SDK <> Prebid Server

This section will cover communication between Prebid SDK and Prebid Server.

Single Stored Auction Response ID

The single stored auction response will return the same response for all responses. No auctions will occur in Prebid Server. A sample OpenRTB request to Prebid server and response is below.

Request

  "test":1,
  "tmax":500,
  "id": "test-auction-id",
  "app": { ... },
  "ext": {
      "prebid": {
             "targeting": {},
             "cache": { "bids": {} }
       }
  },
  "imp": [
    {
      "id": "a",
      "ext": { "prebid": { "storedauctionresponse": { "id": "1111111111" } } }
    }
  ]
}

Response

    "id": "78cb3c51-baa7-437b-b958-c7c6569a5041",
    "seatbid": [
        {
             // Store response for storedauctionresponse=1111111111
        }
  ]
}

Multiple Stored Bid Response IDs

Providing multiple stored auction response IDs allows for resolved bidder config IDs to compete in an auction.

Request

  "test":1,
  "tmax":500,
  "id": "test-auction-id",
  "app": { ... },
  "ext": {
      "prebid": {
             "targeting": {},
             "cache": { "bids": {} }
       }
  },
  "imp": [
    {
      "id": "a",
      "ext": {
          "prebid": {
            "storedbidresponse": [
                  { "bidder": "BidderA", "id": "333333" },
                  { "bidder": "BidderB", "id": "444444" },
             ]
           } 
      }
    }
  ]
}

Response

    "id": "78cb3c51-baa7-437b-b958-c7c6569a5041",
    "seatbid": [
        {
             "bid": [
             // contents of storedbidresponse=3333333 as parsed by bidderA adapter
             // contents of storedbidresponse=5555555 as parsed by bidderA adapter
             ]
        }
  ]
}

Platform details

Support for iOS

Other information

Reference Prebid Server Store Response implementation: prebid/prebid-server#861

@yoalex5
Copy link
Collaborator

yoalex5 commented Aug 12, 2019

@bszekely1, could you please specify a case when a publisher set both variants(Single and Multiple) via: Prebid.shared.storedAuctionResponse and Prebid.shared.storedbidresponse API.
Should PrebidSDK make additional steps and prioritize types of Stored Auction Response or send request as is ?

@bszekely1
Copy link
Contributor Author

Lets keep all logic and decisions in the Prebid Server side. Ideally PBS would handle the single request as priority. Not something that should be handled in the PB SDK.

@yoalex5 yoalex5 closed this as completed Aug 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants