Skip to content

Commit

Permalink
AdHash Bidder Adapter: minor changes (#7920)
Browse files Browse the repository at this point in the history
We're operating on a com TLD now.
Added publisher in URL for easier routing.
  • Loading branch information
wyand-sp authored Jan 7, 2022
1 parent a07f47d commit f99fdac
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions modules/adhashBidAdapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const VERSION = '1.0';

export const spec = {
code: 'adhash',
url: 'https://bidder.adhash.org/rtb?version=' + VERSION + '&prebid=true',
url: 'https://bidder.adhash.com/rtb?version=' + VERSION + '&prebid=true',
supportedMediaTypes: [ BANNER ],

isBidRequestValid: (bid) => {
Expand Down Expand Up @@ -37,7 +37,7 @@ export const spec = {
var size = validBidRequests[i].sizes[index].join('x');
bidRequests.push({
method: 'POST',
url: url,
url: url + '&publisher=' + validBidRequests[i].params.publisherId,
bidRequest: validBidRequests[i],
data: {
timezone: new Date().getTimezoneOffset() / 60,
Expand Down Expand Up @@ -87,7 +87,7 @@ export const spec = {
cpm: responseBody.creatives[0].costEUR,
ad:
`<div id="${oneTimeId}"></div>
<script src="https://bidder.adhash.org/static/scripts/creative.min.js"></script>
<script src="https://bidder.adhash.com/static/scripts/creative.min.js"></script>
<script>callAdvertiser(${bidderResponse},['${oneTimeId}'],${requestData},${publisherURL})</script>`,
width: request.bidRequest.sizes[0][0],
height: request.bidRequest.sizes[0][1],
Expand Down
4 changes: 2 additions & 2 deletions test/spec/modules/adhashBidAdapter_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ describe('adhashBidAdapter', function () {
);
expect(result.length).to.equal(1);
expect(result[0].method).to.equal('POST');
expect(result[0].url).to.equal('https://bidder.adhash.org/rtb?version=1.0&prebid=true');
expect(result[0].url).to.equal('https://bidder.adhash.com/rtb?version=1.0&prebid=true&publisher=0xc3b09b27e9c6ef73957901aa729b9e69e5bbfbfb');
expect(result[0].bidRequest).to.equal(bidRequest);
expect(result[0].data).to.have.property('timezone');
expect(result[0].data).to.have.property('location');
Expand All @@ -93,7 +93,7 @@ describe('adhashBidAdapter', function () {
const result = spec.buildRequests([ bidRequest ], { gdprConsent: true });
expect(result.length).to.equal(1);
expect(result[0].method).to.equal('POST');
expect(result[0].url).to.equal('https://bidder.adhash.org/rtb?version=1.0&prebid=true');
expect(result[0].url).to.equal('https://bidder.adhash.com/rtb?version=1.0&prebid=true&publisher=0xc3b09b27e9c6ef73957901aa729b9e69e5bbfbfb');
expect(result[0].bidRequest).to.equal(bidRequest);
expect(result[0].data).to.have.property('timezone');
expect(result[0].data).to.have.property('location');
Expand Down

0 comments on commit f99fdac

Please sign in to comment.