500 INTERNAL_SERVICE_ERROR while Cancel Subscription

NagarajuRaghava
Contributor
Contributor

Implementing PayPal Subscriptions:

  1. Subscriptions via PayPal Payment standard.
  2. Cancel Subscriptions via PayPal API (Without SDK).

I am facing issues while cancelling the Subscription/Recurring Payment via PayPal API. I was able to get the AccessToken via the API. Below is the API for cancelling subscriptions:

curl -v -X POST https://api.sandbox.paypal.com/v1/payments/billing-agreements/I-1TJ3GAGG82Y9/cancel \ -H "Content-Type: application/json" \ -H "Authorization: Bearer Access-Token" \ -d '{ "note": "Canceling the profile." }'

I get the following response everytime:

{
    "name": "INTERNAL_SERVICE_ERROR",
    "message": "An internal service error occurred.",
    "information_link": "https://developer.paypal.com/webapps/developer/docs/api/#INTERNAL_SERVICE_ERROR",
    "debug_id": "c121fd139b91b"
}

Can someone assure me if i am on the right track & what might be the cause for the issue. Thanks!

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.