This repository has been archived by the owner on Oct 12, 2023. It is now read-only.
/
openrtb.proto
3009 lines (2549 loc) · 113 KB
/
openrtb.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Protocol version: v.2.5.0
// LINT: LEGACY_NAMES
syntax = "proto2";
option java_outer_classname = "OpenRtb";
package com.google.openrtb;
// Copyright 2017 Google Inc. All Rights Reserved.
// OpenRTB extensions ("ext" fields in the spec & JSON representation)
// are represented here by Protocol Buffer extensions. This proto only
// reserves the range of IDs 100-9999 at every extensible object.
// Reserved ranges:
// 100-199: Reserved for Google, including the openrtb-doubleclick
// library (DcExt) and Open Bidder project (ObExt).
// 200-999: Free for use with other exchanges or projects.
// 1000-1999: Reserved for Google.
// 2000-9999: Free for use with other exchanges or projects.
// OpenRTB 2.0: The top-level bid request object contains a globally unique
// bid request or auction ID. This id attribute is required as is at least one
// impression object (Section 3.2.2). Other attributes in this top-level object
// establish rules and restrictions that apply to all impressions being offered.
//
// There are also several subordinate objects that provide detailed data to
// potential buyers. Among these are the Site and App objects, which describe
// the type of published media in which the impression(s) appear.
// These objects are highly recommended, but only one applies to a given
// bid request depending on whether the media is browser-based web content
// or a non-browser application, respectively.
message BidRequest {
// Unique ID of the bid request, provided by the exchange.
// REQUIRED by the OpenRTB specification.
// [AdX: BidRequest.id - AdX is binary, OpenRTB is base64 (no padding)]
required string id = 1;
// Array of Imp objects (Section 3.2.2) representing the impressions offered.
// At least 1 Imp object is required.
// [AdX: BidRequest.AdSlot]
repeated Imp imp = 2;
oneof distributionchannel_oneof {
// Details via a Site object (Section 3.2.6) about the publisher's website.
// Only applicable and recommended for websites.
// [AdX: BidRequest]
Site site = 3;
// Details via an App object (Section 3.2.7) about the publisher's app
// (non-browser applications). Only applicable and recommended for apps.
// [AdX: BidRequest, BidRequest.Mobile]
App app = 4;
}
// Details via a Device object (Section 3.2.11) about the user's
// device to which the impression will be delivered.
// [AdX: BidRequest.Mobile, BidRequest.Device]
optional Device device = 5;
// A Regs object (Section 3.2.16) that specifies any industry, legal,
// or governmental regulations in force for this request.
optional Regs regs = 14;
// Details via a User object (Section 3.2.13) about the human
// user of the device; the advertising audience.
// [AdX: BidRequest]
optional User user = 6;
// Auction type, where 1 = First Price, 2 = Second Price Plus.
// Exchange-specific auction types can be defined using values > 500.
// [AdX: 2]
optional AuctionType at = 7 [default = SECOND_PRICE];
// Maximum time in milliseconds to submit a bid to avoid timeout.
// This value is commonly communicated offline.
// [AdX: not mapped, but fixed to 100ms]
optional int32 tmax = 8;
// Whitelist of buyer seats (e.g., advertisers, agencies) allowed to
// bid on this impression. IDs of seats and knowledge of the
// buyer's customers to which they refer must be coordinated
// between bidders and the exchange a priori.
// Omission implies no seat restrictions.
repeated string wseat = 9;
// Flag to indicate if Exchange can verify that the impressions offered
// represent all of the impressions available in context (e.g., all on the
// web page, all video spots such as pre/mid/post roll) to support
// road-blocking. 0 = no or unknown, 1 = yes, the impressions offered
// represent all that are available.
// [AdX: 0]
optional bool allimps = 10 [default = false];
// Array of allowed currencies for bids on this bid request using ISO-4217
// alpha codes. Recommended only if the exchange accepts multiple currencies.
repeated string cur = 11;
// Blocked advertiser categories using the IAB content categories.
// Refer to enum ContentCategory.
// [AdX: BidRequest.AdSlot.excluded_sensitive_category,
// BidRequest.AdSlot.excluded_product_category]
repeated string bcat = 12;
// Block list of advertisers by their domains (e.g., "ford.com").
repeated string badv = 13;
// 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.
repeated string bapp = 16;
// Indicator of test mode in which auctions are not billable,
// where 0 = live mode, 1 = test mode.
// [AdX: BidRequest.is_test]
optional bool test = 15 [default = false];
// Block list of buyer seats (e.g., advertisers, agencies) restricted
// from bidding on this impression. IDs of seats and knowledge
// of the buyer's customers to which they refer must be
// coordinated between bidders and the exchange a priori.
// At most, only one of wseat and bseat should be used in the
// same request. Omission of both implies no seat restrictions.
repeated string bseat = 17;
// White list of languages for creatives using ISO-639-1-alpha-2.
// Omission implies no specific restrictions, but buyers would be
// advised to consider language attribute in the Device and/or
// Content objects if available.
repeated string wlang = 18;
// A Source object (Section 3.2.2) that provides data about the
// inventory source and which entity makes the final decision.
optional Source source = 19;
// Extensions.
extensions 100 to 9999;
// OpenRTB 2.5: This object describes the nature and behavior of the entity
// that is the source of the bid request upstream from the exchange.
// The primary purpose of this object is to define post-auction or upstream
// decisioning when the exchange itself does not control the final decision.
// A common example of this is header bidding, but it can also apply to
// upstream server entities such as another RTB exchange, a mediation
// platform, or an ad server combines direct campaigns with 3rd party
// demand in decisioning.
message Source {
// Entity responsible for the final impression sale decision,
// where 0 = exchange, 1 = upstream source
// RECOMMENDED by the OpenRTB specification.
optional bool fd = 1;
// Transaction ID that must be common across all participants in
// this bid request (e.g., potentially multiple exchanges).
// RECOMMENDED by the OpenRTB specification.
optional string tid = 2;
// Payment ID chain string containing embedded syntax
// described in the TAG Payment ID Protocol v1.0.
// RECOMMENDED by the OpenRTB specification.
optional string pchain = 3;
// Extensions.
extensions 100 to 9999;
}
// OpenRTB 2.0: This object describes an ad placement or impression
// being auctioned. A single bid request can include multiple Imp objects,
// a use case for which might be an exchange that supports selling all
// ad positions on a given page. Each Imp object has a required ID so that
// bids can reference them individually.
//
// The presence of Banner (Section 3.2.3), Video (Section 3.2.4),
// and/or Native (Section 3.2.5) objects subordinate to the Imp object
// indicates the type of impression being offered. The publisher can choose
// one such type which is the typical case or mix them at their discretion.
// Any given bid for the impression must conform to one of the offered types.
message Imp {
// A unique identifier for this impression within the context of the bid
// request (typically, value starts with 1, and increments up to n
// for n impressions).
// [AdX: BidRequest.AdSlot.id]
required string id = 1;
// A Banner object (Section 3.2.3); required if this impression is
// offered as a banner ad opportunity.
// [AdX: BidRequest.AdSlot]
optional Banner banner = 2;
// A Video object (Section 3.2.4); required if this impression is
// offered as a video ad opportunity.
// [AdX: BidRequest.AdSlot, BidRequest.Video]
optional Video video = 3;
// An Audio object; required if this impression is offered
// as an audio ad opportunity.
optional Audio audio = 15;
// Name of ad mediation partner, SDK technology, or player responsible
// for rendering ad (typically video or mobile). Used by some ad servers
// to customize ad code by partner. Recommended for video and/or apps.
optional string displaymanager = 4;
// Version of ad mediation partner, SDK technology, or player responsible
// for rendering ad (typically video or mobile). Used by some ad servers
// to customize ad code by partner. Recommended for video and/or apps.
optional string displaymanagerver = 5;
// 1 = the ad is interstitial or full screen, 0 = not interstitial.
// [AdX: BidRequest.AdSlot.Mobile.is_interstitial_request]
optional bool instl = 6;
// Identifier for specific ad placement or ad tag that was used to
// initiate the auction. This can be useful for debugging of any issues,
// or for optimization by the buyer.
// [AdX: BidRequest.AdSlot.ad_block_key]
optional string tagid = 7;
// Minimum bid for this impression expressed in CPM.
// [AdX: min(BidRequest.AdSlot.matching_ad_data.minimum_cpm_micros) *
// 1,000,000]
optional double bidfloor = 8 [default = 0];
// Currency specified using ISO-4217 alpha codes. This may be different
// from bid currency returned by bidder if this is allowed by the exchange.
// [AdX: A single currency, obtained from the included billing_id]
optional string bidfloorcur = 9 [default = "USD"];
// Indicates the type of browser opened upon clicking the
// creative in an app, where 0 = embedded, 1 = native.
// Note that the Safari View Controller in iOS 9.x devices is considered
// a native browser for purposes of this attribute.
optional bool clickbrowser = 16;
// Flag to indicate if the impression requires secure HTTPS URL creative
// assets and markup, where 0 = non-secure, 1 = secure. If omitted,
// the secure state is unknown, but non-secure HTTP support can be assumed.
optional bool secure = 12;
// Array of exchange-specific names of supported iframe busters.
// [AdX: Unsupported; use macro %%CACHEBUSTER%% in the snippet]
repeated string iframebuster = 10;
// A Pmp object (Section 3.2.17) containing any private marketplace deals
// in effect for this impression.
// [AdX: BidRequest.AdSlot.MatchingAdData]
optional Pmp pmp = 11;
// A Native object (Section 3.2.5); required if this impression is
// offered as a native ad opportunity.
// [AdX: BidRequest.AdSlot.NativeAdTemplate]
optional Native native = 13;
// Advisory as to the number of seconds that may elapse
// between the auction and the actual impression.
optional int32 exp = 14;
// An array of Metric object (Section 3.2.5).
repeated Metric metric = 17;
// Extensions.
extensions 100 to 9999;
// OpenRTB 2.5: This object is associated with an impression as
// an array of metrics. These metrics can offer insight into
// the impression to assist with decisioning such as average recent
// viewability, click-through rate, etc. Each metric is identified
// by its type, reports the value of the metric, and optionally
// identifies the source or vendor measuring the value.
message Metric {
// Type of metric being presented using exchange curated string
// names which should be published to bidders a priori.
// REQUIRED by the OpenRTB specification.
optional string type = 1;
// Number representing the value of the metric.
// Probabilities must be in the range 0.0 – 1.0.
// REQUIRED by the OpenRTB specification.
optional double value = 2;
// Source of the value using exchange curated string names
// which should be published to bidders a priori.
// If the exchange itself is the source versus a third party,
// "EXCHANGE" is recommended.
// RECOMMENDED by the OpenRTB specification.
optional string vendor = 3;
// Extensions.
extensions 100 to 9999;
}
// OpenRTB 2.0: This object represents the most general type of
// impression. Although the term "banner" may have very specific meaning
// in other contexts, here it can be many things including a simple static
// image, an expandable ad unit, or even in-banner video (refer to the Video
// object in Section 3.2.4 for the more generalized and full featured video
// ad units). An array of Banner objects can also appear within the Video
// to describe optional companion ads defined in the VAST specification.
//
// The presence of a Banner as a subordinate of the Imp object indicates
// that this impression is offered as a banner type impression.
// At the publisher's discretion, that same impression may also be offered
// as video and/or native by also including as Imp subordinates the Video
// and/or Native objects, respectively. However, any given bid for the
// impression must conform to one of the offered types.
message Banner {
// Width in device independent pixels (DIPS).
// If no format objects are specified, this is an exact width
// requirement. Otherwise it is a preferred width.
// [AdX: BidRequest.AdSlot.width[0]]
optional int32 w = 1;
// Height in device independent pixels (DIPS).
// If no format objects are specified, this is an exact height
// requirement. Otherwise it is a preferred height.
// [AdX: BidRequest.AdSlot.height[0]]
optional int32 h = 2;
// Array of format objects representing the banner sizes permitted.
// If none are specified, then use of the h and w attributes
// is highly recommended.
repeated Format format = 15;
// NOTE: Deprecated in favor of the format array.
// Maximum width in device independent pixels (DIPS).
// [AdX: max(BidRequest.AdSlot.width) if |width| > 1]
optional int32 wmax = 11 [deprecated = true];
// NOTE: Deprecated in favor of the format array.
// Maximum height in device independent pixels (DIPS).
// [AdX: max(BidRequest.AdSlot.height) if |height| > 1]
optional int32 hmax = 12 [deprecated = true];
// NOTE: Deprecated in favor of the format array.
// Minimum width in device independent pixels (DIPS).
// [AdX: min(BidRequest.AdSlot.width) if |width| > 1]
optional int32 wmin = 13 [deprecated = true];
// NOTE: Deprecated in favor of the format array.
// Minimum height in device independent pixels (DIPS).
// [AdX: min(BidRequest.AdSlot.height) if |height| > 1]
optional int32 hmin = 14 [deprecated = true];
// Unique identifier for this banner object. Recommended when Banner
// objects are used with a Video object (Section 3.2.4) to represent
// an array of companion ads. Values usually start at 1 and increase
// with each object; should be unique within an impression.
optional string id = 3;
// Ad position on screen.
// [AdX: BidRequest.AdSlot.slot_visibility]
optional AdPosition pos = 4;
// Blocked banner ad types.
repeated BannerAdType btype = 5 [packed = true];
// Blocked creative attributes.
// [AdX: BidRequest.AdSlot.excluded_attribute]
repeated CreativeAttribute battr = 6 [packed = true];
// Whitelist of content MIME types supported. Popular MIME types include,
// but are not limited to "image/jpg", "image/gif" and
// "application/x-shockwave-flash".
// [AdX: Only mapped for BidRequest.Video.companionad:
// BidRequest.Video.companionad.creative_format,
// BidRequest.AdSlot.excluded_attribute / VPAID]
repeated string mimes = 7;
// Specify if the banner is delivered in the top frame (true)
// or in an iframe (false).
// [AdX: BidRequest.AdSlot.iframing_state
// NO_IFRAME: false
// SAME_DOMAIN_IFRAME, CROSS_DOMAIN_IFRAME: true]
optional bool topframe = 8;
// Directions in which the banner may expand.
// [AdX: BidRequest.AdSlot.excluded_attribute / EXPANDING_*]
repeated ExpandableDirection expdir = 9 [packed = true];
// List of supported API frameworks for this impression.
// If an API is not explicitly listed, it is assumed not to be supported.
// [AdX: BidRequest.AdSlot.excluded_attribute / MRAID_1_0]
repeated APIFramework api = 10 [packed = true];
// Relevant only for Banner objects used with a Video object
// (Section 3.2.7) in an array of companion ads. Indicates the
// companion banner rendering mode relative to the associated
// video, where 0 = concurrent, 1 = end-card.
optional bool vcm = 16;
// Extensions.
extensions 100 to 9999;
// OpenRTB 2.4: This object represents an allowed size (i.e.,
// height and width combination) for a banner impression.
// These are typically used in an array for an impression where
// multiple sizes are permitted.
message Format {
// Width in device independent pixels (DIPS).
optional int32 w = 1;
// Height in device independent pixels (DIPS).
optional int32 h = 2;
// Relative width when expressing size as a ratio.
optional int32 wratio = 3;
// Relative height when expressing size as a ratio.
optional int32 hratio = 4;
// The minimum width in device independent pixels (DIPS) at
// which the ad will be displayed when the size is expressed as a ratio.
optional int32 wmin = 5;
// Extensions.
extensions 100 to 9999;
}
}
// OpenRTB 2.0: This object represents an in-stream video impression.
// Many of the fields are non-essential for minimally viable transactions,
// but are included to offer fine control when needed. Video in OpenRTB
// generally assumes compliance with the VAST standard. As such, the notion
// of companion ads is supported by optionally including an array of Banner
// objects (refer to the Banner object in Section 3.2.3) that define these
// companion ads.
//
// The presence of a Video as a subordinate of the Imp object indicates
// that this impression is offered as a video type impression. At the
// publisher's discretion, that same impression may also be offered as
// banner and/or native by also including as Imp subordinates the Banner
// and/or Native objects, respectively. However, any given bid for the
// impression must conform to one of the offered types.
message Video {
// Whitelist of content MIME types supported. Popular MIME types include,
// but are not limited to "image/jpg", "image/gif" and
// "application/x-shockwave-flash".
// REQUIRED by the OpenRTB specification: at least 1 element.
// [AdX: BidRequest.Video.allowed_video_formats,
// BidRequest.AdSlot.excluded_attribute / VPAID]
repeated string mimes = 1;
// Indicates if the impression must be linear, nonlinear, etc.
// If none specified, assume all are allowed.
optional VideoLinearity linearity = 2;
// Minimum video ad duration in seconds.
// RECOMMENDED by the OpenRTB specification.
// [AdX: BidRequest.Video.min_ad_duration]
optional int32 minduration = 3;
// Maximum video ad duration in seconds.
// RECOMMENDED by the OpenRTB specification.
// [AdX: BidRequest.Video.max_ad_duration]
optional int32 maxduration = 4;
// Deprecated; use protocols.
optional Protocol protocol = 5 [deprecated = true];
// Array of supported video bid response protocols.
// At least one supported protocol must be specified.
// [AdX: BidRequest.Video.protocols]
repeated Protocol protocols = 21 [packed = true];
// Width of the video player in device independent pixels (DIPS).
// RECOMMENDED by the OpenRTB specification.
// [AdX: BidRequest.AdSlot.width[0]]
optional int32 w = 6;
// Height of the video player in device independent pixels (DIPS).
// RECOMMENDED by the OpenRTB specification.
// [AdX: BidRequest.AdSlot.height[0]]
optional int32 h = 7;
// Indicates the start delay in seconds for pre-roll, mid-roll, or
// post-roll ad placements.
// Refer to enum StartDelay for generic values.
// RECOMMENDED by the OpenRTB specification.
// [AdX: BidRequest.Video.videoad_start_delay
// 0: PRE_ROLL
// 1: GENERIC_MID_ROLL
// -1: GENERIC_POST_ROLL
// Other values: videoad_start_delay / 1,000]
optional int32 startdelay = 8;
// Indicates if the player will allow the video to be skipped,
// where 0 = no, 1 = yes.
// If a bidder sends markup/creative that is itself skippable, the
// Bid object should include the attr array with an element of
// 16 indicating skippable video.
// [AdX: BidRequest.Video.video_ad_skippable
// 0: ALLOW_SKIPPABLE
// 1: REQUIRE_SKIPPABLE
// 2: BLOCK_SKIPPABLE]
optional bool skip = 23;
// Videos of total duration greater than this number of seconds
// can be skippable; only applicable if the ad is skippable.
optional int32 skipmin = 24;
// Number of seconds a video must play before skipping is
// enabled; only applicable if the ad is skippable.
optional int32 skipafter = 25;
// If multiple ad impressions are offered in the same bid request,
// the sequence number will allow for the coordinated delivery of
// multiple creatives.
optional int32 sequence = 9 [default = 1];
// Blocked creative attributes.
// [AdX: BidRequest.AdSlot.excluded_attribute]
repeated CreativeAttribute battr = 10 [packed = true];
// Maximum extended video ad duration, if extension is allowed.
// If blank or 0, extension is not allowed. If -1, extension is allowed,
// and there is no time limit imposed. If greater than 0, then the value
// represents the number of seconds of extended play supported beyond
// the maxduration value.
optional int32 maxextended = 11;
// Minimum bit rate in Kbps.
optional int32 minbitrate = 12;
// Maximum bit rate in Kbps.
optional int32 maxbitrate = 13;
// Indicates if letter-boxing of 4:3 content into a 16:9 window is
// allowed, where 0 = no, 1 = yes.
optional bool boxingallowed = 14 [default = true];
// Playback methods that may be in use. If none are specified, any
// method may be used. Only one method is typically used in practice.
// As a result, this array may be converted to an integer in a future
// version of the specification. It is strongly advised to use only
// the first element of this array in preparation for this change.
// [AdX: BidRequest.Video.playback_method]
repeated PlaybackMethod playbackmethod = 15 [packed = true];
// Supported delivery methods (e.g., streaming, progressive).
// If none specified, assume all are supported.
repeated ContentDeliveryMethod delivery = 16 [packed = true];
// Ad position on screen.
// [AdX: BidRequest.AdSlot.slot_visibility]
optional AdPosition pos = 17;
// Array of Banner objects (Section 3.2.3) if companion ads are available.
// [AdX: BidRequest.Video.companion_slot]
repeated Banner companionad = 18;
// Companion ads in OpenRTB 2.1 format. (Or to be precise, interpretations
// based on the buggy sample message in 5.1.4, fixed later in 2.2.)
optional CompanionAd companionad_21 = 22 [deprecated = true];
// List of supported API frameworks for this impression.
// If an API is not explicitly listed, it is assumed not to be supported.
// [AdX: BidRequest.AdSlot.excluded_attribute / MRAID_1_0]
repeated APIFramework api = 19 [packed = true];
// Supported VAST companion ad types. Recommended if companion Banner
// objects are included via the companionad array.
// [AdX: BidRequest.Video.companion_slot.creative_format]
repeated CompanionType companiontype = 20 [packed = true];
// Placement type for the impression.
optional VideoPlacementType placement = 26;
// The event that causes playback to end.
optional PlaybackCessationMode playbackend = 27;
// Extensions.
extensions 100 to 9999;
// OpenRTB 2.1 compatibility.
message CompanionAd {
repeated Banner banner = 1;
extensions 100 to 9999;
}
}
// This object represents an audio type impression. Many of the fields
// are non-essential for minimally viable transactions, but are included
// to offer fine control when needed. Audio in OpenRTB generally assumes
// compliance with the DAAST standard. As such, the notion of companion
// ads is supported by optionally including an array of Banner objects
// that define these companion ads.
//
// The presence of a Audio as a subordinate of the Imp object indicates
// that this impression is offered as an audio type impression.
// At the publisher’s discretion, that same impression may also be offered
// as banner, video, and/or native by also including as Imp subordinates
// objects of those types. However, any given bid for the impression must
// conform to one of the offered types.
message Audio {
// Content MIME types supported (e.g., "audio/mp4").
// REQUIRED by the OpenRTB specification: at least 1 element.
repeated string mimes = 1;
// Minimum audio ad duration in seconds.
// RECOMMENDED by the OpenRTB specification.
optional int32 minduration = 2;
// Maximum audio ad duration in seconds.
// RECOMMENDED by the OpenRTB specification.
optional int32 maxduration = 3;
// Array of supported audio protocols.
// RECOMMENDED by the OpenRTB specification.
repeated Protocol protocols = 4 [packed = true];
// Indicates the start delay in seconds for pre-roll, mid-roll, or
// post-roll ad placements.
// Refer to enum StartDelay for generic values.
// RECOMMENDED by the OpenRTB specification.
optional int32 startdelay = 5;
// If multiple ad impressions are offered in the same bid request,
// the sequence number will allow for the coordinated delivery of
// multiple creatives.
optional int32 sequence = 6 [default = 1];
// Blocked creative attributes.
repeated CreativeAttribute battr = 7 [packed = true];
// Maximum extended video ad duration, if extension is allowed.
// If blank or 0, extension is not allowed. If -1, extension is allowed,
// and there is no time limit imposed. If greater than 0, then the value
// represents the number of seconds of extended play supported beyond
// the maxduration value.
optional int32 maxextended = 8;
// Minimum bit rate in Kbps.
optional int32 minbitrate = 9;
// Maximum bit rate in Kbps.
optional int32 maxbitrate = 10;
// Supported delivery methods (e.g., streaming, progressive).
// If none specified, assume all are supported.
repeated ContentDeliveryMethod delivery = 11 [packed = true];
// Array of Banner objects if companion ads are available.
repeated Banner companionad = 12;
// List of supported API frameworks for this impression.
// If an API is not explicitly listed, it is assumed not to be supported.
repeated APIFramework api = 13 [packed = true];
// Supported DAAST companion ad types. Recommended if companion Banner
// objects are included via the companionad array.
repeated CompanionType companiontype = 20 [packed = true];
// The maximum number of ads that can be played in an ad pod.
optional int32 maxseq = 21;
// Type of audio feed.
optional FeedType feed = 22;
// Indicates if the ad is stitched with audio content or delivered
// independently, where 0 = no, 1 = yes.
optional bool stitched = 23;
// Volume normalization mode.
optional VolumeNormalizationMode nvol = 24;
// Extensions.
extensions 100 to 9999;
}
// OpenRTB 2.3: This object represents a native type impression.
// Native ad units are intended to blend seamlessly into the surrounding
// content (e.g., a sponsored Twitter or Facebook post). As such, the
// response must be well-structured to afford the publisher fine-grained
// control over rendering.
//
// The Native Subcommittee has developed a companion specification to
// OpenRTB called the Native Ad Specification. It defines the request
// parameters and response markup structure of native ad units.
// This object provides the means of transporting request parameters as an
// opaque string so that the specific parameters can evolve separately
// under the auspices of the Native Ad Specification. Similarly, the
// ad markup served will be structured according to that specification.
//
// The presence of a Native as a subordinate of the Imp object indicates
// that this impression is offered as a native type impression.
// At the publisher's discretion, that same impression may also be offered
// as banner and/or video by also including as Imp subordinates the Banner
// and/or Video objects, respectively. However, any given bid for the
// impression must conform to one of the offered types.
message Native {
oneof request_oneof {
// Request payload complying with the Native Ad Specification.
// Exactly one of {request, request_native} should be used;
// this is the OpenRTB-compliant field for JSON serialization.
// [AdX: BidRequest.AdSlot.NativeAdTemplate]
string request = 1;
// Request payload complying with the Native Ad Specification.
// Exactly one of {request, request_native} should be used;
// this is an alternate field preferred for Protobuf serialization.
// [AdX: BidRequest.AdSlot.NativeAdTemplate]
NativeRequest request_native = 50;
}
// Version of the Native Ad Specification to which request complies.
// RECOMMENDED by the OpenRTB specification.
// [AdX: "1.0" for OpenRTB 2.3; "1.1" for OpenRTB 2.4]
optional string ver = 2;
// List of supported API frameworks for this impression.
// If an API is not explicitly listed, it is assumed not to be supported.
// [AdX: BidRequest.AdSlot.excluded_attribute / MRAID_1_0]
repeated APIFramework api = 3 [packed = true];
// Blocked creative attributes.
// [AdX: BidRequest.AdSlot.excluded_attribute]
repeated CreativeAttribute battr = 4 [packed = true];
// Extensions.
extensions 100 to 9999;
}
// OpenRTB 2.2: This object is the private marketplace container for
// direct deals between buyers and sellers that may pertain to this
// impression. The actual deals are represented as a collection of
// Deal objects. Refer to Section 7.2 for more details.
message Pmp {
// Indicator of auction eligibility to seats named in the Direct Deals
// object, where 0 = all bids are accepted, 1 = bids are restricted to
// the deals specified and the terms thereof.
optional bool private_auction = 1 [default = false];
// Array of Deal (Section 3.2.18) objects that convey the specific deals
// applicable to this impression.
// [AdX: BidRequest.AdSlot.MatchingAdData.DirectDeal]
repeated Deal deals = 2;
// Extensions.
extensions 100 to 9999;
// OpenRTB 2.2: This object constitutes a specific deal that was struck
// a priori between a buyer and a seller. Its presence with the Pmp
// collection indicates that this impression is available under the terms
// of that deal. Refer to Section 7.2 for more details.
message Deal {
// A unique identifier for the direct deal.
// REQUIRED by the OpenRTB specification.
// [AdX: BidRequest.AdSlot.MatchingAdData.DirectDeal.direct_deal_id]
required string id = 1;
// Minimum bid for this impression expressed in CPM.
// [AdX: BidRequest.AdSlot.MatchingAdData.DirectDeal.fixed_cpm_micros *
// 1,000,000]
optional double bidfloor = 2 [default = 0];
// Currency specified using ISO-4217 alpha codes. This may be different
// from bid currency returned by bidder if this is allowed
// by the exchange.
// [AdX: A single currency, obtained from the included billing_id]
optional string bidfloorcur = 3 [default = "USD"];
// Whitelist of buyer seats (e.g., advertisers, agencies) allowed to
// bid on this deal. IDs of seats and knowledge of the buyer's
// customers to which they refer must be coordinated between bidders
// and the exchange a priori. Omission implies no seat restrictions.
repeated string wseat = 4;
// Array of advertiser domains (e.g., advertiser.com) allowed to
// bid on this deal. Omission implies no advertiser restrictions.
repeated string wadomain = 5;
// Optional override of the overall auction type of the bid request,
// where 1 = First Price, 2 = Second Price Plus, 3 = the value passed
// in bidfloor is the agreed upon deal price. Additional auction types
// can be defined by the exchange.
// [AdX: BidRequest.AdSlot.MatchingAdData.DirectDeal.deal_type]
optional AuctionType at = 6;
// Extensions.
extensions 100 to 9999;
}
}
}
// OpenRTB 2.0: This object should be included if the ad supported content
// is a website as opposed to a non-browser application. A bid request must
// not contain both a Site and an App object. At a minimum, it is useful to
// provide a site ID or page URL, but this is not strictly required.
message Site {
// Site ID on the exchange.
// RECOMMENDED by the OpenRTB specification.
optional string id = 1;
// Site name (may be masked at publisher's request).
// [AdX: BidRequest.anonymous_id]
optional string name = 2;
// Domain of the site, used for advertiser side blocking.
// For example, "foo.com".
optional string domain = 3;
// Array of IAB content categories of the site.
// See enum ContentCategory.
repeated string cat = 4;
// Array of IAB content categories that describe the current section
// of the site.
// See enum ContentCategory.
repeated string sectioncat = 5;
// Array of IAB content categories that describe the current page or view
// of the site.
// See enum ContentCategory.
repeated string pagecat = 6;
// URL of the page where the impression will be shown.
// [AdX: BidRequest.url]
optional string page = 7;
// Indicates if the site has a privacy policy, where 0 = no, 1 = yes.
optional bool privacypolicy = 8;
// Referrer URL that caused navigation to the current page.
optional string ref = 9;
// Search string that caused navigation to the current page.
optional string search = 10;
// Details about the Publisher (Section 3.2.8) of the site.
// [AdX: BidRequest]
optional Publisher publisher = 11;
// Details about the Content (Section 3.2.9) within the site.
// [AdX: BidRequest]
optional Content content = 12;
// Comma separated list of keywords about this site.
// Note: OpenRTB 2.2 allowed an array-of-strings as alternate implementation
// but this was fixed in 2.3+ where it's definitely a single string with CSV
// content again. Compatibility with some OpenRTB 2.2 exchanges that adopted
// the alternate representation may require custom handling of the JSON.
optional string keywords = 13;
// Indicates if the site has been programmed to optimize layout
// when viewed on mobile devices, where 0 = no, 1 = yes.
// [AdX: BidRequest.Mobile.is_mobile_web_optimized]
optional bool mobile = 15;
// Extensions.
extensions 100 to 9999;
}
// OpenRTB 2.0: This object should be included if the ad supported content
// is a non-browser application (typically in mobile) as opposed to a website.
// A bid request must not contain both an App and a Site object.
// At a minimum, it is useful to provide an App ID or bundle,
// but this is not strictly required.
message App {
// Application ID on the exchange.
// RECOMMENDED by the OpenRTB specification.
optional string id = 1;
// Application name (may be aliased at publisher's request).
// [AdX: BidRequest.Mobile.app_name]
optional string name = 2;
// Domain of the application. For example, "mygame.foo.com".
optional string domain = 3;
// Array of IAB content categories of the app.
// See enum ContentCategory.
repeated string cat = 4;
// Array of IAB content categories that describe the current section
// of the app.
// See enum ContentCategory.
repeated string sectioncat = 5;
// Array of IAB content categories that describe the current page or view
// of the app.
// See enum ContentCategory.
repeated string pagecat = 6;
// Application version.
optional string ver = 7;
// A platform-specific application identifier intended to be
// unique to the app and independent of the exchange. On Android,
// this should be a bundle or package name (e.g., com.foo.mygame).
// On iOS, it is a numeric ID.
// [AdX: BidRequest.Mobile.app_id]
optional string bundle = 8;
// Indicates if the app has a privacy policy, where 0 = no, 1 = yes.
optional bool privacypolicy = 9;
// 0 = app is free, 1 = the app is a paid version.
optional bool paid = 10;
// Details about the Publisher (Section 3.2.8) of the app.
// [AdX: BidRequest]
optional Publisher publisher = 11;
// Details about the Content (Section 3.2.9) within the app.
// [AdX: BidRequest]
optional Content content = 12;
// Comma separated list of keywords about the app.
optional string keywords = 13;
// App store URL for an installed app; for QAG 1.5 compliance.
optional string storeurl = 16;
// Extensions.
extensions 100 to 9999;
}
// OpenRTB 2.0: This object describes the publisher of the media in which
// the ad will be displayed. The publisher is typically the seller
// in an OpenRTB transaction.
message Publisher {
// Exchange-specific publisher ID.
// [AdX: BidRequest.seller_network_id]
optional string id = 1;
// Publisher name (may be aliased at publisher's request).
optional string name = 2;
// Array of IAB content categories that describe the publisher.
// See enum ContentCategory.
repeated string cat = 3;
// Highest level domain of the publisher (e.g., "publisher.com").
optional string domain = 4;
// Extensions.
extensions 100 to 9999;
}
// OpenRTB 2.0: This object describes the content in which the impression
// will appear, which may be syndicated or non-syndicated content.
// This object may be useful when syndicated content contains impressions and
// does not necessarily match the publisher's general content.
// The exchange might or might not have knowledge of the page where the
// content is running, as a result of the syndication method.
// For example might be a video impression embedded in an iframe on an
// unknown web property or device.
message Content {
// ID uniquely identifying the content.
// [AdX: (Only App.content) BidRequest.anonymous_id]
optional string id = 1;
// Content episode number (typically applies to video content).
optional int32 episode = 2;
// Content title.
// Video Examples: "Search Committee" (television), "A New Hope" (movie),
// or "Endgame" (made for web).
// Non-Video Example: "Why an Antarctic Glacier Is Melting So Quickly"
// (Time magazine article).
// [AdX: BidRequest.Video.ContentAttributes.title]
optional string title = 3;
// Content series.
// Video Examples: "The Office" (television), "Star Wars" (movie),
// or "Arby 'N' The Chief" (made for web).
// Non-Video Example: "Ecocentric" (Time Magazine blog).
optional string series = 4;
// Content season; typically for video content (e.g., "Season 3").
optional string season = 5;
// Artist credited with the content.
optional string artist = 21;
// Genre that best describes the content (e.g., rock, pop, etc).
optional string genre = 22;
// Album to which the content belongs; typically for audio.
optional string album = 23;
// International Standard Recording Code conforming to ISO-3901.
optional string isrc = 24;
// URL of the content, for buy-side contextualization or review.
// [AdX: (Only App.content) BidRequest.url]
optional string url = 6;
// Array of IAB content categories that describe the content.
// See enum ContentCategory.
repeated string cat = 7;
// Production quality.
optional ProductionQuality prodq = 25;
// NOTE: Deprecated in favor of prodq.
// Video quality per IAB's classification.
optional ProductionQuality videoquality = 8 [deprecated = true];
// Comma separated list of keywords describing the content.
// Note: OpenRTB 2.2 allowed an array-of-strings as alternate implementation
// but this was fixed in 2.3+ where it's definitely a single string with CSV