cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Need to override the taxable amount passed to the cybersource tax calculation service

0 Kudos
260

Below is the code snippet where we are passing abstractOrderModel(CartModel) as a request parameter to the cybersource tax calculation service.

final PaymentServiceRequest request = new TaxRequestBuilder().addParam(ORDER, abstractOrder).setMerchantId(getMerchantId()).build();
    if (abstractOrder instanceof CartModel)
    {
    request.addParam(JdPaymentTransactionCreatorContext.isTransient, Boolean.TRUE);
    }
    final PaymentServiceResult result = paymentServiceExecutor.execute(request);

We are sending only abstract order which contains all the cartentries and total amounts and there is no discounts available. But in the above result object, it returns taxes that are calculated on the discounted prices. where are we specifying the taxable amount to the cybersource service.

Accepted Solutions (0)

Answers (0)