authCapture() call is AuthorizationPending. The payment flow for PayPal-based real-time transactions proceeds as follows:
- When a customer clicks the PayPal button on your site, create a
Transactionobject that specifies PayPal as the payment method, and make aTransaction.authCapture()call. - When that call returns, examine the status of the returned
Transactionobject. If the status is not a failure (Cancelled), it isAuthorizationPending, which means that the transaction is in the Subscribe and PayPal systems, and that it requires further action from the customer for completion. - PayPal notifies Subscribe of the successful creation of the Transaction by issuing a PayPal token, which keeps the transaction valid for the next few hours.
- The returned
Transactionobject contains a PayPal-specific status along with a URL, which contains the token information. Redirect the customer to that URL to complete PayPal’s payment process. - Depending on the customer’s success or failure in completing the payment process, PayPal redirects the customer to a Subscribe landing page, along with an indication of whether the payment succeeded or failed. That landing page in turn redirects the customer to a success or failure URL on your site. (Provide Subscribe the success and failure URLs as attributes
returnUrlandcancelUrlof the PayPal payment method for the transaction.) From this page, make a call to Subscribe to finalize the PayPal authorization so that Subscribe can update the status of the transaction. This call requires you to pass in the ID of the transaction, which you can find in the redirected URL. It is value-associated with name:vindicia_vidin the redirect URL.
Use PayPal for a one-time transaction
PaymentMethodFrom this page, finalize the Transaction to update its status in Subscribe.
Authorized, which changes to Captured after Subscribe has finished processing this and other PayPal transactions in a batch.
Note: If you request that PayPal return a referenceId for the Transaction, its paymentMethod may be used for recurring payments. For more information, see Using PayPal for Recurring Billing, and the Using Subscribe with PayPal white paper, available from Vindicia Client Services.
Parent topic:Working with One-Time Transactions
