-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Add StickyAdsTV Bidder adapter #916
Conversation
Please fix test failures. |
Done by merging in master. |
src/adapters/stickyadstv.js
Outdated
|
||
var script = "<script type='text/javascript'>"+ | ||
|
||
"var vast = window.top.stickyadstv_cache[\""+placementCode+"\"];"+ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use of window.top
will not work when running in a cross domain iframe, which is increasingly more common. Delivery of creatives into a SafeFrame, for example, or when integrating Prebid with an AMP Page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, I'll remove it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a way I can get the context where my script has been loaded before the bid?
When I use "adloader.loadScript" I load a full API that I would need to access again inside the "Ad" (html/javascript loaded if my bid wins) which is loaded inside an iframe.
That is what "window.top" was for.
src/adapters/stickyadstv.js
Outdated
var bidObject; | ||
if(valid && priceData) { | ||
// valid bid response | ||
bidObject = bidfactory.createBid(1); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pass in the bid requested here so the request/response pair can be matched.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How? the documentation says to use "var bidObject = bidfactory.createBid(1);"
see: http://prebid.org/dev-docs/bidder-adaptor.html
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, seen an example in bidder adaptor AppNexus.js:
bidfactory.createBid(1, bidObj);
You should add it in the documentation, I didn't find an API reference for the bidfactory.
(did I miss it?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, thanks, created an issue on docs repo:
prebid/prebid.github.io#168
src/adapters/stickyadstv.js
Outdated
} | ||
else { | ||
// invalid bid response | ||
bidObject = bidfactory.createBid(2); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pass in the bid requested here as well.
@guillaume-sticky please let us know the status on this, thanks. |
I'm sorry I was quite busy those days. I'll push the requested modifications soon. |
Updated with requested modifications. |
This appears to be a video adapter. Please have a look at the docs on video support: http://prebid.org/dev-docs/show-video-with-a-dfp-video-tag.html This PR can be updated to incorporate the video config as described. |
Can you be more specific on what is needed here ? We don't want to use your video player example as we are already setup our player as we need it. I guess I have to declare the supported media type video ? Is that it ? |
@guillaume-sticky yes and also set the |
@guillaume-sticky This format appears to be in banner video, is that correct? |
Yes it is, we never return a VAST response, we give the html ad in a bid object to be displayed in banner. So "supportedMediaTypes" : ["video"] will be enough ? |
@guillaume-sticky This is good as-is, thanks for the contribution! |
Thank you for adding stickyadstv bidder adapter. I wonder if we should worry about the 20$ CPM cap? As we could see some CPM over 20$ in our video platform. And if we need to work around this, can we do it from inside the bidder adapter or is the "custom price bucket" something the publisher needs to setup? |
* add stickyadsTV bidder adapter * init unit test file * ad some unit tests * fix unit test on ad format with parameters * add some unit tests * add unit tests on getBid method * add some test cases in unit tests * minor fix on component id tag. * remove adapters-sticky.json test file * use top most accessible window instead of window.top * Pass in the bid request in the createBid call. * use top most accessible window instead of window.top * add unit tests * update unit tests * fix unit test. * fix CI build
…ebid-official-0.19.0 to release/1.14.0 * commit 'b13f7ba7ee8b3c168dc0af7c8bfc94747d017e70': (34 commits) Add changelog entry. Prebid 0.19.0 Release check truthiness of adUnitCode (prebid#990) fixed exception when refreshing individual Ad Units and bidder responds slowly (prebid#989) Stub pixel drop to prevent network request in test (prebid#988) Updating Komoona adapter to support future Prebid requirements (prebid#974) Use stable version of Chrome (prebid#984) Revert to running browser tests in Travis (prebid#983) Fix issue with appnexusAst sending `user` object in the wrong place. (prebid#980) Integrate Browserstack tests into Travis CI build (prebid#839) Add StickyAdsTV Bidder adapter (prebid#916) Stronger xdomain checks (prebid#971) added matomy as an alias for appnexus (prebid#850) Added 152Media Appnexus Alias (prebid#952) OpenX Adapter: Handles fallback ads correctly as a no fill (prebid#39) (prebid#963) Use package dependencies for ES6 Array shims (prebid#962) Make x-domain safe frame example work out of the box (prebid#955) added usersync for adkernel adapter (prebid#951) Rubicon adapter: add a floor variable (prebid#964) Added Lifestreet adapter. (prebid#965) ...
…14.0 to master * commit 'c008f3f531ae3409f4a16bf03470d84e82aead0e': (35 commits) Add adapters in aolPartnersIds.json. Add changelog entry. Prebid 0.19.0 Release check truthiness of adUnitCode (prebid#990) fixed exception when refreshing individual Ad Units and bidder responds slowly (prebid#989) Stub pixel drop to prevent network request in test (prebid#988) Updating Komoona adapter to support future Prebid requirements (prebid#974) Use stable version of Chrome (prebid#984) Revert to running browser tests in Travis (prebid#983) Fix issue with appnexusAst sending `user` object in the wrong place. (prebid#980) Integrate Browserstack tests into Travis CI build (prebid#839) Add StickyAdsTV Bidder adapter (prebid#916) Stronger xdomain checks (prebid#971) added matomy as an alias for appnexus (prebid#850) Added 152Media Appnexus Alias (prebid#952) OpenX Adapter: Handles fallback ads correctly as a no fill (prebid#39) (prebid#963) Use package dependencies for ES6 Array shims (prebid#962) Make x-domain safe frame example work out of the box (prebid#955) added usersync for adkernel adapter (prebid#951) Rubicon adapter: add a floor variable (prebid#964) ...
Type of change
Description of change
Add StickyAdsTV Bidder Adaptor
Other information
Contact: [email protected]
Test page: http://sandbox.stickyadstv.com/qa/prebid.html