Skip to content

Commit 53ac1b9

Browse files
authored
ORTB + AdCOM 202303 Updates (#8)
* ORTB + AdCOM 202303 Updates * Bump Major Version * Copy Paste Errors * Fix Mod File * Keep On 1.16 * Revert Go Mod Version * Rename plcmnt to plcmt To Align With Native * Final Spec Updates * Fix VideoPlcmtNoContent * Update Category Taxonomies
1 parent 49cfc48 commit 53ac1b9

49 files changed

Lines changed: 226 additions & 70 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
# openrtb [![Go Reference](https://pkg.go.dev/badge/github.com/prebid/openrtb/v18.svg)](https://pkg.go.dev/github.com/prebid/openrtb/v18) [![Test](https://github.com/prebid/openrtb/actions/workflows/test.yml/badge.svg)](https://github.com/prebid/openrtb/actions/workflows/test.yml)
1+
# openrtb [![Go Reference](https://pkg.go.dev/badge/github.com/prebid/openrtb/v19.svg)](https://pkg.go.dev/github.com/prebid/openrtb/v19) [![Test](https://github.com/prebid/openrtb/actions/workflows/test.yml/badge.svg)](https://github.com/prebid/openrtb/actions/workflows/test.yml)
22

33
[OpenRTB](https://iabtechlab.com/standards/openrtb/), [AdCOM](https://iabtechlab.com/standards/openmedia) and [OpenRTB Dynamic Native Ads](https://iabtechlab.com/standards/openrtb-native/) types for [Go programming language](https://golang.org/)
44

5-
- [openrtb2](openrtb2/) - [OpenRTB](https://iabtechlab.com/standards/openrtb/) [2.5](https://iabtechlab.com/wp-content/uploads/2016/07/OpenRTB-API-Specification-Version-2-5-FINAL.pdf), [2.6](https://iabtechlab.com/wp-content/uploads/2022/04/OpenRTB-2-6_FINAL.pdf)
5+
- [openrtb2](openrtb2/) - [OpenRTB](https://iabtechlab.com/standards/openrtb/) [2.5](https://iabtechlab.com/wp-content/uploads/2016/07/OpenRTB-API-Specification-Version-2-5-FINAL.pdf), [2.6](https://github.com/InteractiveAdvertisingBureau/openrtb2.x/blob/main/2.6.md)
66
- [openrtb3](openrtb3/) - [OpenRTB](https://iabtechlab.com/standards/openrtb/) [3.0](https://github.com/InteractiveAdvertisingBureau/openrtb) (can lag behind because official spec is constantly updated without version bump, feel free to PR)
77
- [adcom1](adcom1/) - [AdCOM](https://iabtechlab.com/standards/openmedia/) [1.0](https://github.com/InteractiveAdvertisingBureau/AdCOM) (can lag behind because official spec is constantly updated without version bump, feel free to PR)
88
- [native1](native1/) - [OpenRTB Dynamic Native Ads API](https://iabtechlab.com/standards/openrtb-native/) [1.2](https://iabtechlab.com/wp-content/uploads/2016/07/OpenRTB-Native-Ads-Specification-Final-1.2.pdf)
@@ -14,19 +14,19 @@ This library uses [Go modules](https://golang.org/ref/mod) ([tl;dr](https://blog
1414
# Using
1515

1616
```bash
17-
go get -u "github.com/prebid/openrtb/v18/..."
17+
go get -u "github.com/prebid/openrtb/v19/..."
1818
```
1919

2020
```go
2121
import (
22-
openrtb2 "github.com/prebid/openrtb/v18/openrtb2"
22+
openrtb2 "github.com/prebid/openrtb/v19/openrtb2"
2323

24-
openrtb3 "github.com/prebid/openrtb/v18/openrtb3"
25-
adcom1 "github.com/prebid/openrtb/v18/adcom1"
24+
openrtb3 "github.com/prebid/openrtb/v19/openrtb3"
25+
adcom1 "github.com/prebid/openrtb/v19/adcom1"
2626

27-
native1 "github.com/prebid/openrtb/v18/native1"
28-
nreq "github.com/prebid/openrtb/v18/native1/request"
29-
nres "github.com/prebid/openrtb/v18/native1/response"
27+
native1 "github.com/prebid/openrtb/v19/native1"
28+
nreq "github.com/prebid/openrtb/v19/native1/request"
29+
nres "github.com/prebid/openrtb/v19/native1/response"
3030
)
3131
```
3232

@@ -63,7 +63,7 @@ Pointer | Omitempty | When to use
6363

6464
Using both pointer and `omitempty` is mostly just to save traffic / generate more "canonical" (strict) JSON.
6565

66-
## Documentation ([pkg.go.dev](https://pkg.go.dev/github.com/prebid/openrtb/v18))
66+
## Documentation ([pkg.go.dev](https://pkg.go.dev/github.com/prebid/openrtb/v19))
6767
- [Godoc: documenting Go code](http://blog.golang.org/godoc-documenting-go-code)
6868
- Each entity (type, struct key or constant) should be documented
6969
- Ideally, copy-paste descriptions as-is, but feel free to omit section numbers, so just `<GoTypeName> defines <copy-pasted description from spec>`

adcom1/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
# adcom1 [![GoDoc](https://godoc.org/github.com/prebid/openrtb/adcom1?status.svg)](https://pkg.go.dev/github.com/prebid/openrtb/v18/adcom1)
1+
# adcom1 [![GoDoc](https://godoc.org/github.com/prebid/openrtb/adcom1?status.svg)](https://pkg.go.dev/github.com/prebid/openrtb/v19/adcom1)
22

33
[AdCOM](https://iabtechlab.com/standards/openmedia/) [1.0](https://github.com/InteractiveAdvertisingBureau/AdCOM) types for [Go programming language](https://golang.org/)

adcom1/adcom1_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88
. "github.com/onsi/ginkgo/extensions/table"
99
. "github.com/onsi/gomega"
1010

11-
. "github.com/prebid/openrtb/v18/adcom1"
11+
. "github.com/prebid/openrtb/v19/adcom1"
1212
)
1313

1414
var _ = DescribeTable(

adcom1/auto_refresh_trigger.go

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
package adcom1
2+
3+
// AutoRefreshTrigger represents a list of triggers that result in an ad slot refreshing.
4+
type AutoRefreshTrigger int8
5+
6+
// Triggers support by a placement or required by an ad.
7+
const (
8+
AutoRefreshTriggerUnknown AutoRefreshTrigger = 0
9+
AutoRefreshTriggerUserAction AutoRefreshTrigger = 1 // Refresh triggered by user-initiated action such as scrolling.
10+
AutoRefreshTriggerEvent AutoRefreshTrigger = 2 // Event-driven content change. For example, ads refresh when the football game score changes on the page.
11+
AutoRefreshTriggerTime AutoRefreshTrigger = 3 // Time-based refresh. Ads refresh on a predefined time interval even without user activity.
12+
)

adcom1/category_taxonomy.go

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,11 @@ type CategoryTaxonomy int64
77
//
88
// Values of 500+ hold vendor-specific codes.
99
const (
10-
CatTaxIABContent10 CategoryTaxonomy = 1 // 1 IAB Content Category Taxonomy 1.0.
11-
CatTaxIABContent20 CategoryTaxonomy = 2 // 2 IAB Content Category Taxonomy 2.0: www.iab.com/guidelines/taxonomy
12-
CatTaxIABProduct10 CategoryTaxonomy = 3 // 3 IAB Ad Product Taxonomy 1.0.
13-
CatTaxIABAudience11 CategoryTaxonomy = 4 // 4 IAB Audience Taxonomy 1.1.
14-
CatTaxIABContent21 CategoryTaxonomy = 5 // 5 IAB Content Category Taxonomy 2.1.
15-
CatTaxIABContent22 CategoryTaxonomy = 6 // 6 IAB Content Category Taxonomy 2.2
10+
CatTaxIABContent10 CategoryTaxonomy = 1 // IAB Tech Lab Content Category Taxonomy 1.0: Deprecated, and recommend NOT be used since it does not have SCD flags.
11+
CatTaxIABContent20 CategoryTaxonomy = 2 // IAB Tech Lab Content Category Taxonomy 2.0: Deprecated, and recommend NOT be used since it does not have SCD flags.
12+
CatTaxIABProduct10 CategoryTaxonomy = 3 // IAB Tech Lab Ad Product Taxonomy 1.0.
13+
CatTaxIABAudience11 CategoryTaxonomy = 4 // IAB Tech Lab Audience Taxonomy 1.1.
14+
CatTaxIABContent21 CategoryTaxonomy = 5 // IAB Tech Lab Content Category Taxonomy 2.1.
15+
CatTaxIABContent22 CategoryTaxonomy = 6 // IAB Tech Lab Content Category Taxonomy 2.2.
16+
CatTaxIABContent30 CategoryTaxonomy = 7 // IAB Tech Lab Content Category Taxonomy 3.0.
1617
)

adcom1/feed_type.go

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
package adcom1
22

3-
// FeedType represents types of feeds, typically for audio.
3+
// FeedType represents types of feeds for audio.
44
type FeedType int8
55

6-
// Types of feeds, typically for audio.
6+
// Types of feeds for audio content.
77
const (
8-
FeedMusicService FeedType = 1 // Music Service
9-
FeedRadioBroadcast FeedType = 2 // FM/AM Broadcast
10-
FeedPodcast FeedType = 3 // Podcast
8+
FeedMusicService FeedType = 1 // AOD - Music Streaming Service
9+
FeedRadioBroadcast FeedType = 2 // LIVE - FM/AM broadcast: Live content broadcast over the air but also available via online streaming.
10+
FeedPodcast FeedType = 3 // AOD - Podcast: Original, pre-recorded content distributed as episodes in a series.
11+
FeedCatchUpRadio FeedType = 4 // AOD - Catch-up Radio: recorded segment of a radio show that was originally broadcast live.
12+
FeedWebRadio FeedType = 5 // LIVE - Web Radio: Live content only available via online streaming, not as AM/FM broadcast.
13+
FeedVideoGame FeedType = 6 // MISC - Video Game: Background audio in video games.
14+
FeedTextToSpeech FeedType = 7 // MISC - Text To Speech: Audio books, website plugin that can read article.
1115
)

adcom1/video_placement.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ type VideoPlacement struct {
1212
// integer
1313
// Definition:
1414
// Placement subtype.
15-
// Refer to List: Placement Subtypes - Video.
15+
// Refer to List: Plcmt Subtypes - Video.
1616
PType VideoPlacementSubtype `json:"ptype,omitempty"`
1717

1818
// Attribute:

adcom1/video_placement_subtype.go

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,16 @@
11
package adcom1
22

33
// VideoPlacementSubtype represents types of video placements derived largely from the IAB Digital Video Guidelines.
4+
// To be sent using the placement attribute in the Video object.
5+
// DEPRECATED AS OF OPENRTB 2.6-202303.
6+
// Proposed removal of this list and associated attribute in 2024.
47
type VideoPlacementSubtype int8
58

69
// Types of video placements derived largely from the IAB Digital Video Guidelines.
710
const (
8-
VideoInStream VideoPlacementSubtype = 1 // In-Stream: Played before, during or after the streaming video content that the consumer has requested (e.g., Pre-roll, Mid-roll, Post-roll).
9-
VideoInBanner VideoPlacementSubtype = 2 // In-Banner: Exists within a web banner that leverages the banner space to deliver a video experience as opposed to another static or rich media format. The format relies on the existence of display ad inventory on the page for its delivery.
10-
VideoInArticle VideoPlacementSubtype = 3 // In-Article: Loads and plays dynamically between paragraphs of editorial content; existing as a standalone branded message.
11-
VideoInFeed VideoPlacementSubtype = 4 // In-Feed: Found in content, social, or product feeds.
12-
VideoAlwaysVisible VideoPlacementSubtype = 5 // Interstitial/Slider/Floating: Covers the entire or a portion of screen area, but is always on screen while displayed (i.e. cannot be scrolled out of view).
11+
VideoPlacementInStream VideoPlacementSubtype = 1 // In-Stream: Played before, during or after the streaming video content that the consumer has requested (e.g., Pre-roll, Mid-roll, Post-roll).
12+
VideoPlacementInBanner VideoPlacementSubtype = 2 // In-Banner: Exists within a web banner that leverages the banner space to deliver a video experience as opposed to another static or rich media format. The format relies on the existence of display ad inventory on the page for its delivery.
13+
VideoPlacementInArticle VideoPlacementSubtype = 3 // In-Article: Loads and plays dynamically between paragraphs of editorial content; existing as a standalone branded message.
14+
VideoPlacementInFeed VideoPlacementSubtype = 4 // In-Feed: Found in content, social, or product feeds.
15+
VideoPlacementAlwaysVisible VideoPlacementSubtype = 5 // Interstitial/Slider/Floating: Covers the entire or a portion of screen area, but is always on screen while displayed (i.e. cannot be scrolled out of view).
1316
)

adcom1/video_plcmt_subtype.go

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
package adcom1
2+
3+
// VideoPlacementSubtype represents the the various types of video placements in accordance with updated IAB Digital Video Guidelines.
4+
// To be sent using the plcmt attribute in Video object.
5+
type VideoPlcmtSubtype int8
6+
7+
// Types of video placements derived largely from the IAB Digital Video Guidelines.
8+
const (
9+
// VideoPlcmtInstream represents pre-roll, mid-roll, and post-roll ads that are played
10+
// before, during or after the streaming video content that the consumer has requested.
11+
// Instream video must be set to “sound on” by default at player start, or have
12+
// explicitly clear user intent to watch the video content. While there may be other
13+
// content surrounding the player, the video content must be the focus of the user’s
14+
// visit. It should remain the primary content on the page and the only video player
15+
// in-view capable of audio when playing. If the player converts to floating/sticky
16+
// subsequent ad calls should accurately convey the updated player size.
17+
VideoPlcmtInstream VideoPlcmtSubtype = 1
18+
19+
// VideoPlcmtAccompanyingContent represents pre-roll, mid-roll, and post-roll ads that
20+
// are played before, during, or after streaming video content. The video player loads
21+
// and plays before, between, or after paragraphs of text or graphical content, and
22+
// starts playing only when it enters the viewport. Accompanying content should only
23+
// start playback upon entering the viewport. It may convert to a floating/sticky player
24+
// as it scrolls off the page.
25+
VideoPlcmtAccompanyingContent VideoPlcmtSubtype = 2
26+
27+
// VideoPlcmtInterstitial represents video ads that are played without video content.
28+
// During playback, it must be the primary focus of the page and take up the majority
29+
// of the viewport and cannot be scrolled out of view. This can be in placements like
30+
// in-app video or slideshows.
31+
VideoPlcmtInterstitial VideoPlcmtSubtype = 3
32+
33+
// VideoPlcmtNoContext represents no content / standalone video ads that are played
34+
// without streaming video content. This can be in placements like slideshows, native
35+
// feeds, in-content or sticky/floating.
36+
VideoPlcmtNoContent VideoPlcmtSubtype = 4
37+
)

go.mod

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
1-
module github.com/prebid/openrtb/v18
1+
module github.com/prebid/openrtb/v19
22

33
go 1.16
44

5-
retract v18.0.0 // Published with the wrong module version.
6-
75
require (
86
github.com/onsi/ginkgo v1.16.1
97
github.com/onsi/gomega v1.11.0

0 commit comments

Comments
 (0)