Risk Manager: Liquidation Proximity and Cohort Stress

Build a risk dashboard that ranks positions by danger and highlights crowding and liquidation clustering.

The Risk Manager is designed around prioritization. Most users cannot interpret a complex portfolio in real time, especially when leverage is involved. A strong risk manager reduces everything to a short list of “things you must care about right now.”

You begin with GET /api/wallets/{address} and compute per-position risk indicators such as liquidation distance, leverage sensitivity, concentration, and dependency on collateral health. You then rank positions so the interface leads with the most dangerous one, not the largest one. This is where you turn raw fields into decision support: “This position is closest to liquidation” or “This position dominates your exposure.”

Next, you add systemic context. GET /api/state/summary provides a stress header, and cohort endpoints such as GET /api/segments/{segmentId}/assets/liquidation-risk show whether the broader crowd is vulnerable in the same asset. If many wallets in a segment are clustered near liquidation on the same coin, the risk of cascade increases, and your UI can warn users more aggressively.

Optional drilldowns via segment wallets and positions let you show “who else is vulnerable,” which is a powerful educational tool and helps advanced users interpret crowd risk.

Necessary Rest API:

  • Get Wallets (get a paginated list of wallets with filtering by address, segment, and liquidation proximity)

  • Get All Positions (retrieve open or closed positions filterable by address, coin, and time)

  • Get Liquidation Risk by Asset (Returns each asset’s percent of open interest at high liquidation risk within a cohort)

  • Get Cohort Summary (get a snapshot for a specific cohort including top assets, exposure metrics, and 24h trader count changes)

Necessary HL Info Endpoints:

Optional Rest API:

Optional HL Info Endpoints:

  • openOrders (show the current open orders for an account)

  • userRole (show what kind of user the wallet is)

  • subAccounts (show all sub wallets associated with the master wallet (if any))

  • activeAssetData (get real time wallet data for a specfiic asset)

An example of how a self-made Risk Management tool using the Risk Manager would look like:

Last updated