Skip to navigation

Executions

A fill

URL — No public environment serves this socket yet.

Topic execution

Request parameters

ParameterTypeRequiredDescription
opstringYessubscribe
reqIdstringYesEchoed byte-exact on the answer. Printable ASCII, escape-free; anything else answers MALFORMED.
paramsobjectYes
> topicsarray of stringsYesexecution

Response parameters

ParameterTypeRequiredDescription
opstringYesOne of subscribe, unsubscribe.
reqIdstringYesEchoed byte-exact on the answer. Printable ASCII, escape-free; anything else answers MALFORMED.
successbooleanYestrue

Push data parameters

orderId is null for a leg discovered at the venue before the platform bound it to an order; the row is restated with the id when attribution lands, and the upsert rule makes that a replacement rather than a duplicate.

What the image holds. Every execution leg of the organization this member retains, keyed by executionId — no window applies here, unlike order. A leg is retained as long as the order it belongs to is, so the set follows orders rather than time.

How a row leaves. With its order, when the platform releases that order under its own retention, and — as on order — that release rides no wire. Re-subscribe to rebuild. Nothing else removes a leg: a busted or corrected fill arrives as its own row with its own kind, never as a deletion of the one it corrects.

ParameterTypeRequiredDescription
eventstringYesexecution
msgTypestringYesexecution
topicstringYesexecution
seqstringYesThe stream position, as a decimal string — an int64 a JSON number would truncate.
seqTsstringYesThe stream timestamp, epoch-ns as a decimal string.
isSnapshotbooleanYesOne of true, false.
snapshotIdstringNoPresent on a snapshot part only, and the same on every part of one image; the next image of any topic carries a different one. Opaque — compare it for equality and nothing else. It is not a sequence, a version or a timestamp, and its shape may change; a client that ordered by it would be relying on how a member happens to mint it. Use it to keep two images apart. A repeat subscribe re-pushes the image — that is the resync, and there is no separate op — so a client can start image N+1 while N is still arriving, and without a name on each part it cannot tell which last: true closes which, nor stop a straggling part of N landing in the map N+1 just cleared. Discard any part whose snapshotId is not the one you are currently applying.
partintegerNoPresent on a snapshot part only; 1-based.
lastbooleanNoPresent on a snapshot part only. The image is complete when true — including for an empty channel, which is still one part.
dataarray of objectsYesOne fill, keyed by executionId.
> executionIdstringYes
> orderIdstring, nullableYesNull for a leg discovered at the venue before the platform bound it to an order. The row is restated with the id when attribution lands, and the upsert rule makes that a replacement rather than a duplicate.
> accountIdintegerYes
> accountstring, nullableYes
> instrumentIdstringYesAn instrument, by the platform’s own id — an int64 as a decimal string, because a JSON number cannot hold one. One id space across this wire and the HTTP lane, and the same one both order doors take: the id you read here is the id you send, on submitOrder and on POST /orders alike. It is the platform’s own reference-data key and nothing else’s. It is not a venue symbol, and it is not an id from any other system — in particular it does not equal an immix-api v2 Instrument.id, and there is no arithmetic that maps between them. A client holding v2 ids resolves through the symbol, once, at cutover: instrument beside this field carries the platform symbol (OKX@BTC/USDT), which is what both systems can be joined on. The id is the stable address and the symbol is the convenience: a symbol is reference data’s to change and this id is not.
> instrumentstring, nullableYes
> credentialIdintegerYes
> sidestringYesOne of UNKNOWN, BUY, SELL.
> kindstringYesOne of UNKNOWN, FILL, BUST, CORRECTION.
> liquiditystring, nullableYesNull when the venue did not say. One of MAKER, TAKER.
> qtystringYes
> pxstringYes
> feestring, nullableYesSigned — a rebate is a negative fee. A fee is a fact once it names its asset, a stated zero included; only an unstated fee is null.
> feeAssetIdinteger, nullableYes
> feeAssetstring, nullableYes
> fillTsNsstring, nullableYes
> venueTsNsstring, nullableYes
> venueTradeIdstring, nullableYes
> venueOrderIdstring, nullableYes
> notionalUsdstring, nullableYesqty x px converted at the quote asset’s USD rate. Null where the platform holds no current rate — null is NEVER the un-converted amount.
> feeUsdnullYesAlways null in 1.0.0. The conversion is defined but the renderer for a signed 128-bit amount is not published yet, and a rounded fee would be a wrong number rather than a missing one. Read fee with feeAsset. When it starts carrying a value it will be a decimal string, which is an additive change to this type.
> fxSourcestring, nullableYesThe route the QUOTE asset’s USD rate took — the notional’s provenance. Null where the platform holds no current rate, which is also when notionalUsd is null: null is NEVER the un-converted amount. One of IDENTITY, DIRECT, CROSS, PEGGED.