This API is in private preview. Target September 2026; timing is subject to change.
Streams isolated-margin and isolated-margin top-up updates for the requested addresses.
{
"method": "subscribe",
"subscription": {
"type": "userIsolatedMarginUpdates",
"addresses": ["0x1111111111111111111111111111111111111111"]
}
}{
"type": "userIsolatedMarginUpdates",
"channel": "userIsolatedMarginUpdates",
"seq": 1,
"cursor": 1704067201000,
"updates": [{
"updateType": "updateIsolatedMargin",
"time": 1704067201000,
"user": "0x1111111111111111111111111111111111111111",
"coin": "BTC",
"isBuy": true,
"ntli": "500.00",
"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.
| 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. |
The stream batches updates for the subscribed addresses. The cursor identifies the event position for resumption.
{
"method": "unsubscribe",
"subscription": {
"type": "userIsolatedMarginUpdates",
"addresses": ["0x1111111111111111111111111111111111111111"]
}
}To resume a stream, supply cursor in the subscription object. Store and return the cursor unmodified.