#egor.slam-net amount

1 messages ยท Page 1 of 1 (latest)

kindred bloom
#

๐Ÿ‘‹ happy to help

#

on any payment intent there is a list of Charges

#

you could see the balance transaction per each charge object if you want

limpid stream
#

right I can get charge -> balance transaction -> net

but it's net of the original charge and this NET NOT includes refunds

and on the charge page i can see needed value

kindred bloom
#

so actually you'd have to look into both balance transaction and the refunds list of the Charge Object

#

so the Net Amount of each charge is
balance_transaction.net - sum(refunds. data.amount)

#

it's a pseudo code but refunds is a list

#

so you need to sum all the amount of the partial refunds within that list

limpid stream
#

got it. thanks

#

I was thinking about ready value, will calc it on my side

kindred bloom
#

there is no ready value

#

it should be calculated each time ๐Ÿ˜ฟ