You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CampaignIDStringOrNumber`json:"cid,omitempty"`// Campaign ID that appears with the Ad markup.
31
-
CreativeIDstring`json:"crid,omitempty"`// Creative ID for reporting content issues or defects. This could also be used as a reference to a creative ID that is posted with an exchange.
32
-
Tacticstring`json:"tactic,omitempty"`// Tactic ID to enable buyers to label bids for reporting to the exchange the tactic through which their bid was submitted.
33
-
Cat []string`json:"cat,omitempty"`// IAB content categories of the creative. Refer to List 5.1
34
-
Attr []int`json:"attr,omitempty"`// Array of creative attributes.
35
-
APIint`json:"api,omitempty"`// API required by the markup if applicable
36
-
Protocolint`json:"protocol,omitempty"`// Video response protocol of the markup if applicable
37
-
QAGMediaRatingint`json:"qagmediarating,omitempty"`// Creative media rating per IQG guidelines.
38
-
Languagestring`json:"language,omitempty"`// Language of the creative using ISO-639-1-alpha-2.
39
-
DealIDstring`json:"dealid,omitempty"`// DealID extension of private marketplace deals
40
-
Hint`json:"h,omitempty"`// Height of the ad in pixels.
41
-
Wint`json:"w,omitempty"`// Width of the ad in pixels.
42
-
WRatioint`json:"wratio,omitempty"`// Relative width of the creative when expressing size as a ratio.
43
-
HRatioint`json:"hratio,omitempty"`// Relative height of the creative when expressing size as a ratio.
44
-
Expint`json:"exp,omitempty"`// Advisory as to the number of seconds the bidder is willing to wait between the auction and the actual impression.
45
-
ExtExtension`json:"ext,omitempty"`
22
+
IDstring`json:"id"`
23
+
ImpIDstring`json:"impid"`// Required string ID of the impression object to which this bid applies.
24
+
Pricefloat64`json:"price"`// Bid price in CPM. Suggests using integer math for accounting to avoid rounding errors.
25
+
AdIDstring`json:"adid,omitempty"`// References the ad to be served if the bid wins.
CampaignIDStringOrNumber`json:"cid,omitempty"`// Campaign ID that appears with the Ad markup.
34
+
CreativeIDstring`json:"crid,omitempty"`// Creative ID for reporting content issues or defects. This could also be used as a reference to a creative ID that is posted with an exchange.
35
+
Tacticstring`json:"tactic,omitempty"`// Tactic ID to enable buyers to label bids for reporting to the exchange the tactic through which their bid was submitted.
36
+
Cat []string`json:"cat,omitempty"`// IAB content categories of the creative. Refer to List 5.1
37
+
Attr []int`json:"attr,omitempty"`// Array of creative attributes.
38
+
APIint`json:"api,omitempty"`// API required by the markup if applicable
39
+
Protocolint`json:"protocol,omitempty"`// Video response protocol of the markup if applicable
40
+
QAGMediaRatingint`json:"qagmediarating,omitempty"`// Creative media rating per IQG guidelines.
41
+
Languagestring`json:"language,omitempty"`// Language of the creative using ISO-639-1-alpha-2.
42
+
DealIDstring`json:"dealid,omitempty"`// DealID extension of private marketplace deals
43
+
Hint`json:"h,omitempty"`// Height of the ad in pixels.
44
+
Wint`json:"w,omitempty"`// Width of the ad in pixels.
45
+
WRatioint`json:"wratio,omitempty"`// Relative width of the creative when expressing size as a ratio.
46
+
HRatioint`json:"hratio,omitempty"`// Relative height of the creative when expressing size as a ratio.
47
+
Expint`json:"exp,omitempty"`// Advisory as to the number of seconds the bidder is willing to wait between the auction and the actual impression.
Copy file name to clipboardExpand all lines: bidrequest.go
+24-21Lines changed: 24 additions & 21 deletions
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,9 @@
1
1
package openrtb
2
2
3
-
import"errors"
3
+
import (
4
+
"encoding/json"
5
+
"errors"
6
+
)
4
7
5
8
// Validation errors
6
9
var (
@@ -13,26 +16,26 @@ var (
13
16
// attribute is required as is at least one "imp" (i.e., impression) object. Other attributes are
14
17
// optional since an exchange may establish default values.
15
18
typeBidRequeststruct {
16
-
IDstring`json:"id"`// Unique ID of the bid request
17
-
Imp []Impression`json:"imp,omitempty"`
18
-
Site*Site`json:"site,omitempty"`
19
-
App*App`json:"app,omitempty"`
20
-
Device*Device`json:"device,omitempty"`
21
-
User*User`json:"user,omitempty"`
22
-
Testint`json:"test,omitempty"`// Indicator of test mode in which auctions are not billable, where 0 = live mode, 1 = test mode
23
-
AuctionTypeint`json:"at"`// Auction type, where 1 = First Price, 2 = Second Price Plus. Exchange-specific auction types can be defined using values greater than 500.
24
-
TMaxint`json:"tmax,omitempty"`// Maximum amount of time in milliseconds to submit a bid
25
-
WSeat []string`json:"wseat,omitempty"`// Array of buyer seats allowed to bid on this auction
26
-
BSeat []string`json:"bseat,omitempty"`// Array of buyer seats blocked to bid on this auction
27
-
WLang []string`json:"wlang,omitempty"`// Array of languages for creatives using ISO-639-1-alpha-2
28
-
AllImpsint`json:"allimps,omitempty"`// Flag to indicate whether exchange can verify that all impressions offered represent all of the impressions available in context, Default: 0
29
-
Cur []string`json:"cur,omitempty"`// Array of allowed currencies
BAdv []string`json:"badv,omitempty"`// Array of strings of blocked toplevel domains of advertisers
32
-
BApp []string`json:"bapp,omitempty"`// Block list of applications by their platform-specific exchange-independent application identifiers. On Android, these should be bundle or package names (e.g., com.foo.mygame). On iOS, these are numeric IDs.
33
-
Source*Source`json:"source,omitempty"`// A Source object that provides data about the inventory source and which entity makes the final decision
34
-
Regs*Regulations`json:"regs,omitempty"`
35
-
ExtExtension`json:"ext,omitempty"`
19
+
IDstring`json:"id"`// Unique ID of the bid request
20
+
Imp []Impression`json:"imp,omitempty"`
21
+
Site*Site`json:"site,omitempty"`
22
+
App*App`json:"app,omitempty"`
23
+
Device*Device`json:"device,omitempty"`
24
+
User*User`json:"user,omitempty"`
25
+
Testint`json:"test,omitempty"`// Indicator of test mode in which auctions are not billable, where 0 = live mode, 1 = test mode
26
+
AuctionTypeint`json:"at"`// Auction type, where 1 = First Price, 2 = Second Price Plus. Exchange-specific auction types can be defined using values greater than 500.
27
+
TMaxint`json:"tmax,omitempty"`// Maximum amount of time in milliseconds to submit a bid
28
+
WSeat []string`json:"wseat,omitempty"`// Array of buyer seats allowed to bid on this auction
29
+
BSeat []string`json:"bseat,omitempty"`// Array of buyer seats blocked to bid on this auction
30
+
WLang []string`json:"wlang,omitempty"`// Array of languages for creatives using ISO-639-1-alpha-2
31
+
AllImpsint`json:"allimps,omitempty"`// Flag to indicate whether exchange can verify that all impressions offered represent all of the impressions available in context, Default: 0
32
+
Cur []string`json:"cur,omitempty"`// Array of allowed currencies
BAdv []string`json:"badv,omitempty"`// Array of strings of blocked toplevel domains of advertisers
35
+
BApp []string`json:"bapp,omitempty"`// Block list of applications by their platform-specific exchange-independent application identifiers. On Android, these should be bundle or package names (e.g., com.foo.mygame). On iOS, these are numeric IDs.
36
+
Source*Source`json:"source,omitempty"`// A Source object that provides data about the inventory source and which entity makes the final decision
37
+
Regs*Regulations`json:"regs,omitempty"`
38
+
Extjson.RawMessage`json:"ext,omitempty"`
36
39
37
40
Pmp*Pmp`json:"pmp,omitempty"`// DEPRECATED: kept for backwards compatibility
0 commit comments