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

Improve Digital Bid Adapter: Bid floor is sent in USD when possible #20

Merged
merged 5 commits into from
Oct 17, 2024

Conversation

lyubomirshishkov
Copy link
Collaborator

@lyubomirshishkov lyubomirshishkov commented Oct 2, 2024

Type of change

  • Updated bidder adapter

Description of change

Bid Floors are currently always sent in their original currency to Improve Digital, which is problematic in cases when the currency is not supported by the SSP. The proposed change converts all Bid Floors which are not already in USD to USD when possible. If the Bid Floor cannot be converted by Improve Digital's Bid Adapter the Bid Floor is sent as is.

Other information

Original Issue in prebid/Prebid.js - prebid#12238

* **Type:** Fix
* **Scope:** improvedigitalBidAdapter
* **Subject:** Bid floors are always converted to USD.
* **Details:**
* Adds `DEFAULT_CURRENCY` variable which is set to USD
* Adds `convertBidFloorCurrency` function which in used to convert the bid floor when both `imp.bidfloor` and `imp.bidfloorcur` are present, and `imp.bidfloorcur` is not equal to the adapter's `DEFAULT_CURRENCY`;
* **Breaks:** N/A
…ed to USD;

* Removes rounding of bid floor when converting its currency to USD;
@lyubomirshishkov lyubomirshishkov changed the title Improve Digital - Bid floor is always sent in USD Improve Digital - Bid floor is sent in USD when possible Oct 2, 2024
@lyubomirshishkov lyubomirshishkov changed the title Improve Digital - Bid floor is sent in USD when possible Improve Digital Bid Adapter: Bid floor is sent in USD when possible Oct 2, 2024
@lyubomirshishkov lyubomirshishkov marked this pull request as ready for review October 2, 2024 14:45
modules/improvedigitalBidAdapter.js Show resolved Hide resolved
modules/improvedigitalBidAdapter.js Outdated Show resolved Hide resolved
* remove redundant checks for type and NaN from `convertBidFloorCurrency` function
@jbartek25 jbartek25 merged commit cb54dce into master Oct 17, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants