Skip to content
Alchemy Logo

allTwapStatusUpdates stream

This API is in private preview. Target September 2026; timing is subject to change.

{
  "method": "subscribe",
  "subscription": {
    "type": "allTwapStatusUpdates",
    "coins": ["BTC"]
  }
}

{
  "channel": "subscriptionResponse",
  "data": {
    "subscriptionId": "sub_01",
    "type": "allTwapStatusUpdates"
  }
}

{
  "channel": "allTwapStatusUpdates",
  "subscriptionId": "sub_01",
  "blockHeight": 123456,
  "blockTime": 1780000000000,
  "cursor": "<opaque cursor>",
  "data": {
    "time": "2025-09-03T10:48:14.285201806",
    "createdAt": 1756896494285,
    "twapId": 12345,
    "user": "0x1111111111111111111111111111111111111111",
    "coin": "BTC",
    "side": "B",
    "status": "activated",
    "statusMessage": null,
    "sz": "1.00",
    "minutes": 60,
    "reduceOnly": false,
    "randomize": true,
    "executedSz": "0.20",
    "executedNtl": "20000.0",
    "txIndex": 3,
    "triggerPx": "100000.0",
    "triggerAbove": true,
    "stopPx": "95000.0"
  }
}

FieldTypeDescription
timestringTime of the status update.
createdAtintegerTime the TWAP was created, in milliseconds.
twapIdintegerIdentifier for the TWAP order.
userstringAddress that owns the TWAP order.
coinstringMarket symbol for the TWAP order.
sidestringSide code: A is ask/sell; B is bid/buy.
statusstringTWAP status: activated, finished, terminated, stopped, waitingForTrigger, or error.
statusMessagestring or nullStatus detail; populated for an error status.
szstringTotal TWAP size.
minutesintegerDuration of the TWAP in minutes.
reduceOnlybooleanWhether the TWAP only reduces an existing position.
randomizebooleanWhether the TWAP schedule is randomized.
executedSzstringCumulative size executed by the TWAP order.
executedNtlstringCumulative notional executed by the TWAP order.
txIndexintegerTransaction index of the update within its block.
triggerPxstringTrigger price for a trigger TWAP.
triggerAbovebooleanDirection that activates a trigger TWAP relative to triggerPx.
stopPxstringStop price attached to the TWAP.

{
  "method": "unsubscribe",
  "subscription": {
    "type": "allTwapStatusUpdates",
    "coins": ["BTC"]
  }
}

To resume a stream, supply cursor in the subscription object. The cursor is opaque: clients store and return it unmodified, and its format may change.

Was this page helpful?