Passing Address Info Back to PayPal using DoReferenceTransaction (paypal express checkout)

quinnf4
Contributor
Contributor

Hello,

 

Is it possible to send the customer's billing/shipping information to paypal when doing reference transactions?

Being able to have the customer's address information makes it easier to provide support and to fight purchase disputes.

 

Currently: trying to pass address info like this 

$params->REFERENCEID = $referenceId;
$params->PAYMENTACTION = 'sale';
$companyId = App::getInstance()->getCompanyId();
$params->STREET = $order->address1;
if (isset($order->address2))
$params->STREET2 = $order->address2;
$params->CITY = $order->city;
$params->STATE = $order->state;
$params->COUNTRYCODE = $order->country;
$params->ZIP = $order->postalCode;
$params->SHIPTONAME = $order->shipFirstName . ' ' . $order->shipLastName;
$params->SHIPTOSTREET = $order->shipAddress1;
if (isset($order->shipAddress2))
$params->SHIPTOSTREET2 = $order->shipAddress2;
$params->SHIPTOCITY = $order->shipCity;
$params->SHIPTOSTATE = $order->shipState;
$params->SHIPTOCOUNTRY = $order->shipCountry;
$params->SHIPTOZIP = $order->shipPostalCode;
$params->SHIPTOPHONENUM = $order->phoneNumber;

 

but when processing transactions I am faced with this error:  "Invalid credit card details section must be empty you cannot specify credit card infomartion in a non ddirect payment ddc referece transaction" though I am not passing CC details

 

 

If this is possible can someone please guide me to the proper documentation to achieve this?

 

 

Login to Me Too
0 REPLIES 0

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.