8000 New Adapter onetagBidAdapter by onetag-dev · Pull Request #2461 · prebid/Prebid.js · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

New Adapter onetagBidAdapter #2461

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

Merged
merged 4 commits into from
May 7, 2018

Conversation

onetag-dev
Copy link
Contributor
@onetag-dev onetag-dev commented Apr 27, 2018

Type of change

  • Bugfix
  • Feature
  • New bidder adapter
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Does this change affect user-facing APIs or examples documented on http://prebid.org?
  • Other

Description of change

Add new Bid Adapter onetagBidAdapter

  • test parameters for validating bids
{
  bidder: 'onetag',
  params: {
    pubId: 'your_publisher_id',         // required
    type: 'banner',                     // optional. Default 'banner'
  }
}

Be sure to test the integration with your adserver using the Hello World sample page.

  • contact email of the adapter’s maintainer: devops@onetag.com
  • official adapter submission

For any changes that affect user-facing APIs or example code documented on http://prebid.org, please provide:

Other information

@onetag-dev onetag-dev changed the title One tag dev ops patch 1 New Adapter onetagBidAdapter Apr 27, 2018
@bretg bretg requested a review from jaiminpanchal27 April 27, 2018 20:32
@bretg
Copy link
Collaborator
bretg commented Apr 27, 2018

@onetag-dev
Copy link
Contributor Author
onetag-dev commented Apr 30, 2018

We made a PR against https://github.com/prebid/prebid.github.io/tree/master/dev-docs/bidders, can you please check here: prebid/prebid.github.io#740. Thanks

@bretg any news about this PR?

@onetag-dev
Copy link
Contributor Author

@jaiminpanchal27 could you please review the PR and let us know?

Copy link
Collaborator
@jaiminpanchal27 jaiminpanchal27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@OneTagDevOps Left some comments.

I am not receiving bids back with the test params you provided. Please provide valid params.

body.bids.forEach(function(bid) {
bids.push({
requestId: bid.requestId,
cpm: 0.5,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this cpm hardcoded ?

return bids;
}

function getUserSyncs(syncOptions, serverResponses) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getUserSyncs is optional. you can remove if not using.

* Returns information about the page needed by the server in an object to be converted in JSON
* @returns {{location: *, referrer: (*|string), masked: *, wWidth: (*|Number), wHeight: (*|Number), sWidth, sHeight, date: string, timeOffset: number}}
*/
function getPageInfo() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do have bunch of functions in utils for what you are doing here. Can you check if it fits your needs

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this is not a blocking factor? We'd like to see into the util functions in the next release.

const bidObject = {'bids': bids};
const pageInfo = getPageInfo();

const payload = mergeObjects(bidObject, pageInfo);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you use Object.assign() here ? What is the need for this function.

});

const d = serverRequest.data;
const data = JSON.parse(d);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wrap all JSON.parse in try/catch

export const spec = {

code: BIDDER_CODE,
aliases: [],
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove if you don't need alias

@onetag-dev
Copy link
Contributor Author
onetag-dev commented May 5, 2018

@jaiminpanchal27 Thanks for the review, I believe our last commits should have solved all the issues.

@onetag-dev
Copy link
Contributor Author

@jaiminpanchal27 please let us know whether everything works fine

@jaiminpanchal27 jaiminpanchal27 merged commit a348d8f into prebid:master May 7, 2018
@onetag-dev onetag-dev deleted the OneTagDevOps-patch-1 branch May 18, 2018 11:11
@onetag-dev onetag-dev restored the OneTagDevOps-patch-1 branch May 18, 2018 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0