#ankit_api

1 messages ยท Page 1 of 1 (latest)

stiff rockBOT
#

๐Ÿ‘‹ 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. Thank you for your patience!

โฑ๏ธ We automatically close idle threads, which makes them read-only. Make sure you stick around to chat in realtime! If this thread is closed and you have another question you'll need to start a new thread.

๐Ÿ”— 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/1214508434809163827

๐Ÿ“ Have more to share? You can add more detail below, including code, screenshots, videos, etc.

spring palmBOT
bronze warren
#

hi! well you don't really, it works the opposite way

#

when a payout happens, you can find out what payments were included in that payout : https://docs.stripe.com/expand/use-cases#charges-in-payout

and then that way you can know that a certain invoice has been paid out in that Payout; so you listen to payout.created webhook events, do that process, and mark your database or add metadata to objects so you have information on what payout they were in

quiet wolf
#

so if there us any way to create the link between invoice id and payout id?

bronze warren
#

yes, I described the way above.

quiet wolf
#

so with the help of pm_id we can fetch the payout id?

bronze warren
#

not sure what you mean, I never mentioned a "pm_id" (pm_xxx is a PaymentMethod).

#

as I mentioned โ€” you would listen to payout.created events, use the process at https://docs.stripe.com/expand/use-cases#charges-in-payout to 'reconcile' what payments are in the payout, and update your database with that information. If you do that over time for every payout, you will know what payout a certain payment or Invoice was in. But you have to understand it works that way(you start with the payout, not the Invoice).

quiet wolf
#

ok got it

#

now i understood

#

thank you so much