Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dailymotion bid adapter: Clarify the video metadata to provide in each player context #11

Merged
merged 1 commit into from
Mar 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 31 additions & 13 deletions modules/dailymotionBidAdapter.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,32 @@ Please note that failing to set these configuration options will result in the a

# Sample video AdUnit

To allow better targeting, you should provide as much context about the video as possible.
There are two ways of doing this depending on if you're using Dailymotion player or a third party one.

If you are using the Dailymotion player, you should only provide the video `xid` in your ad unit, example:

```javascript
const adUnits = [
{
code: 'test-ad-unit',
mediaTypes: {
video: {
context: 'instream',
playerSize: [1280, 720],
api: [2,7],
xid: 'x123456'
},
}
}
];
```

This will automatically fetch the most up-to-date information about the video.
If you provide any other metadata in addition to the `xid`, they will be ignored.

If you are using a third party video player, you should not provide any `xid` and instead fill the following members:

```javascript
const adUnits = [
{
Expand All @@ -66,31 +92,23 @@ const adUnits = [
tags: 'tag_1,tag_2,tag_3',
title: 'test video',
topics: 'topic_1, topic_2',
xid: 'x123456'
},
},
bids: [{
bidder: "dailymotion",
params: {
video: {
description: 'this is a test video description',
duration: 330,
iabcat2: ['6', '17'],
id: '54321',
lang: 'FR',
private: false,
tags: 'tag_1,tag_2,tag_3',
title: 'test video',
topics: 'topic_1, topic_2, topic_3',
xid: 'x123456'
description: 'overriden video description',
duration: 330
}
}
}]
}
];
```

Following video metadata fields can be added in mediaTypes.video or bids.params.video. If a field exists in both places, it will be overridden by bids.params.video.
Each of the following video metadata fields can be added in mediaTypes.video or bids.params.video.
If a field exists in both places, it will be overridden by bids.params.video.

* `description` - Video description
* `duration` - Video duration in seconds
Expand All @@ -101,7 +119,7 @@ Following video metadata fields can be added in mediaTypes.video or bids.params.
* `tags` - Tags for the video, comma separated
* `title` - Video title
* `topics` - Main topics for the video, comma separated
* `xid` - Dailymotion video identifier (only applicable if using the Dailymotion player), allows better targeting
* `xid` - Dailymotion video identifier (only applicable if using the Dailymotion player)

# Integrating the adapter

Expand Down