Checking settings and reports
A tool for checking buyer bids
In several cases, bid requests can be sent to buyers multiple times:
- When loading the page: requests are sent to all buyers specified in the configuration script.
- When reloading a placement: using the
reload()
method, the buyers that are only related to the reloaded ad are polled again. - When calling the
pushAdUnits()
method: the request is only sent to the buyers specified in it.
To get bids from the latest buyer polling, use the getLastBidsReceived
method:
window.Ya.headerBidding.getLastBidsReceived();
The response contains an array filled with Bid
objects for each "placement + buyer" pair. An object may only contain one of the following fields:
banner
: If the buyer responds with a regular banner.native
: If the buyer responds with a native banner.error
: If an error occurs.
Example of a method call in the browser console

interface Bid {
adapterName: string; // buyer name
containerId: string; // container ID
campaignId: number; // campaign ID in Adfox
requestDuration: number; // request duration
cost?: {
currency: string; // currency "RUB"/"USD"
cpm: number; // CPM rate returned by the server
},
banner?: {
src: string; // banner contents
},
size?: {
width: number; // width in px
height: number; // height in px
},
error?: {
code: number; // error code
message: string; // error name
},
native?: {
nativePayload: any; // object with contents for a native banner impression
}
};
Error codes:
Error code | Value |
---|---|
0 | Unknown error. |
1 | No bid or response. |
2 | Incorrect response. |
3 | Timeout. |
4 | HTTP error. |
5 | Incorrect user data in the configuration script. |
6 | Incorrect bidder settings. |
7 | The container ID received from the bidder differs from the ID specified in the request. |
8 | A correct response with no status is received from the bidder. |
9 | The bidder's response is missing or has an incorrect CodeType . |
Error code | Value |
---|---|
0 | Unknown error. |
1 | No bid or response. |
2 | Incorrect response. |
3 | Timeout. |
4 | HTTP error. |
5 | Incorrect user data in the configuration script. |
6 | Incorrect bidder settings. |
7 | The container ID received from the bidder differs from the ID specified in the request. |
8 | A correct response with no status is received from the bidder. |
9 | The bidder's response is missing or has an incorrect CodeType . |
Reports by Header Bidding
If monetizers are enabled for your account, reports by Header Bidding are available to you at the site and account levels. To learn more about reports, see Monetization reports.