-
Notifications
You must be signed in to change notification settings - Fork 749
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
New Adapter: Insticator #3806
Merged
Merged
New Adapter: Insticator #3806
Changes from 1 commit
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
dcdddfa
Create a basic insticator adaptor (#3)
shubhamc-ins 56feaa0
Update insticator.yaml
shubhamc-ins db6d2c3
add multi-imps testJson (#6)
shubhamc-ins b751ff9
Instissp 790 create a basic insticator go lang adapter new (#7)
shubhamc-ins 92e859a
update insticator yaml
shubhamc-ins 24d9b39
update insticator bid adaptor | remove validations | fixed interfaces
shubhamc-ins 1f43978
refactor error checks
shubhamc-ins c5b5e24
fix email typo
shubhamc-ins 4dfb854
add invalidparams for insticator
shubhamc-ins 713599c
Merge branch 'master' of github.com:prebid/prebid-server into add-ins…
shubhamc-ins c776f19
update imports to v3 for insticator
shubhamc-ins 4650191
use request clone and add macro
shubhamc-ins e3b07a8
update insticator adaptor:
shubhamc-ins f31772e
refactor- remove unecessary unmarshal
shubhamc-ins 5e78df8
insticator updates:
shubhamc-ins ff2df10
update makeRequest to use requestCopy as reference
shubhamc-ins fdcdc59
update and add test cases for insticator
shubhamc-ins d8f3ca3
update makeImps and populatepublisherid, remove multiple calls, remov…
shubhamc-ins f0d12f0
update adaptor and test cases for headers validation
shubhamc-ins File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,14 +25,24 @@ | |
"publisher": { | ||
"id": "test-publisher-id" | ||
} | ||
}, | ||
"device": { | ||
"ipv6": "2001:0db8:85a3:0000:0000:8a2e:0370:7334", | ||
"ip": "1.22.22.1", | ||
"ua": "Mozilla/5.0 (Linux; Android 8.0.0; SM-G960F Build/R16NW) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.84 Mobile Safari/537.36" | ||
} | ||
}, | ||
|
||
"httpCalls": [ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please verify the headers are set correctly in this test since some of them are derived from the device object. You can do so like this:
|
||
{ | ||
"expectedRequest": { | ||
"uri": "https://ex.ingage.tech/v1/prebidserver", | ||
"uri": "https://insticator.example.com/v1/pbs", | ||
"body": { | ||
"device": { | ||
"ip": "1.22.22.1", | ||
"ipv6": "2001:0db8:85a3:0000:0000:8a2e:0370:7334", | ||
"ua": "Mozilla/5.0 (Linux; Android 8.0.0; SM-G960F Build/R16NW) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.84 Mobile Safari/537.36" | ||
}, | ||
"ext": { | ||
"insticator": { | ||
"caller": [ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{ | ||
"mockBidRequest": { | ||
"id": "test-request-id", | ||
"imp": [ | ||
{ | ||
"id": "test-imp-id", | ||
"banner": { | ||
"format": [{"w": 728, "h": 90}] | ||
}, | ||
"ext": { | ||
"bidder": { | ||
"adUnitId": "fake-site-id", | ||
"publisherId": "test-publisher-id" | ||
} | ||
} | ||
} | ||
], | ||
"site": { | ||
"publisher": { | ||
"id": "test-publisher-id" | ||
} | ||
} | ||
}, | ||
|
||
"httpCalls": [ | ||
{ | ||
"expectedRequest": { | ||
"uri": "https://insticator.example.com/v1/pbs", | ||
"body": { | ||
"ext": { | ||
"insticator": { | ||
"caller": [ | ||
{ | ||
"name": "Prebid-Server", | ||
"version": "n/a" | ||
} | ||
] | ||
} | ||
}, | ||
"id": "test-request-id", | ||
"imp": [ | ||
{ | ||
"id":"test-imp-id", | ||
"banner": { | ||
"format": [{"w": 728, "h": 90}] | ||
}, | ||
"ext": { | ||
"insticator": { | ||
"adUnitId": "fake-site-id", | ||
"publisherId": "test-publisher-id" | ||
} | ||
} | ||
} | ||
], | ||
"site": { | ||
"publisher": { | ||
"id": "test-publisher-id" | ||
} | ||
} | ||
}, | ||
"impIDs":["test-imp-id"] | ||
}, | ||
"mockResponse": { | ||
"status": 204, | ||
"body": {} | ||
} | ||
} | ||
], | ||
"expectedBidResponses": [] | ||
} | ||
|
120 changes: 120 additions & 0 deletions
120
adapters/insticator/insticatortest/supplemental/app-pubid-absent.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,120 @@ | ||
{ | ||
"mockBidRequest": { | ||
"id": "test-request-id", | ||
"imp": [ | ||
{ | ||
"id": "test-imp-id", | ||
"banner": { | ||
"format": [{"w": 728, "h": 90}] | ||
}, | ||
"ext": { | ||
"bidder": { | ||
"adUnitId": "fake-app-id", | ||
"publisherId": "test-publisher-id" | ||
} | ||
} | ||
} | ||
], | ||
"app": { | ||
"id": "test-app-id", | ||
"bundle": "test-app.com" | ||
} | ||
}, | ||
|
||
"httpCalls": [ | ||
{ | ||
"expectedRequest": { | ||
"uri": "https://insticator.example.com/v1/pbs", | ||
"body": { | ||
"ext": { | ||
"insticator": { | ||
"caller": [ | ||
{ | ||
"name": "Prebid-Server", | ||
"version": "n/a" | ||
} | ||
] | ||
} | ||
}, | ||
"id": "test-request-id", | ||
"imp": [ | ||
{ | ||
"id":"test-imp-id", | ||
"banner": { | ||
"format": [{"w": 728, "h": 90}] | ||
}, | ||
"ext": { | ||
"insticator": { | ||
"adUnitId": "fake-app-id", | ||
"publisherId": "test-publisher-id" | ||
} | ||
} | ||
} | ||
], | ||
"app": { | ||
"id": "test-app-id", | ||
"bundle": "test-app.com", | ||
"publisher": { | ||
"id": "test-publisher-id" | ||
} | ||
} | ||
}, | ||
"impIDs":["test-imp-id"] | ||
}, | ||
"mockResponse": { | ||
"status": 200, | ||
"body": { | ||
"id": "test-request-id", | ||
"seatbid": [ | ||
{ | ||
"seat": "insticator", | ||
"bid": [{ | ||
"id": "8ee514f1-b2b8-4abb-89fd-084437d1e800", | ||
"impid": "test-imp-id", | ||
"price": 0.500000, | ||
"adm": "some-test-ad", | ||
"crid": "crid_10", | ||
"h": 90, | ||
"w": 728, | ||
"mtype": 1, | ||
"ext": { | ||
"insticator": { | ||
"mediaType": "banner" | ||
} | ||
} | ||
}] | ||
} | ||
], | ||
"cur": "USD" | ||
} | ||
} | ||
} | ||
], | ||
|
||
"expectedBidResponses": [ | ||
{ | ||
"currency": "USD", | ||
"bids": [ | ||
{ | ||
"bid": { | ||
"id": "8ee514f1-b2b8-4abb-89fd-084437d1e800", | ||
"impid": "test-imp-id", | ||
"price": 0.5, | ||
"adm": "some-test-ad", | ||
"crid": "crid_10", | ||
"w": 728, | ||
"h": 90, | ||
"mtype": 1, | ||
"ext": { | ||
"insticator": { | ||
"mediaType": "banner" | ||
} | ||
} | ||
}, | ||
"type": "banner" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
|
29 changes: 29 additions & 0 deletions
29
adapters/insticator/insticatortest/supplemental/bad-imp-ext.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
{ | ||
"mockBidRequest": { | ||
"id": "test-request-id", | ||
"imp": [ | ||
{ | ||
"id": "test-imp-id", | ||
"banner": { | ||
"format": [{"w": 728, "h": 90}] | ||
}, | ||
"ext": { | ||
"bidder": "invalid ext" | ||
} | ||
} | ||
], | ||
"site": { | ||
"publisher": { | ||
"id": "test-publisher-id" | ||
} | ||
} | ||
}, | ||
|
||
"expectedMakeRequestsErrors": [ | ||
{ | ||
"value": "expect { or n, but found \"", | ||
"comparison": "literal" | ||
} | ||
] | ||
} | ||
|
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick: you should be able to delete the parentheses