#nrh-cklimas

1 messages · Page 1 of 1 (latest)

elfin berryBOT
terse comet
#

hello, can you share a screenshot?

#

and what is the PaymentIntent ID?

charred oxide
#

I'm also getting an API error message trying to change the payment method on the subscription, but I'm not sure if this is the same problem or something else I'm doing wrong. (Error says: "No such PaymentMethod: 'pm_XXXX'; OAuth key or Stripe-Account header was used but API request was provided with a platform-owned payment method ID. Please ensure that the provided payment method matches the specified account")

terse comet
#

let's take one at a time

#

though I can guess you're using Stripe Connect?

charred oxide
#

yes. I'm also very inexperienced with Stripe 🙂

#

here's the listing in the table (blacked out my email address). clicking on that shows the error message.

terse comet
#

what is the Subscription ID and PaymentIntent ID

charred oxide
#

it says the paymentintent ID is pi_3Li1OlPbhdfvD1kV0IZ61tWa

#

I'm not sure how to find the subscription ID

terse comet
#

ok so the Subscription and PaymentIntentu ID live on the connected account since your Platform created it on the connected accounts acct_1JhHQsPbhdfvD1kV

I assume you're searching for the PaymentIntent on the Platform account, but it doens't live there, you need to look in the acct_1JhHQsPbhdfvD1kV Dashboard

charred oxide
#

aha! this fixed it.

#

thank you!

#

as for my other issue, I think the problem is that the code is creating a payment method not linked to the relevant account.

#

does that sound plausible to you?

terse comet
#

that might be that the way you're creating the PaymentMethod, you're creating it on the Platform account

#

BUT

#

your Subscription / Customer live on the connected accounts

#

so how are you creating the PaymentMethod? with Stripe.js?

#

i.e. CardElement?

charred oxide
#

yes

terse comet
#

are you passing the stripeAccount: header when initializing Stripe.js?

#

I assume no

#

which would be the issue

charred oxide
#

here

#

's what I see (wrapping my head around new code)

#

this is in React

#

in a parent component, it calls loadStripe(apiKey, { stripeAccount })

#

it renders an Elements component from @stripe/react-stripe-js and inside that Elements components is a child component that calls useStripe(). This child is creating the payment method.

#

if something sticks out to you as the wrong way to do it, advice is welcome--otherwise I think this is implementation specific on my side and I can puzzle that out.

terse comet
#

let's start here

#

what is the request ID for the request that returns

I'm also getting an API error message trying to change the payment method on the subscription, but I'm not sure if this is the same problem or something else I'm doing wrong. (Error says: "No such PaymentMethod: 'pm_XXXX'; OAuth key or Stripe-Account header was used but API request was provided with a platform-owned payment method ID. Please ensure that the provided payment method matches the specified account")

charred oxide
#

req_tVPPXZnKGdiqP6

terse comet
#

ah I see, the way you're doing

in a parent component, it calls loadStripe(apiKey, { stripeAccount })

isn't right, AFAICT stripeAccount isn't being passed to Stripe.js correctly

#

cause PaymentMethod was created on the Platform

#

your this request is OK: req_tVPPXZnKGdiqP6

just that the previous request to create the PaymentMethod was off