Skip to content

Commit

Permalink
Merge pull request #3 from yieldlab/add_multi-format_documentation
Browse files Browse the repository at this point in the history
Add Yieldlab multi-format documentation
  • Loading branch information
kippsterr authored Oct 27, 2021
2 parents 1e1a1bd + 840b1bf commit 3ab20a7
Showing 1 changed file with 91 additions and 61 deletions.
152 changes: 91 additions & 61 deletions modules/yieldlabBidAdapter.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,66 +11,96 @@ Maintainer: [email protected]
Module that connects to Yieldlab's demand sources

# Test Parameters

```javascript
const adUnits = [
{
code: 'banner',
sizes: [ [ 728, 90 ] ],
bids: [{
bidder: 'yieldlab',
params: {
adslotId: '5220336',
supplyId: '1381604',
targeting: {
key1: 'value1',
key2: 'value2'
},
extId: 'abc',
iabContent: {
id: 'some_id',
episode: '1',
title: 'some title',
series: 'some series',
season: 's1',
artist: 'John Doe',
genre: 'some genre',
isrc: 'CC-XXX-YY-NNNNN',
url: 'http://foo_url.de',
cat: [ 'IAB1-1', 'IAB1-2', 'IAB2-10' ],
context: '7',
keywords: ['k1', 'k2'],
live: '0'
}
}
}]
},
{
code: 'video',
sizes: [ [ 640, 480 ] ],
mediaTypes: {
video: {
context: 'instream' // or 'outstream'
}
},
bids: [{
bidder: 'yieldlab',
params: {
adslotId: '5220339',
supplyId: '1381604'
}
}]
},
{
code: 'native',
mediaTypes: {
native: {
// native config
}
},
bids: [{
bidder: 'yieldlab',
params: {
adslotId: '5220339',
supplyId: '1381604'
}
}]
}
];
```
var adUnits = [
{
code: "banner",
sizes: [[728, 90]],
bids: [{
bidder: "yieldlab",
params: {
adslotId: "5220336",
supplyId: "1381604",
targeting: {
key1: "value1",
key2: "value2"
},
extId: "abc",
iabContent: {
id: "some_id",
episode: "1",
title: "some title",
series: "some series",
season: "s1",
artist: "John Doe",
genre: "some genre",
isrc: "CC-XXX-YY-NNNNN",
url: "http://foo_url.de",
cat: ["IAB1-1", "IAB1-2", "IAB2-10"],
context: "7",
keywords: ["k1", "k2"],
live: "0"
}
}
}]
}, {
code: "video",
sizes: [[640, 480]],
mediaTypes: {
video: {
context: "instream" // or "outstream"
}
},
bids: [{
bidder: "yieldlab",
params: {
adslotId: "5220339",
supplyId: "1381604"
}
}]
},
{
code: "native",
mediaTypes: {
native: { }
},
bids: [{
bidder: "yieldlab",
params: {
adslotId: "5220339",
supplyId: "1381604"
}
}]
}
];

# Multi-Format Setup

A general overview of how to set up multi-format ads can be found in the offical Prebid.js docs. See: [show multi-format ads](https://docs.prebid.org/dev-docs/show-multi-format-ads.html)

When setting up multi-format ads with Yieldlab make sure to always add at least one eligible Adslot per given media type in the ad unit configuration.

```javascript
const adUnit = {
code: 'multi-format-adslot',
mediaTypes: {
banner: {
sizes: [ [ 728, 90 ] ]
},
native: {
// native config
}
},
bids: [
// banner Adslot
{ bidder: 'yieldlab', params: { adslotId: '1234', supplyId: '42' } },
// native Adslot
{ bidder: 'yieldlab', params: { adslotId: '2345', supplyId: '42' } }
]
};
```

0 comments on commit 3ab20a7

Please sign in to comment.