Paypal Subscription JS SDK - RESOURCE_NOT_FOUND Error

TamalDEV
Contributor
Contributor

I was working in paypal subscription process with JS SDK . First of all i have created the plan successfully by PHP SDK And activated it . Then i was trying to implement the subscription process with JS SDK by that plan ID. But some how its not working . If anyone can help me out that will be great.

paypal guide : https://developer.paypal.com/docs/subscriptions/integrate/

This is my code:

 

<div id="paypal-button-container"></div>

<script>    paypal.Buttons({        env: 'sandbox',        createSubscription: function (data, actions) {

            return actions.subscription.create({

                'plan_id': 'P-15T61220BN038602UZQLZ2UI',

            });
        }
        ,        onApprove: function (data, actions) {            alert('You have successfully created subscription ' + data.subscriptionID);
        }
    }).render('#paypal-button-container');
</script>

 

This is the error :

Uncaught Error: Create Subscription Api response error:

{
    "name": "RESOURCE_NOT_FOUND",
    "message": "The specified resource does not exist.",
    "debug_id": "f2628efbed424",
    "details": [
        {
            "issue": "INVALID_RESOURCE_ID",
            "description": "Requested resource ID was not found."
        }
    ],
    "links": [
        {
            "href": "https://developer.paypal.com/docs/api/v1/billing/subscriptions#RESOURCE_NOT_FOUND",
            "rel": "information_link",
            "method": "GET"
        }
    ]
}

Screenshot from 2020-01-22 19-40-08.png

Login to Me Too
1 REPLY 1

randiaz
Member
Member

Apparently this 177 Billion dollar company cannot answer questions about their main operations and product.

 

It is so sad that paypal has such trust and branding when it comes to consumers using it and will lose it due to such simple failure in support.

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.