Skip to main content

Spread Execution

Topic: spread.execution

Response Parameters

ParameterTypeComments
idstringMessage ID
topicstringTopic name
creationTimenumberData created timestamp (ms)
dataarray<object>
> categorystringCombo or single leg, combination, spot_leg, future_leg
> symbolstringCombo or leg symbol name
> isLeveragestringAccount-wide, if Spot Margin is enabled, the spot_leg field in the execution message shows 1, combo is "", and future_leg is 0.
> orderIdstringOrder ID, leg is ""
> orderLinkIdstringUser customized order ID, leg is ""
> sidestringSide. Buy,Sell
> orderPricestringOrder price
> orderQtystringOrder qty
> leavesQtystringThe remaining qty not executed
> createTypestringOrder create type
> orderTypestringOrder type. Market,Limit
> execFeestringExecuted trading fee
> parentExecIdstringCombo's Execution ID, leg's event has the value
> execIdstringExecution ID
> execPricestringExecution price
> execQtystringExecution qty
> execPnlstringProfit and Loss for each close position execution
> execTypestringExecuted type
> execValuestringExecuted order value
> execTimestringExecuted timestamp(ms)
> isMakerbooleanIs maker order. true: maker, false: taker
> feeRatestringTrading fee rate
> markPricestringThe mark price of the symbol when executing
> closedSizestringClosed position size
> seqlongCross sequence

Subscribe Example

{
"op": "subscribe",
"args": [
"spread.execution"
]
}

Stream Example

// Combo execution
{
"topic": "spread.execution",
"id": "cvqes8141ilt347i9l20",
"creationTime": 1744104992226,
"data": [
{
"category": "combination",
"symbol": "SOLUSDT_SOL/USDT",
"closedSize": "",
"execFee": "",
"execId": "82c82077-0caa-5304-894d-58a50a342bd7",
"parentExecId": "",
"execPrice": "20.9848",
"execQty": "2",
"execType": "Trade",
"execValue": "",
"feeRate": "",
"markPrice": "",
"leavesQty": "0",
"orderId": "5e010c35-2b44-4f03-8081-8fa31fb73376",
"orderLinkId": "",
"orderPrice": "21",
"orderQty": "2",
"orderType": "Limit",
"side": "Buy",
"execTime": "1744104992220",
"isLeverage": "",
"isMaker": false,
"seq": 241321,
"createType": "CreateByUser",
"execPnl": ""
}
]
}

//Future leg execution
{
"topic": "spread.execution",
"id": "1448939_SOLUSDT_28731107101",
"creationTime": 1744104992229,
"data": [
{
"category": "future_leg",
"symbol": "SOLUSDT",
"closedSize": "0",
"execFee": "0.039712",
"execId": "99a18f80-d3b5-4c6f-a1f1-8c5870e3f3bc",
"parentExecId": "82c82077-0caa-5304-894d-58a50a342bd7",
"execPrice": "124.1",
"execQty": "2",
"execType": "FutureSpread",
"execValue": "248.2",
"feeRate": "0.00016",
"markPrice": "119",
"leavesQty": "0",
"orderId": "",
"orderLinkId": "",
"orderPrice": "124.1",
"orderQty": "2",
"orderType": "Limit",
"side": "Buy",
"execTime": "1744104992224",
"isLeverage": "0",
"isMaker": false,
"seq": 28731107101,
"createType": "CreateByFutureSpread",
"execPnl": "0"
}
]
}