#cac3a-new-pm

1 messages ยท Page 1 of 1 (latest)

small tiger
#

Hey there! This isn't possible but you don't really need to do this.

#

You can pass card objects to the payment_method param

pliant crow
#

is it as card[token] = card_x123 ?

#

I've been trying and can't seem to get it working

small tiger
#

What language are you using and what exactly are you trying to do?

#

Also if you are hitting a certain error message then that would be helpful as well

pliant crow
#

I have stripe working under my account without issue. However, I have a customer that I have integrated through stripe connected accounts to charge under their account for some of our services. The issue is that all of their customers have card_ objects and our integration is based on payment methods.

small tiger
pliant crow
#

?

small tiger
#

Yep exactly

#

Also please delete that key

#

Even if it is a test key that is sensitive data that someone could use to get control of your account.

#

I'd recommend rolling your keys as well.

pliant crow
#

thanks

pliant crow
#

so got the request built up

#

and getting the following error": {
"code": "resource_missing",
"doc_url": "https://stripe.com/docs/error-codes/resource-missing",
"message": "No such PaymentMethod: 'card_434343432N1CUn'",
"param": "payment_method",
"type": "invalid_request_error"

Learn more about common error codes and how to resolve them.

#

simply means that the card is not there ?

eager pewter
#

๐Ÿ‘‹ @bismark had to step away but I can help -do you have the request ID (req_xxx) that resulted in that error?

pliant crow
#

I didn't see request id in the response

eager pewter
pliant crow
#

this one wasn't in test

eager pewter
#

Let's approach this from a different angle then - is card_434343432N1CUn the exact object ID you got back from the error message? Or did you change it at all before pasting it here?

pliant crow
#

yeah

#

i was using wrong card

#

customer just updated it

#

how would this work if i have payment method and they change a card after pm has been established. Will it still work >

#

under new card

#

or I need to generate new pm each time card is added

grizzled sable
#

What did they update about it?

pliant crow
#

I dunno, but I looked at their profile and it was different card_id and expiration was different. But maybe I used a wrong before (it was my assumption that card has changed).

#

So now with pi -> how do I go to pm ?

#

my ultimate original goal was to arrive at payment method

#

and my understanding (perhaps wrong) was that i need pi first

grizzled sable
#

I am a bit unclear on your question. Is this still related to your question on creating the PaymentIntent?

#

From my understanding, you have these card_ objects and can pass their ID in to anything that is requesting a payment method ID. You shouldn't need to create a separate payment method for these.

#

The "No such PaymentMethod" error could be coming from a couple of places but it is hard to tell without the specific request ID from when you got that error. Do you have the full response that you got this error from?

pliant crow
#

Sorry for confusing you and others.

#

My original goal is to be able to use card_ object and establish payment method. I have established payment intent successfuly, but now not sure how to go from pi_ to pm_.

grizzled sable
#

If you are using a card, that will also have the card_123 ID because you can use those IDs interchangeably here

pliant crow
#

so am i understanding you correctly that on the payment intent object for payment_method you can use card_ or pm_ objects without any issues.

grizzled sable
#

Correct. You can use either

pliant crow
#

ok thank you. In which cases card_ object id would change ?

manic aurora
#

Hello! I'm taking over and catching up now...

#

card_ IDs don't change. Why do you ask?