#red_node-javascript-browser

1 messages · Page 1 of 1 (latest)

blissful quailBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1385006455375003803

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

kind flower
#

From your code, it looks like you're searching the customer with email as propsData.contact.email? You're not passing the actual email address

inland fulcrum
#

the email address is contained in that JSON

#

the error is on stripe.customers being undefined

#

this is on the client

kind flower
inland fulcrum
#

it doesn't get that far

kind flower
#

Could you share the full error message you're facing?

inland fulcrum
#

payments:93 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'search')
at handlePaymentSuccess (payments:93:44)
at HTMLFormElement.handleSubmit (payments:66:9)

kind flower
#

Which version of stripe-node are you using?

inland fulcrum
#

it's javascript

#

on the client

#

not server

kind flower
#

Are you referring to Stripe.js?

inland fulcrum
#

I had a similar issue with the following code:

var paymentIntent = await stripe.paymentIntents.retrieve

#

yes

kind flower
#

This is expected. stripe.customer.search is only supported at the server side

#

not client side

inland fulcrum
#

on the above code stripe.paymentIntents was undefined - I had to change it to stripe.retrievePaymentIntent(cs)

#

gotcha, that's what I was wondering

#

is there a way to retrieve on client?

kind flower
#

I'm afraid that's not possible

inland fulcrum
#

stripe.retrieveCustomer maybe?

kind flower
#

Stripe.js only supports retrieving Payment Intent and Setup Intent, but not Customer

#

To retrieve, list or search a customer, this can only be done at server side

inland fulcrum
#

gotcha. thanks

kind flower
#

No problem! Happy to help 😄

blissful quailBOT