Skip to content
LogoLogo

Account state

Endpoint

POST /info

Selector: type: "clearinghouseState"

Purpose

Returns the customer's perpetual account summary, margin and positions from the confidential ledger.

Authorization

Owner or approved reader for user. The SDK signs requests; raw clients use proof headers.

Request fields

FieldTypeRequiredMeaning
typeStringYesclearinghouseState.
userAddressYesCustomer account address; the signer must own it or have read permission.
dexStringNoOmit or use the empty string for the default perpetual DEX.

Request example

{
  "type": "clearinghouseState",
  "user": "0x1111111111111111111111111111111111111111"
}

Response fields

FieldMeaning
assetPositionsPosition entries containing the coin, signed size, entry price, cross leverage, margin, PnL and funding.
marginSummary / crossMarginSummaryAccount value, margin used, gross position notional and raw USD cash, encoded as decimal strings.
crossMaintenanceMarginUsedMaintenance margin in decimal quote units.
withdrawableThe private account's currently withdrawable amount; this is not a completed custody payout.
timeSnapshot time in Unix milliseconds.

Response example

Illustrative response:

{
  "assetPositions": [],
  "crossMaintenanceMarginUsed": "0",
  "crossMarginSummary": {
    "accountValue": "0",
    "totalMarginUsed": "0",
    "totalNtlPos": "0",
    "totalRawUsd": "0"
  },
  "marginSummary": {
    "accountValue": "0",
    "totalMarginUsed": "0",
    "totalNtlPos": "0",
    "totalRawUsd": "0"
  },
  "time": 1796238000000,
  "withdrawable": "0"
}

Constraints

  • The supported position model uses cross margin.
  • liquidationPx is null; the API does not publish an unverified cross-margin liquidation estimate.
  • Only the default perpetual DEX is supported.

All account queries.