-
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
Create undertone udapter #1850
Create undertone udapter #1850
Conversation
and adapter fixes
# remove console.log in adapter
and relevant unit tests
change request that will be sent wait for different field in response update unit tests
I saw that this error raised while running 'gulp run-tests' HeadlessChrome 0.0.0 (Linux 0.0.0) MarsMedia adapter implementation "before each" hook FAILED I'm not getting this error locally , moreover, our pull request contains undertone adapter only , nothing that is related to Marsmedia . can you please help? |
@gilpat We have some flakky tests. I've restarted the job to see if it passes |
Thanks , |
Hi , |
@gilpat it's passing now |
Hello Matt, |
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.
@gilpat Thanks for submitting these changes. There are a few things that should be reviewed/updated, but mostly it seems good.
Please take a look at the specifics below and let me know if there are any questions. Thanks!
}; | ||
}, | ||
interpretResponse: function(serverResponse, request) { | ||
const bids = []; |
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.
#1748 changed the first argument of interpretResponse
to:
{
body: responseBody,
headers: {
get: function(header) { /* returns a header from the HTTP response */ }
}
}
so adding something like
serverResponse = serverResponse.body;
just below this line, or however you'd prefer to grab the body, and updating corresponding tests if needed should get this back to working properly
modules/undertoneBidAdapter.js
Outdated
if (bidRes.ad && bidRes.cpm > 0) { | ||
const bid = { | ||
requestId: bidRes.bidRequestId, | ||
bidderCode: BIDDER_CODE, |
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.
bidderCode
will be set by bidderFactory
automatically now, this line can be dropped
modules/undertoneBidAdapter.js
Outdated
const payload = { | ||
'x-ut-hb-params': [] | ||
}; | ||
const timeout = window.PREBID_TIMEOUT || null; |
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.
Can you clarify why the timeout value is needed for the bid object passed to your system? Is this a reporting metric or actively used by the system?
Prebid data can't be accessed directly through the window object. So we want to understand the need to help figure out some alternatives around supplying this information (if it's really needed).
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.
Our API enable us to pass the timeout value to the server, so we can response with nobid if we are not able to respond within this time frame. This should improve the user experience and reduce load from our server.
Is there another way to get the timeout you're using? Or maybe there is a constant value you're using? If so, we can just add it here.
@danagutkind |
@mkendall07 |
Ok np. Just wanted to give you the heads up. Possibly next week depending on things shake out. |
@mkendall07 |
modules/undertoneBidAdapter.js
Outdated
import { registerBidder } from 'src/adapters/bidderFactory'; | ||
|
||
const BIDDER_CODE = 'undertone'; | ||
const URL = '//hb.undertone.com/hb'; // //ads.undertone.com/hb |
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.
What's //ads.undertone.com/hb
? Could remove this comment
@gilpat We are seeing a CORS related error when testing the adapter. Are you sure the test params are valid and work on the hello world test page? |
After retesting this morning, we're able to see the test ad with the hello word test page. LGTM |
@mkendall07 |
@mkendall07 Hi Matt Thank you, |
What do you mean live? This is merged and available in the 0.34 release I believe |
Thank you very much. |
Type of change
Description of change
new undertone bidder adapter.
Be sure to test the integration with your adserver using the Hello World sample page.
Other information