diff --git a/modules/gammaBidAdapter.js b/modules/gammaBidAdapter.js index 8240df3d151..ce5c4ef2544 100644 --- a/modules/gammaBidAdapter.js +++ b/modules/gammaBidAdapter.js @@ -8,6 +8,7 @@ const BIDDER_CODE = 'gamma'; export const spec = { code: BIDDER_CODE, aliases: ['gamma'], + supportedMediaTypes: ['banner', 'video'], /** * Determines whether or not the given bid request is valid. @@ -29,7 +30,7 @@ export const spec = { const gaxObjParams = find(bidRequests, hasParamInfo); return { method: 'GET', - url: '//' + ENDPOINT + '/adx/request?wid=' + gaxObjParams.params.siteId + '&zid=' + gaxObjParams.params.zoneId + '&hb=pbjs&bidid=' + gaxObjParams.bidId + '&urf=' + utils.getTopWindowUrl() + url: '//' + ENDPOINT + '/adx/request?wid=' + gaxObjParams.params.siteId + '&zid=' + gaxObjParams.params.zoneId + '&hb=pbjs&bidid=' + gaxObjParams.bidId + '&urf=' + encodeURIComponent(utils.getTopWindowUrl()) }; }, @@ -50,6 +51,15 @@ export const spec = { } return bids; + }, + + getUserSyncs: function(syncOptions) { + if (syncOptions.iframeEnabled) { + return [{ + type: 'iframe', + url: '//' + ENDPOINT + '/adx/usersync' + }]; + } } } @@ -76,6 +86,7 @@ function newBid(serverBid) { if (serverBid.type == 'video') { Object.assign(bid, { vastXml: serverBid.seatbid[0].bid[0].vastXml, + vastUrl: serverBid.seatbid[0].bid[0].vastUrl, ttl: 3600 }); } diff --git a/modules/gammaBidAdapter.md b/modules/gammaBidAdapter.md index 83c1fdf4853..2902be78492 100644 --- a/modules/gammaBidAdapter.md +++ b/modules/gammaBidAdapter.md @@ -12,7 +12,7 @@ Connects to Gamma exchange for bids. Gamma bid adapter supports Banner, Video. -# Test Parameters +# Test Parameters: For Banner ``` var adUnits = [{ code: 'gamma-hb-ad-123456-0', @@ -29,6 +29,23 @@ var adUnits = [{ }]; ``` +# Test Parameters: For Video +``` +var adUnits = [{ + code: 'gamma-hb-ad-78910-0', + sizes: [[640, 480]], + + // Replace this object to test a new Adapter! + bids: [{ + bidder: 'gamma', + params: { + siteId: '1465446377', + zoneId: '1493280341' + } + }] + + }]; +``` # Ad Unit and Setup: For Testing In order to receive bids please map localhost to (any) test domain.