Skip to main content

PayPal Community

  • Dashboard
  • Send and Request
  • Wallet
  • Business
  • Help
Log in

Le forum de Communauté ne sera plus disponible à partir du 30 Juin 2025. Le Forum de la communauté n’est pas disponible pour les nouveaux messages ou les réponses; les articles précédents restent disponibles pour vérification. Afin de connaître les options d’assistance complètes, rendez-vous sur PayPal.com/HelpCenter

Si vous souhaitez signaler du contenu illégal et contraire au Règlement sur les services numériques de l’Union Européenne (DSA), veuillez cliquer ici.

since ‎Oct-17-2019
Country: Italy
Type: Personal
nicklem
nicklem
New Community Member
1
Post
0
Kudos
0
Solutions
Your PayPal Anniversary
Active
View all
Topics nicklem has Participated In
  • Topics nicklem has Participated In
  • Latest Contributions by nicklem

Subscriptions integration - creating a plan ID

by nicklem in REST APIs
‎Oct-17-2019 06:48 AM
‎Oct-17-2019 06:48 AM
Hi,   I'm implementing an on-page payment solution using the Smart Payment Buttons, as described here: https://developer.paypal.com/docs/subscriptions/integrate/   The process described requires to generate a plan ID and pass it to the Buttons createSubscription method.   It is suggested to use curl calls to generate said plan ID, but this may not cut it for us. Our payment amounts will likely vary; it's a plugin meant for recurring donations, with user-selected amounts, so it would be important to be able to generate a plan on the fly.   This on-page solution is meant to replace an older SDK that we were using, https://github.com/paypal/PayPal-PHP-SDK which handled the creation of the plan and activation of the agreement on the server: https://github.com/paypal/PayPal-PHP-SDK/blob/master/sample/billing/CreateBillingAgreementWithPayPal.php   I tried reusing the existing server code to generate a plan on the back-end and pass its ID to the Buttons, but it's not working and I'm getting a 404 response when the button POSTs the plan ID to https://www.sandbox.paypal.com/v1/billing/subscriptions: {issue: "INVALID_RESOURCE_ID", description: "Requested resource ID was not found."}   My question: - Does the PayPal-PHP-SDK play well with the Buttons? Are these two solutions compatible? - If it does not, is there a compatible/updated SDK to generate the plan ID, or am I expected to implement the code on my own, using the API curl calls as reference?   Thanks! ... View more
Paypal Logo
  • Help
  • Contact Us
  • Security
  • Fees
  • © 1999-2025 PayPal, Inc. All rights reserved.
  • Privacy
  • Legal
  • Cookies
  • Policy Updates

The money in your balance is eligible for pass-through FDIC insurance.

The PayPal Cash Mastercard is issued by The Bancorp Bank pursuant to a license by Mastercard International Incorporated. The Bancorp Bank; Member FDIC.

Powered by Khoros