#0xzoltaneth_api

1 messages · Page 1 of 1 (latest)

deep moonBOT
#

👋 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/1284059137214513162

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

dire torrent
#

I'd be happy with a non-elegant solution as well, ie. getting an email from Stripe to my email address and getting the customer email and the paid amount in there and in that case I couldn build an automation from there.

deep moonBOT
steady swift
#

Hi, let me help you with this.

#

Could you please share the Customer ID? cus_xxx

dire torrent
#

Any customer

#

Any customer pays

#

And I'd like to collect their email address and paid amount so that I can add them to their course

#

obviously automatically

#

So I need to use API probably

#

Actually I can grab the amount they pay easily from "amount received"

#

However their emails are not captured

steady swift
#

I am asking for a Customer ID to understand how you're collecting emails, so I can suggest how you can automate it.

dire torrent
#

Ok where can I grab one?

steady swift
#

PaymentIntent ID is also fine

#

pi_xxx

#

The email address probably lives on the Customer object that you can find attached to the PaymentIntent.

dire torrent
#

pi_3PyUWzCeIDajNZL71Svw9qe2

steady swift
#

You get a receipt_email on the PaymentIntent object.
But also you can find billing_details[email] on the related Charge object. You can find the Charge via PaymentIntent.latest_charge.

dire torrent
#

Cool thanks I just found it!

#

Now I cant find the name of the customer

#

Can you help plls

#

I should be able to grab the name as well, in this case it was Czére Zoltán

steady swift
#

It's on the Charge object, billing_details[name]

dire torrent
#

I can see it should be on there...

#

Its just not there, this is everything it captures

#

I can't see name: Czére Zoltán anywhere

#

just so you know this is a payment intent webhook

steady swift
dire torrent
#

k let me try

#

Cool, thank you!!

#

Pls bear with me a moment to check if everything is captured

#

If Event Type=charge.succeeded that means payment succeeded, right?

steady swift
#

As a rule of thumb, if you create a PaymentIntent, listen to payment_intent.succeeded event.

dire torrent
#

Thank you! Everything is captured

#

Have a great day!

steady swift
#

Happy to help.