Refund PayPal PAYID using v2 REST API?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have used the Amelia Booking plugin for my one of the site.
I would like to implement the split payment & refund to customer functionality with PayPal payment gateway.
I made one addon for my site which can split the payment using PayPal payout APIs(https://api-m.sandbox.paypal.com/v1/payments/payouts).
Split is working fine but to make a refund I need customer's PayPal details.
So I did below things:
Amelia is storing the transaction information in the database in below format.
{ "data": { "PayerId": "4ABCDEFGHIJKL", "PaymentId": "PAYID-ABCDEFGHIJKLMNO2PQRSTUVW", "transactionReference": "PAYID-ABCDEFGHIJKLMNO2PQRSTUVW" }, "amount": "00.00", "gateway": "payPal", "currency": "USD" }
So from above information I can access "transactionReference" to fetch the customer's details using (https://api-m.sandbox.paypal.com/v1/payments/payment/{transactionReference}) {Jbbess}API call to make refund.
But unfortunately this endpoint is deprecated, so is there anyway to fetch the customer's PayPal data using above information from PayPal v2 API ?
- Labels:
-
Payments REST APIs
Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
- Remove PayPal Pay Later option from paypal checkout page. in PayPal Upgrade Community
- When PayPal gives a code 422 what is the reason? in PayPal Payments Standard
- Cart dropps items, fails to return customer to previous window in PayPal Payments Standard
- Hosted Buttons have changed. How can I now edit the item ID and stock? in PayPal Payments Standard
- Changes to Subscriptions vs Billing Agreements in PayPal Payments Standard