#NewtReyes-PaymentMethod

1 messages · Page 1 of 1 (latest)

hollow mulch
#

Hi there, can you send me the request ID?

topaz void
#

Nevermind

#

seems like I got it working

#

🙂

#

Thank you!!!

hollow mulch
#

That's great! feel free to come back if you have other questions

topaz void
#

I am trying to update a payment method but I am getting the following error: You must save this PaymentMethod to a customer before you can update it.

hollow mulch
#

Request ID?

#

Ah, it's OK I know the problem.

#

Basically you can't update a payment method unless it's attached to a customer

topaz void
#

I am following this procedure:

#
  1. Create token: req_edyok7FMe6bpb7
#
  1. Create customer: req_R5khlMvRtjXVRm
#
  1. Create setupintent: req_Q6zDM8KcTCN5bM
#
  1. Try to update PM: req_9UrP65piKBUoHr
#

What am I missing?

#

Why isn't the PM getting attached to the customer?

#

Thought that including the customer id when creating the setup intent was enough

hollow mulch
#

Let me check something one sec.

#

I noticed that you passed a on_behalf_of, are you setting up a payment method for a connected account?

topaz void
#

Yes

hollow mulch
#

And the customer that you passed in, was it created in that connected account?

topaz void
#

Yes

hollow mulch
#

Hmm, actually it's created in the platform, not connected account.

topaz void
#

is that a prob?

hollow mulch
#

Let us take a step back, what do you want to achieve here?

topaz void
#

I want to be able to create a PM and update it

#

this is for testing an integration

#

I want to add some metadata to the recently created PM

hollow mulch
#

and this PM is for platform or connected account?

topaz void
#

For an express connected account

hollow mulch
#

OK. Thanks for the context.

#

I've checked the setupIntent log, the status is still requires_confirmation, and that's why the payment method is not attached to the customer.

topaz void
#

Got it

#

Makes sense

hollow mulch
topaz void
#

Awesome!!!

#

Worked like a charm

#

Thank you!!!