New to the community? Welcome! Please read our Community Rules and Guidelines
When using Smart buttons from the JavaScript SDK and during guest checkout the user is required to enter card information twice.
Sets to reproduce, using the PayPal online example: https://developer.paypal.com/demo/checkout/#/pattern/client
I have deployed a similar staging implementation and have the same results, how do I prevent the need for the user to enter the exact same information twice?
I've tried setting the application_context user_action below as documented but results in a PayPal 400 server error when clicking the Smart Button.
application_context: { shipping_preference: 'NO_SHIPPING', user_action: "commit" }
Payments (paypal.com)
application_context
string
A label that overrides the business name in the merchant's PayPal account on the PayPal checkout pages.
Maximum length: 127.
string
The locale of pages that the PayPal payment experience displays. Please refer here for list of supported local codes. Defaulted to en_US if not provided or invalid.
string
The type of landing page to show on the PayPal site for customer checkout. To use the non-PayPal account landing page, set to Billing. To use the PayPal account log in landing page, set to Login.
enum
The shipping preference.
The possible values are:
string
The user action. Presents the customer with either the Continue or Pay Now checkout flow:
FlowActionDescriptionPay Nowuser_action=commitAfter the customer is redirected to the PayPal payment page, shows the Pay Now button.Continue | user_action=continue | After the customer is redirected to the PayPal payment page, shows the Continue button. Use this option when you do not know the final amount when you initiate the checkout flow and you want to redirect the customer to the merchant page without processing the payment. |
The preferred payment source for the payer. Currently supported only for PayPal Billing Agreements. If provided, checkout experience will have this payment source pre-selected for the
I'm currently having the same problem and the demo page is also still doing it.
Did this ever get resolved?
Update:
Tested this in production and it works fine. Problems appears to happen only in the sandbox.
©1999-2021 PayPal, Inc. All rights reserved.