#ORIKIMO-PM

1 messages ยท Page 1 of 1 (latest)

karmic bridge
#

๐Ÿ‘‹ happy to help

#

do you have the payment method id?

somber river
#

Yes

karmic bridge
somber river
#

I tried but the api return an empty object

karmic bridge
#

would you mind sharing the PM id pm_xxx?

somber river
#

ok wait a sec

#

pm_1JZbBlLYMuPAhhAUy6MURaKv

#

I think the api don't return informations because the pm is not link to a customer

karmic bridge
#

let me check

somber river
#

req_RmnE7kGfnq9QgT

karmic bridge
#

are you able to retrieve any other PM from a customer?

somber river
#

Yes

karmic bridge
#

would you mind sharing another pm id? and also the response that you're getting?

somber river
#

yes wait a min

karmic bridge
#

if you could throw in your code as well that would be great

somber river
karmic bridge
#

a side note if you don't mind

#

you don't need to wrap your code with return new Promise etc...

#

you're already in an async function using await

#

so instead of using return new Promise etc... remove that line and replace the resolve({value}) to return {value}

somber river
#

pm_1HUC16LYMuPAhhAUvovRjcAQ

#

req_CwjcRbe100Y7D7

#

I promise it because i'm parallelize requests

karmic bridge
somber river
#

Yes but all the verification process need to be promised, with this method, i can check a pm every 52ms and don't wait response

#

sorry for my english ^^

karmic bridge
#

when using a new Promise with an async function, you're creating a redundant Promise for nothing... basically instead of checkPaymentMethodValidity to return a Promise<bool> your code is returning a Promise<Promise<Promise<bool>>>

somber river
#

Ok.. and for the main problem ?

karmic bridge
#

I was still looking to be honest, and it's really weird that I wasn't able to find something specific

#

the only thing that I was able to see is that your account is in a weird state

#

maybe you should sort that out first with support https://support.stripe.com/?contact=true

somber river
#

In the api doc, they said "Retrieves a PaymentMethod object attached to the StripeAccount. To retrieve a payment method attached to a Customer" So i think gest customers don't work..

karmic bridge
#

I'm not sure to be honest let me test it out

grand anchor
#

Hi ๐Ÿ‘‹ jumping in as my teammate needed to step away. I see that you're logging paymentMethod in most of the paths that your code is taking, can you share the output of those log lines when you retrieve the Payment Method that is coming back empty?

somber river
#

no response

#

and on the log request too

grand anchor
somber river
#

wait i tried and seems work.. wait a min

#

It works

#

thank you

grand anchor
#

Glad I could help!