#hammam

1 messages ยท Page 1 of 1 (latest)

mighty basinBOT
humble verge
#

Hi. How can I help?

maiden bobcat
#

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

humble verge
maiden bobcat
#

req_rmEB94ajhREMGT

humble verge
#

What if you set off_session?

maiden bobcat
#

the same

#

error

#

req_q0ji1m3cpkCd6D

#

this request with off_session

humble verge
#

It's not the same, here you used off_session: true, but it must be usage: "off_session"

maiden bobcat
#

req_7q7doKNHjnNH2S
i tryed now , the same error

untold plume
#

Hi there ๐Ÿ‘‹ jumping in as my teammate needs to step away soon.

maiden bobcat
#

ok

untold plume
#

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?

Learn how to save PayPal details and charge your customers later.

maiden bobcat
#

i konw this documention link , i do the same thing

untold plume
#

Hm, it doesn't line up with your requests though. In your requests you're including the usage parameter, but the guide does not.

maiden bobcat
#

by default ist set off_session

untold plume
#

Gotcha, we'll need to take a closer look at this and that might take a little time.

maiden bobcat
#

ok

potent kernel
#

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?