#hammam
1 messages ยท Page 1 of 1 (latest)
Hi. How can I help?
by stripe setupIntent Create for paypal
ich got alway erorr if set usage off_session or usage on_session
protected async createSetupIntentPayPal(
context:Context,
payload:any):Promise<string>
{
console.log("createSetupIntentPayPal ", payload);
console.log("Methods ", this.getMethods());
const customer = await this.getCurrentCustomer(context);
const setupIntent = await this.getApi().setupIntents.create(<any>
{
customer: customer.id,
payment_method_types: ['paypal'],
payment_method_data: {
type: 'paypal',
},
usage:'on_session',
});
return setupIntent.client_secret;
}
i use nodejs
Could you please share the Request ID req_xxx? https://support.stripe.com/questions/finding-the-id-for-an-api-request
req_rmEB94ajhREMGT
What if you set off_session?
It's not the same, here you used off_session: true, but it must be usage: "off_session"
req_7q7doKNHjnNH2S
i tryed now , the same error
Hi there ๐ jumping in as my teammate needs to step away soon.
ok
Looking at our guide for setting up Paypal payment methods to be used for future payments:
https://stripe.com/docs/payments/paypal/set-up-future-payments?platform=web#enable-recurring-payments-support-from-stripe-dashboard
It looks like using that combination requires you to enable a setting in your dashboard, have you done that already?
Additionally, I see in that guide that usage is omitted when creating the Setup Intent, does doing the same allow your process to progress?
i konw this documention link , i do the same thing
Hm, it doesn't line up with your requests though. In your requests you're including the usage parameter, but the guide does not.
by default ist set off_session
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
and i want to use paypal for subscriptions
https://stripe.com/docs/payments/paypal/set-up-future-payments?platform=web#web-handle-redirect-manually
Gotcha, we'll need to take a closer look at this and that might take a little time.
ok
hey there, thanks for raising this
we did some digging internally and found this is related to you having used our earlier implementation of paypal (i hope that makes sense to you, let me know if it doesn't!)
we've made a change that should allow this to work for you now. Can you try again?