# allIsolatedMarginUpdates stream

> HyperCore private-preview documentation.

> For the complete documentation index, see [llms.txt](/docs/llms.txt).

<Callout intent="info">
  This API is in private preview. Target September 2026; timing is subject to change.
</Callout>


# allIsolatedMarginUpdates stream

Streams isolated-margin and isolated-margin top-up updates across users.

## Subscribe

```json
{
  "method": "subscribe",
  "subscription": {
    "type": "allIsolatedMarginUpdates"
  }
}
```

## Event envelope

```json
{
  "type": "allIsolatedMarginUpdates",
  "channel": "allIsolatedMarginUpdates",
  "seq": 1,
  "cursor": 1704067201000,
  "updates": [{
    "updateType": "updateIsolatedMargin",
    "time": 1704067201000,
    "user": "0x1111111111111111111111111111111111111111",
    "coin": "xyz:GOLD",
    "isBuy": false,
    "ntli": "0.223223",
    "txIndex": 0
  }]
}
```

An isolated-margin top-up update uses updateType `topUpIsolatedOnlyMargin` and includes targetLeverage instead of isBuy and ntli.

These are normalized events derived from on-chain actions: asset IDs are resolved to market symbols and integer quantities are converted to decimal strings.

## Payload fields

| Field | Type | Description |
| --- | --- | --- |
| type | string | Event type. |
| channel | string | Routing channel for the event. |
| seq | integer | Monotonic sequence number for the stream. |
| cursor | integer | Resume cursor for the event position. |
| updates | array | Margin update records. |
| updates[] | object | Isolated-margin or isolated-margin top-up record. |
| updates[].updateType | string | Update discriminator: `updateIsolatedMargin` or `topUpIsolatedOnlyMargin`. |
| updates[].time | integer | Event time in milliseconds. |
| updates[].user | string | Address whose margin setting changed. |
| updates[].coin | string | Market identifier. |
| updates[].isBuy | boolean | Isolated-margin side for an `updateIsolatedMargin` update. |
| updates[].ntli | string | Isolated-margin notional value for an `updateIsolatedMargin` update. |
| updates[].targetLeverage | string | Target leverage for a `topUpIsolatedOnlyMargin` update. |
| updates[].txIndex | integer | Index of the transaction within its block. |

## Behavior

The stream batches update records. The cursor identifies the event position for resumption.

## Unsubscribe

```json
{
  "method": "unsubscribe",
  "subscription": {
    "type": "allIsolatedMarginUpdates"
  }
}
```

## Resume

To resume a stream, supply cursor in the subscription object. Store and return the cursor unmodified.