Get Account Info

Provides information on a specific trading account.

Let's look at the following response example:

{
  "collateralBalance": "3627.894177",
  "availableMargin": "3049.205067",
  "totalInvested": "3511.0394",
  "totalMargin": "3634.378226",
  "totalUnrealizedPnl": "6.662591",
  "positions": [
    {
      "marketId": "SOLUSDC",
      "direction": "SHORT",
      "avgExecutionPrice": "149.566",
      "size": "17.6",
      "marginAmount": "438.726714",
      "borrowedAmount": "2193.633571",
      "leverage": "6",
      "realizedPnl": "1.931",
      "liquidationPrice": "372.988834",
      "maintenanceMargin": "78.970848"
    },
    {
      "marketId": "ETHUSDC",
      "direction": "SHORT",
      "avgExecutionPrice": "3993.99",
      "size": "0.22",
      "marginAmount": "146.446445",
      "borrowedAmount": "732.232227",
      "leverage": "6",
      "realizedPnl": "1.4279",
      "liquidationPrice": "21204.717038",
      "maintenanceMargin": "26.360334"
    }
  ]
}

collateralBalance is the amount on the account balance. It neither counts any unrealized PNL nor represents the amount that could be withdrawn immediately.

availableMargin is the margin amount available for opening new positions. Total value of a position that could be opened depends on leverage.

totalMargin - collateralBalance + unrealized pnl

totalUnrealizedPnl - raw estimation of balance change as a result of immediately selling all positions without taking fee into account

Last updated