#Am.D-Account

1 messages · Page 1 of 1 (latest)

steep wave
#

Could you summarize your question? Are you asking about how to change the connected Stripe Id when create Payment Intent?

gentle schooner
#

hello , i got no such payment intent error , which i belive it has been generated with a different account id from the one i set
i am using react native and SDK from stripe

#

how can i change my

#

this is where i am initializing and use it as a provider

steep wave
#

So when you initialize client side you need to fix a Connected Account Id

#

You were correct that "No such PaymentIntent" error is because the PI belongs to different account

gentle schooner
#

how can i send muliptle account id ?

steep wave
#

I am not sure if that's possible. Is that React or React Native?

gentle schooner
#

the backend is generating the payment intent with multiple account id

#

React Native

steep wave
#

I believe this issue mentioned about the same issue

#

Can you try this suggestion?

#

keep it in a state variable and pass that to the StripeProvider component

gentle schooner
#

gonna check it , please dont archive our talk @steep wave

steep wave
#

Sure

gentle schooner
#

and how can we use multiple account id for there?

#

the backend is generating payment intent connected with multiple account , how is that possible from app side. ? @steep wave

steep wave
#

PaymentIntent can only be generated from backend

#

If you are frontend developer you shouldn't worry about it

gentle schooner
#

ye i know

#

but which account id i should pass there ? @steep wave

steep wave
#

It depends on the system design. I would say you need to know exactly what account id before going to the confirmation page, then pass the value onto the state variable mentioned in above solution

#

How did you retrieve the PaymentIntent secret? via a call to your backend right? You can ask your backend team to also return the account id there

#

so they need to return a pair of (accountId, PaymentIntent secret)

gentle schooner
#

ye i know , but the question is :
backend is generating a payment intent connected with multiple account ids .
how can i pass multiple account id ?

steep wave
#

a payment intent connected with multiple account ids
This is not possible

#

a PaymentIntent only tie to one Stripe account Id

gentle schooner
#

i talked with backend team

#

as you can see we are able to add multipe account there , and backend will send me an array of account ids @steep wave

#

what will be the approach here /

steep wave
#

hmm I see

#

That flow "Separate Charges and Transfer" mean you transfer to multiple different Accounts, but the PaymentIntent belongs to your Platform account

#

meaning you don't need to pass in stripeAccountId, just initialize with your platform's publishable key

#

then you should find the PI

gentle schooner
#

am i able to send null for account id ? @steep wave

steep wave
#

You can just don't set stripeAccountId

gentle schooner
#

but while initializing i am adding it to the provider @steep wave

steep wave
#

How about just remove that parameter?

#

comment out line 96

gentle schooner
#

but it should be dynamically changable

#

i will try to handle this , otherwise gonna ask for help

#

cheers

obtuse minnow
#

Hi! If you are using Destination Charges, you'll never need to set stripeAccountId on the frontend, that's why you can completely remove it.