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

Somo Audience Prebid module. #1833

Merged
merged 5 commits into from Nov 22, 2017
Merged

Somo Audience Prebid module. #1833

merged 5 commits into from Nov 22, 2017

Conversation

eliter
Copy link
Contributor

@eliter eliter commented Nov 15, 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

Official Somo Audience Adapater

  • test parameters for validating bids
{
    bidder: 'somoaudience',
    params: {
        placementId: '22a58cfb0c9b656bff713d1236e930e8'
    }
}

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

  • contact email of the adapter’s maintainer
    [email protected]

  • official adapter submission

Other information

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.

@eliter Thanks for submitting adapter.
For some reason travis checks did not run. Your code is having linting errors. Please run command gulp lint for details.

Also i am not able to validate test params given in md file. Please test your params with https://github.com/prebid/Prebid.js/blob/master/integrationExamples/gpt/hello_world.html page.

}
}

function getReferrer() {
Copy link
Collaborator

Choose a reason for hiding this comment

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

This can be removed and you can use utils.getTopWindowReferrer https://github.com/prebid/Prebid.js/blob/master/src/utils.js#L181

}

function openRtbRequest(bidRequest) {
logError('openRtbRequest', 'ERROR', bidRequest);
Copy link
Collaborator

Choose a reason for hiding this comment

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

What is the purpose of logError here ?

ttl: 360,
creativeId: bidData.crid,
creative_id: bidData.crid,
ad_id: bidId,
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why the same key is used multiple times adId, ad_id and adid ?


aliases: ['somo'],

supportedMediaTypes: ['banner'],
Copy link
Collaborator

Choose a reason for hiding this comment

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

banner is default type. No need to add it.

if(typeof bidRequest != 'undefined' && typeof bidRequest.bidRequest != 'undefined' && typeof bidRequest.bidRequest.bidId != 'undefined') {
bidId = bidRequest.bidRequest.bidId;
}
if (bidResponse) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

your check should be bidResponse.body. You will always receive this object https://github.com/prebid/Prebid.js/blob/master/src/adapters/bidderFactory.js#L284

@eliter
Copy link
Contributor Author

eliter commented Nov 20, 2017

Thank you for the review @jaiminpanchal27.
I have updated the instructions to include a test placement ID that will return a 300x250 ad.
Have a great day!

bids: [{
bidder: 'somoaudience',
params: {
placement: '22a58cfb0c9b656bff713d1236e930e8'
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think this should be placementId

@@ -0,0 +1,98 @@
import {expect} from 'chai';
import {spec} from 'modules/somoaudienceBidAdapter';
import bidManager from 'src/bidmanager';
Copy link
Collaborator

Choose a reason for hiding this comment

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

This line needs to be removed. We have removed bidManager from prebid-1.0.

@eliter
Copy link
Contributor Author

eliter commented Nov 20, 2017

Thanks again @jaiminpanchal27, I have made the requested changes.

@matthewlane matthewlane merged commit 14780fd into prebid:master Nov 22, 2017
dluxemburg pushed a commit to Genius/Prebid.js that referenced this pull request Jul 17, 2018
* Somo Audience Prebid module.

* Requested Changes

* Requested Changes - Wrong var in Documentation

* Requested Change - remove unnecessary import
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.

4 participants