Portfolio History

The portfolio history API returns the timeseries data for equity and profit loss information of the account.


Known Issue with Portfolio History Calculations

We have received feedback and are aware issues regarding data calculated with Portfolio History API which could lead to incorrect values for equity, profit_loss, and profit_loss_pct.

Please validate results for Portfolio History API and make sure values are consistent for your use case.

We will be revamping Portfolio History API soon and will be updated in the documentation accordingly.

Sample Portfolio History

  "timestamp": [1580826600000, 1580827500000, 1580828400000],
  "equity": [27423.73, 27408.19, 27515.97],
  "profit_loss": [11.8, -3.74, 104.04],
  "profit_loss_pct": [0.000430469507254688, -0.0001364369455197062, 0.0037954277571845543],
  "base_value": 27411.93,
  "timeframe": "15Min"


timestampArray of epoch int (in seconds)Time of each data element, left-labeled (the beginning of time window)
equityArray of numbersEquity value of the account in dollar amount as of the end of each time window
profit_lossArray of numbersThe profit/loss in dollars from the base value
profit_loss_pctArray of numbersThe profit/loss in percentage from the base value
base_valuenumberBasis in dollar of the profit loss calculation
timeframestringTime window size of each data element