Skip to content
Alchemy Logo

builderLiquidations stream

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

Streams liquidation fills associated with a builder.

{
  "method": "subscribe",
  "subscription": {
    "type": "builderLiquidations",
    "builder": "0x2222222222222222222222222222222222222222",
    "aggregateByTime": true
  }
}

{
  "type": "builderLiquidations",
  "channel": "builderLiquidations",
  "seq": 1,
  "cursor": "500:1704067200000:3",
  "liquidations": [[
    "0x1111111111111111111111111111111111111111",
    {
      "coin": "ETH",
      "px": "2150.50",
      "sz": "1.5",
      "side": "B",
      "time": 1704067200000,
      "startPosition": "1.5",
      "dir": "Open Long",
      "closedPnl": "125.50",
      "hash": "0xabc...def",
      "oid": 12345678,
      "crossed": false,
      "fee": "2.50",
      "tid": 87654321,
      "cloid": "client-123",
      "builderFee": null,
      "deployerFee": null,
      "feeToken": "USDC",
      "builder": "0x2222222222222222222222222222222222222222",
      "twapId": null,
      "txIndex": 1,
      "liquidation": {
        "liquidatedUser": "0x3333333333333333333333333333333333333333",
        "markPx": "2148.00",
        "method": "market"
      }
    }
  ]]
}

FieldTypeDescription
typestringEvent type.
channelstringRouting channel for the event.
seqintegerMonotonic sequence number for the stream.
cursorstringResume cursor for the event position.
liquidationsarrayPairs of user address and liquidation fill.
liquidations[]tupleUser address followed by a liquidation fill.
liquidations[][0]stringAddress associated with the fill.
liquidations[][1]objectLiquidation fill record.
liquidations[][1].coinstringMarket symbol.
liquidations[][1].pxstringFill price.
liquidations[][1].szstringFilled size.
liquidations[][1].sidestringSide code: A is ask/sell; B is bid/buy.
liquidations[][1].timeintegerFill time in milliseconds.
liquidations[][1].startPositionstringPosition size before the fill.
liquidations[][1].dirstringPosition-direction classification for the fill.
liquidations[][1].closedPnlstringRealized profit and loss from the fill.
liquidations[][1].hashstringTransaction hash containing the fill.
liquidations[][1].oidintegerOrder identifier.
liquidations[][1].crossedbooleanWhether the fill crossed the book.
liquidations[][1].feestringFee charged for the fill.
liquidations[][1].tidintegerTrade identifier.
liquidations[][1].cloidstringClient-supplied order identifier, when present.
liquidations[][1].builderFeestringBuilder fee charged for the fill, when present.
liquidations[][1].deployerFeestringDeployer fee charged for the fill, when present.
liquidations[][1].feeTokenstringToken used to pay the fee.
liquidations[][1].builderstringBuilder address associated with the fill.
liquidations[][1].twapIdinteger | nullTWAP identifier, when the fill belongs to a TWAP.
liquidations[][1].txIndexintegerIndex of the transaction within its block.
liquidations[][1].liquidationobjectLiquidation details.
liquidations[][1].liquidation.liquidatedUserstringAddress of the liquidated user.
liquidations[][1].liquidation.markPxstringMark price at liquidation.
liquidations[][1].liquidation.methodstringLiquidation method: market or backstop.

The stream batches liquidation fills for the requested builder. The aggregateByTime parameter controls time aggregation, and the cursor identifies the event position for resumption.

{
  "method": "unsubscribe",
  "subscription": {
    "type": "builderLiquidations",
    "builder": "0x2222222222222222222222222222222222222222",
    "aggregateByTime": true
  }
}

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

Was this page helpful?