#.ib3n
1 messages · Page 1 of 1 (latest)
You can listed to webhook event balance.available for this
It should, yes
There may be multiple transfers created for this account, is there a way to know which transfer has become available?
Once again, I really appreciate your help!
hmm, I don't think there's a specific transfer linked to those events unfortunately. thinking of a workaround..
sorry for the delay
So my understanding is that transfers are instant. They don't really have a status of pending as such.
are you using source_transaction parameter for creating transfers before funds are available?
Yes i'm using the charge associated with an invoice on the invoice.paid event as the source_transaction property
Gotcha. I haven't tried this myself but do you see transfer.created webhook event right after you send the request to create the transfer? OR do you see that after the funds are available?
Right after we send the create transfer request
Gotcha. This is a bit tricky since there's no direct way to get this info.
I'm thinking you could look at transfer's OR destination_payment's balance transaction object and check it's status
https://stripe.com/docs/api/transfers/object#transfer_object-balance_transaction
but there's no way to co-relate a balance.available webhook to a specific transfer 😅
ok that makes sense, I can listen to the balance.available hook and use the event.account property to check the transfers to that destination account
If I don't associate the transfer with the invoice charge using source_transaction - are the funds immediatley available?
no, if you don't use source_transaction parameter then the transfer creation request would likely fail if your platform account balance is less than transfer amount
Ok thank you so much hanzo, you've been an unbelievable help, hope you have a great day!