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

Add new adapter ServerBid (by Adzerk) #1024

Merged
merged 8 commits into from
Mar 15, 2017

Conversation

LarryTurtis
Copy link
Contributor

@LarryTurtis LarryTurtis commented Mar 2, 2017

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
  • Other

Description of change

Add ServerBid (by Adzerk) adapter.

  • test parameters for validating bids
{
            bidder: 'serverbid',
            params: {
                networkId: 9969,
                siteId: 730181,
            }
        }

Other information

@LarryTurtis LarryTurtis changed the title Serverbid Add new adapter ServerBid (by Adzerk) Mar 2, 2017
@jaiminpanchal27 jaiminpanchal27 self-assigned this Mar 2, 2017
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.

@GaryKertis Please check the comments. Thanks.

placements: [],
time: Date.now(),
user: {},
url: document.location.href,
Copy link
Collaborator

Choose a reason for hiding this comment

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

I would recommend using these function utils.getTopWindowUrl() and utils.getTopWindowLocation()

placementCode = bidObj.placementCode;

//prepare a no bid response.
bid = bidfactory.createBid(2, bidObj);
Copy link
Collaborator

Choose a reason for hiding this comment

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

Move this to else part. In case you get result, this code is of no use.


var bids = params.bids || [];
for (var i = 0; i < bids.length; i++) {

Copy link
Collaborator

Choose a reason for hiding this comment

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

remove extra line breaks in this file.


var baseAdapter = Adapter.createNew('serverbid');

var BASE_URI = '//e.serverbid.com/api/v2';
Copy link
Collaborator

Choose a reason for hiding this comment

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

Using const/let is recommended.

@LarryTurtis
Copy link
Contributor Author

@jaiminpanchal27 I have incorporated these changes. Please let me know if there are any other concerns. Thanks!

@jaiminpanchal27
Copy link
Collaborator

@GaryKertis utils.getTopWindowUrl is a function. Check line 54 in serverbid.js

@LarryTurtis
Copy link
Contributor Author

Oops. @jaiminpanchal27 fixed.

@jaiminpanchal27
Copy link
Collaborator

LGTM. Thanks @GaryKertis

@jaiminpanchal27 jaiminpanchal27 merged commit 8e06100 into prebid:master Mar 15, 2017
@jaiminpanchal27
Copy link
Collaborator

This is merged into master. Please submit a PR to the docs repo to add a file for your adapter to the bidders directory so your adapter's params will appear on the bidders page. Thank you for contributing

outoftime pushed a commit to Genius/Prebid.js that referenced this pull request Mar 20, 2017
* Wrote initial call logic to make request to serverbid.

* Add initial bid response handling logic.

* Handle requests and responses, successfully pass to add server, write initial tests.

* Clean up pricing and fix tests.

* Enable request credentials.

* JSHint and JSCS

* Incorporate code review comments.

* Add function invocation to getTopWindowUrl
outoftime pushed a commit to Genius/Prebid.js that referenced this pull request Mar 20, 2017
…built

* 'master' of https://github.com/prebid/Prebid.js:
  Add GourmetAds AppNexus Alias (prebid#1057)
  fix issue calling `requestBids();` (prebid#1058)
  explicit win url response format as pixel (prebid#1001)
  OpenX Adapter: Correctly gets the page domain for cross-domain iframes (prebid#1027)
  better http/s support (prebid#1010)
  Add a new generated field transactionId to each adunits. (prebid#1040)
  Update readme (prebid#1053)
  PulsePoint Lite adapter (prebid#1016)
  Add new adapter ServerBid (by Adzerk) (prebid#1024)
  Fix Mantis tests in negative timezone (prebid#1049)
  Add deal id handling (prebid#1044)
  sanitize bidderRequest to rubicon adapter to ensure accountId is sent (prebid#1030)
  Bidfluence Adapter (prebid#1023)
  Update uglify-js version (prebid#1041)
  Add dev dependencies.
  hb_adid should be uppercase in all cases (prebid#1037)
  Add TapSense Header Bidding Adapter and tests (prebid#1004)
  iOS Referrer fix (prebid#996)
  Change identification of JavaScript user matching (prebid#1022)
  Fixed mixed tabs/spaces in wideorbit adapter (prebid#1031)
dluxemburg pushed a commit to Genius/Prebid.js that referenced this pull request Jul 17, 2018
* Wrote initial call logic to make request to serverbid.

* Add initial bid response handling logic.

* Handle requests and responses, successfully pass to add server, write initial tests.

* Clean up pricing and fix tests.

* Enable request credentials.

* JSHint and JSCS

* Incorporate code review comments.

* Add function invocation to getTopWindowUrl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants