Can you cancel a PayPal automatic payment via API? It's a "Subscription" created via Hosted button.
I have the "Automatic payment number" and the "Transaction ID".
Can you cancel a PayPal automatic payment via API? It's a "Subscription" created via Hosted button.
I have the "Automatic payment number" and the "Transaction ID".
Yes.
Please find this Reference:
Accodring to PAYPAL you can take any of three actions utilizing the ManagerecurringPayments API.
I don't think you can use the API to cancel a payment with Paypal standard payment event pro while only express checkout will work. I tried and got the error message: "Subscription Profiles not supported by Recurring Payment APIs.". You can find out more here.
"A subscription is created via a Website Payments Standard 'Subscribe' button. Before 2009, the subscription profile ID started with S-XXXXXXXX. You are not able to manage these subscriptions via any API calls. After 2009, the subscription profile ID starts with I-XXXXXX. You are able to cancel these subscriptions via the ManageRecurringPaymentsProfileStatus API call."
Was having the same problem and just read it by Robert and it works, you can cancel standard website subscription using API.
I found this thread before finding a solution, and thought I'd come back to give the answer. (C#.Net Solution)
You will require the following nuget packages:
And the following references:
Here's the code: