Open
Description
Description
Response to removal of BinLookup, CostEstimateResponse SurChargeType
Steps to reproduce
I have the issue that in version 29 the property SurChargeType was removed from the CostEstimateResponse model of BinLookup. We relied in our logic in the value in the SurChargeType to determine if we any surcharge was applied by checking if the SurChargeType did not contain ZERO.
Now that the property has been removed we need to adapt our code.
Can you explain me what the reasoning was behind the removal of the property? Maybe then I will also know how to adapt my code.
Thank you so much.
Natalie
Actual behavior
No response
Expected behavior
I wasn't expecting this property to not be there.
Code snippet or screenshots (if applicable)
Current code
if (!string.Equals(calculatedFee.SurchargeType, "ZERO", StringComparison.OrdinalIgnoreCase) && calculatedFee.CostEstimateAmount?.Value is not null)
{
retval.Amount = new Sdk.Models.Amount
{
CurrencyCode = calculatedFee.CostEstimateAmount.Currency,
Value = Convert.ToDecimal(calculatedFee.CostEstimateAmount.Value) * 0.01m
};
retval.Percentage = retval.Amount.Value / group.Amount * 100m;
}
Adyen .NET API Library version
31 migrating from 26.1
.NET version
8
Operating System
Linux
Additional context
This issue started after updating to a version after v28