0
votes

Good Afternoon,

We are trying to set up our PayPal Express checkout to process PayPal payments by only authorizing the payments, giving us the option to then be able to either capture or void the payment from within our PayPal account. Have tried changing PAYMENTREQUEST_0_PAYMENTACTION=Authorization, but this doesn't seem to be working. This code only allows the sale/payment to be taken straight away. Any help or suggestions, would be very much appreciated. Here's a link to the original code before we have applied any modifications:

https://github.com/wp-e-commerce/WP-e-Commerce/blob/branch-3.15.1/wpsc-merchants/paypal-express.merchant.php

Kind Regards,

Andy

1
You have to set =Authorization in multiple places, both the SetExpress and DoExpress. It looks like that code will take the value from a config setting in the plugin's setting interfacePreston PHX
Hi Preston. Firstly a big thank you for taking the time to reply with this information. Have set=Authorization in multiple places. Line 688 is set=Sale. Not sure if this needs changing at all. If I set it to authorization here instead of =sale, it throws an error. Kind Regards, AndyAndy

1 Answers

0
votes

In order to do payments of type Authorization you need to:

  1. Have "Authorization" set or evaluated from plugin settings everywhere (including line 688 in the DoExpressCheckoutPayment)

  2. Have your User/PWD/Signature credentials set, using the information from your PayPal account in https://www.paypal.com/api . Uncredentialed API calls can process Sales, but not Authorizations.

If at all possible you really should configure "Authorization" within the plugin's settings, and not by changing any code.