From cf0254550f494225e806fd32c21c699713a5131b Mon Sep 17 00:00:00 2001 From: Kevin Siow Date: Thu, 11 Jan 2024 10:48:02 +0100 Subject: [PATCH 1/3] Dailymotion Bid Adaptor: initial release --- dev-docs/bidders/dailymotion.md | 80 +++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 dev-docs/bidders/dailymotion.md diff --git a/dev-docs/bidders/dailymotion.md b/dev-docs/bidders/dailymotion.md new file mode 100644 index 0000000000..1b53cd5c0d --- /dev/null +++ b/dev-docs/bidders/dailymotion.md @@ -0,0 +1,80 @@ +--- +layout: bidder +title: Dailymotion +description: Dailymotion Prebid Bidder Adapter +pbjs: true +pbs: false +biddercode: dailymotion +media_types: video +gvl_id: 573 +tcfeu_supported: true +usp_supported: true +coppa_supported: true +deals_supported: true +floors_supported: true +sidebarType: 1 +safeframes_ok: true +ortb_blocking_supported: false +--- + +### Registration + +To use the adapter with any non-test request, you first need to ask an API key from Dailymotion. Please contact us through **DailymotionPrebid.js@dailymotion.com**. + +This API key will ensure proper identification of your inventory and allow you to get real bids. + +# Configuration options + +Before calling this adapter, you need to set its configuration with a call to setConfig like this: + +``` +config.setConfig({ + dailymotion: { + api_key: 'test_api_key', + position: 'test_position', + xid: 'x123456' + } +}); +``` + +This call must be made before each auction. Here's a description of each parameter: +* `api_key` is your publisher API key. For testing purpose, you can use "dailymotion-testing". +* `position` parameter is the ad position in the video and must either be "preroll", "midroll" or "postroll". +* `xid` is the Dailymotion video identifier and should be provided to have better contextual data and higher fillrate. + +# Test Parameters + +By setting the following configuration options, you'll get a constant response to any request to validate your adapter integration: + +``` +config.setConfig({ + dailymotion: { + api_key: 'dailymotion-testing', + position: 'preroll' + } +}); +``` + +Please note that failing to set these configuration options will result in the adapter not bidding at all. + +## Sample video AdUnit + +``` +const adUnits = [ + { + code: 'test-ad-unit', + mediaTypes: { + video: { + context: 'instream', + playerSize: [1280, 720], + }, + }, + bids: [{ + bidder: "dailymotion", + params: {} + }] + } +]; +``` + + From f178b4976e0218e0605f3a4a601cdbf916c609e9 Mon Sep 17 00:00:00 2001 From: Aditi Chaudhary Date: Mon, 22 Jan 2024 17:41:10 +0100 Subject: [PATCH 2/3] .md file lint issue resolved --- dev-docs/bidders/dailymotion.md | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/dev-docs/bidders/dailymotion.md b/dev-docs/bidders/dailymotion.md index 1b53cd5c0d..598f836772 100644 --- a/dev-docs/bidders/dailymotion.md +++ b/dev-docs/bidders/dailymotion.md @@ -19,7 +19,7 @@ ortb_blocking_supported: false ### Registration -To use the adapter with any non-test request, you first need to ask an API key from Dailymotion. Please contact us through **DailymotionPrebid.js@dailymotion.com**. +To use the adapter with any non-test request, you first need to ask an API key from Dailymotion. Please contact us through . This API key will ensure proper identification of your inventory and allow you to get real bids. @@ -27,7 +27,7 @@ This API key will ensure proper identification of your inventory and allow you t Before calling this adapter, you need to set its configuration with a call to setConfig like this: -``` +```javascript config.setConfig({ dailymotion: { api_key: 'test_api_key', @@ -38,6 +38,7 @@ config.setConfig({ ``` This call must be made before each auction. Here's a description of each parameter: + * `api_key` is your publisher API key. For testing purpose, you can use "dailymotion-testing". * `position` parameter is the ad position in the video and must either be "preroll", "midroll" or "postroll". * `xid` is the Dailymotion video identifier and should be provided to have better contextual data and higher fillrate. @@ -46,7 +47,7 @@ This call must be made before each auction. Here's a description of each paramet By setting the following configuration options, you'll get a constant response to any request to validate your adapter integration: -``` +```javascript config.setConfig({ dailymotion: { api_key: 'dailymotion-testing', @@ -59,7 +60,7 @@ Please note that failing to set these configuration options will result in the a ## Sample video AdUnit -``` +```javascript const adUnits = [ { code: 'test-ad-unit', @@ -76,5 +77,3 @@ const adUnits = [ } ]; ``` - - From 9a86defcf19444a1741517b31a234d410732a791 Mon Sep 17 00:00:00 2001 From: Kevin Siow Date: Fri, 1 Mar 2024 14:52:59 +0100 Subject: [PATCH 3/3] Dailymotion Bid Adaptor: add documentation for video metadata support --- dev-docs/bidders/dailymotion.md | 74 +++++++++++++++++++++++++-------- 1 file changed, 56 insertions(+), 18 deletions(-) diff --git a/dev-docs/bidders/dailymotion.md b/dev-docs/bidders/dailymotion.md index 598f836772..bac218a0a0 100644 --- a/dev-docs/bidders/dailymotion.md +++ b/dev-docs/bidders/dailymotion.md @@ -25,40 +25,41 @@ This API key will ensure proper identification of your inventory and allow you t # Configuration options -Before calling this adapter, you need to set its configuration with a call to setConfig like this: +Before calling this adapter, you need to set its configuration with a call like this: ```javascript -config.setConfig({ - dailymotion: { - api_key: 'test_api_key', - position: 'test_position', - xid: 'x123456' - } +pbjs.setBidderConfig({ + bidders: ["dailymotion"], + config: { + dailymotion: { + api_key: 'fake_api_key', + } + } }); ``` -This call must be made before each auction. Here's a description of each parameter: +This call must be made before the first auction to allow proper authentication with our servers. -* `api_key` is your publisher API key. For testing purpose, you can use "dailymotion-testing". -* `position` parameter is the ad position in the video and must either be "preroll", "midroll" or "postroll". -* `xid` is the Dailymotion video identifier and should be provided to have better contextual data and higher fillrate. +`api_key` is your publisher API key. For testing purpose, you can use "dailymotion-testing". # Test Parameters By setting the following configuration options, you'll get a constant response to any request to validate your adapter integration: ```javascript -config.setConfig({ - dailymotion: { - api_key: 'dailymotion-testing', - position: 'preroll' - } +pbjs.setBidderConfig({ + bidders: ["dailymotion"], + config: { + dailymotion: { + api_key: 'dailymotion-testing' + } + } }); ``` Please note that failing to set these configuration options will result in the adapter not bidding at all. -## Sample video AdUnit +# Sample video AdUnit ```javascript const adUnits = [ @@ -68,12 +69,49 @@ const adUnits = [ video: { context: 'instream', playerSize: [1280, 720], + api: [2,7], + description: 'this is a video description', + duration: 556, + iabcat2: 'test_cat', + id: '54321', + lang: 'FR', + private: false, + tags: 'tag_1,tag_2,tag_3', + title: 'test video', + topics: 'topic_1, topic_2', + xid: 'x123456' }, }, bids: [{ bidder: "dailymotion", - params: {} + params: { + video: { + description: 'this is a test video description', + duration: 330, + iabcat2: 'test_cat', + 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' + } + } }] } ]; ``` + +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 +* `iabcat2` - Video IAB category +* `id` - Video unique ID in host video infrastructure +* `lang` - ISO 639-1 code for main language used in the video +* `private` - True if video is not publicly available +* `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) and allows better targeting