Paypal basic integration fails to call the onApprove hook
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm learning to use this api and discovering really fast that most of tutorials on the google and youtube are out of date... That's ok, just need to shove my face on the docs and push trough, that's normal, but when even the basic integration on the docs fails without any erros that's kind bad.
Here is the code that I'm using:
https://developer.paypal.com/docs/checkout/integrate/#
paypal.Buttons({ createOrder: function (data, actions) { console.log('creating order') // Set up the transaction return actions.order.create({ purchase_units: [{ amount: { value: '0.01' } }] }) }, onApprove: function (data, actions) { console.log('order aproved') // Capture the funds from the transaction return actions.order.capture().then(function (details) { // Show a success message to your buyer alert('Transaction completed by ' + details.payer.name.given_name) }) } }).render('#paypal-button-container')
Nothing weird, the login goes trough but the purchase fails and I'm presented with the information that I should another payment method.
When I click on credit card, the order and values appears, but, even when I'm logged in, I'm forced to create another account?
Could I have some help here to understand what is happening?
- Labels:
-
Payouts 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.
- Using Paypal Smart Buttons for checkout sometimes fails with Debit/ Credit Cards Form in Braintree Client-side Integration (JS, iOS, Android SDKs)
- Sandbox account not generating IPNs in Sandbox Environment
- Need help to integrate PayPal Checkout (PPCP) with OpenCart? in PayPal Upgrade Community
- Add Others data in SDKs
- How can I integrate PayPal to enable direct tipping features between users on a content platform? in REST APIs