Developer Community

Ask a Question
Back to All

How to properly calculate the TOTAL balance from an investment account?

Hi!

I have a question when fetching balances from investments accounts. There are many properties related to monetary amounts and I'm not sure which one (or maybe a sum of them) will reflect the actual "total balance".

What I'm calling "total balance" is all the amount invested (equities, stocks, ...) plus any amount in cash.

Is it currentValue? Or should it be currentValue + availableCashBalance?

I also see some fields called rolloverAmount, shortBalance and marginBalance that I'm not sure if I need them.

Thank you.