AuthorizeNet / sample-code-php

This repository contains working code samples which demonstrate php integration with the Authorize.Net API
MIT License
175 stars 197 forks source link

PayPal Express Checkout not updating values on authOnlyContinueTransaction or authCaptureContinueTransaction #174

Open alecsfp opened 2 years ago

alecsfp commented 2 years ago

My code for setTransactionRequest:

$transactionRequestType = new AnetAPI\TransactionRequestType();
$transactionRequestType->setTransactionType('authOnlyContinueTransaction');
$transactionRequestType->setRefTransId($transactionID);
$transactionRequestType->setAmount($total);
$transactionRequestType->setPayment($authorizePayment);
$transactionRequestType->setOrder($order);
$transactionRequestType->setShipping($shipping);
$transactionRequestType->setCustomer($customerData);
$transactionRequestType->setTax($tax);

Steps to reproduce

  1. Start the checkout process with PayPal
  2. Redirected to PayPal to confirm initial subtotal
  3. Select payment, continue
  4. Redirected back to my site to confirm shipping and tax (based off getDetails information from PayPal)
  5. Finish checkout

Expected Outcome: Order amount, Invoice ID, Customer Email, Customer Phone Number, Shipping amount, and Tax amount should be updated with the Authorize.net dashboard and PayPal.

Actual Outcome: Only the order amount was updated with PayPal (thankfully), however the Authorize.net dashboard does not have any of the fields updated (Order amount, Invoice ID, Customer Email, Customer Phone Number, Shipping amount, and Tax amount).

I can capture an order through Authorize's API and it will capture the incorrect amount on PayPal. This could be very scary to my client and I will have to explain to them that PayPal is receiving the correct amount but Authorize.net is not, and they will have to capture the order on PayPal. I will also have to explain to them that all the order data cannot be imported into the dashboard until Authorize.net fixes this.