event | string | Yes | order |
msgType | string | Yes | orderUpdate |
topic | string | Yes | order |
seq | string | Yes | The stream position, as a decimal string — an int64 a JSON number would truncate. |
seqTs | string | Yes | The stream timestamp, epoch-ns as a decimal string. |
isSnapshot | boolean | Yes | One of true, false. |
snapshotId | string | No | Present 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. |
part | integer | No | Present on a snapshot part only; 1-based. |
last | boolean | No | Present on a snapshot part only. The image is complete when true — including for an empty channel, which is still one part. |
data | array of objects | Yes | One order’s applied image, keyed by orderId. Upsert by that key into the map part: 1 cleared. |
> orderId | string | Yes | The upsert key, as a decimal string — an int64. |
> version | string | Yes | |
> clientOrderId | string, nullable | Yes | The id the submitter chose; null when it sent none. |
> accountId | integer | Yes | |
> account | string, nullable | Yes | The account’s display name; null when the referenced row is not held. |
> instrumentId | string | Yes | An 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. |
> instrument | string, nullable | Yes | |
> credentialId | integer | Yes | |
> actor | object | Yes | The principal behind an act, as the platform records it on every command and fact: a member of your organization (USER, id their user id — the REST API’s GET /users/{id}), an API key it issued (API_KEY, id the key’s — GET /api-keys/{id}), or the platform itself (MACHINE, id 0) when a strategy’s instance acted — then algoInstanceId beside it names the instance. Tell a strategy’s act from a principal’s by algoInstanceId, never by the kind alone. UNKNOWN is the sentinel of a fact that stated none, which nothing in this release writes; tolerate it as you would a kind you do not know. |
> > kind | string | Yes | One of UNKNOWN, USER, API_KEY, MACHINE. |
> > id | integer | Yes | |
> algoInstanceId | integer, nullable | Yes | The algo instance that placed the order, when a strategy placed it (the MACHINE actor is beside it); null on an order a member or an API key placed. actor is who SUBMITTED, never restamped — attribution of a cancel is a different question and neither field answers it. |
> side | string | Yes | One of UNKNOWN, BUY, SELL. |
> orderType | string | Yes | One of UNKNOWN, LIMIT, MARKET. |
> timeInForce | string | Yes | GTD is reserved and never appears on this wire in v1. One of UNKNOWN, GTC, IOC, FOK, GTD. |
> postOnly | boolean | Yes | |
> reduceOnly | boolean | Yes | Whether the order was placed reduce-only (submitOrder’s reduceOnly). |
> price | string, nullable | Yes | Exact decimal at the record’s price scale, trailing zeros kept. Null for a MARKET order, which has no price rather than a zero one. |
> qty | string | Yes | |
> status | string | Yes | Do NOT bucket on this. A status appended to the platform’s schema later is a value you have not heard of; bucket on live and terminal, which arrive already set for it. One of UNKNOWN, QUEUED, INSTRUCTED, OPEN, PARTIALLY_FILLED, FILLED, CANCELED, REJECTED, EXPIRED, INSTRUCTION_EXPIRED, EXPIRED_UNCONFIRMED, NOT_FOUND_AT_VENUE. |
> live | boolean | Yes | |
> terminal | boolean | Yes | |
> cancelRequested | boolean | Yes | Live, with a cancel in flight — a fact about an order, not a different kind of order. |
> transition | string | Yes | Advisory. On a snapshot row it reads SNAPSHOT: the durable transition belongs to a fact, and a snapshot is not one. One of UNKNOWN, SUBMITTED, INSTRUCTED, ACKNOWLEDGED, OPENED, TRADE, CANCEL_REQUESTED, CANCEL_REJECTED, CANCELED, REJECTED, EXPIRED, INSTRUCTION_EXPIRED, EXPIRED_UNCONFIRMED, NOT_FOUND_AT_VENUE, RECONCILE_REQUESTED, RESTATED, SNAPSHOT. |
> reason | string, nullable | Yes | Null when the record states no reason. One of USER_REQUESTED, VENUE_INITIATED, POST_ONLY_WOULD_CROSS, MMP, SELF_TRADE_PREVENTED, IOC_REMAINDER, FOK_UNFILLED, UNSUPPORTED_AT_VENUE, VENUE_REJECTED, INSTRUCTION_FRESHNESS_EXPIRED, RECONCILE_PROOF, OWNER_TIMEOUT, VENUE_REFERENCE_MISSING. |
> venueCode | integer, nullable | Yes | |
> message | string, nullable | Yes | The platform’s own words for reason — display text, null exactly when reason is null. Branch on reason, the stable name; this sentence may be reworded in any release and carries no numbers. Show it beside venueText, never instead of it. The two are different voices: this one is the platform’s, venueText is the venue’s. Where the venue is the one that decided — VENUE_REJECTED above all — this reads “the venue rejected this order” and the venue’s own text holds why (“insufficient margin”). A client that rendered one or the other would hide the informative half exactly when it mattered. Render message, and render venueText after it when it is present. |
> venueText | string, nullable | Yes | Whatever the venue said, verbatim — the venue’s voice, never the platform’s. Display it; do not parse it. Null whenever no venue said anything, which includes every reason the platform decides for itself (OWNER_TIMEOUT, INSTRUCTION_FRESHNESS_EXPIRED, RECONCILE_PROOF): for those, message is the only text there is. |
> cumQty | string | Yes | |
> leavesQty | string | Yes | |
> avgPx | string, nullable | Yes | Null with no fills. |
> lastFillQty | string, nullable | Yes | |
> lastFillPx | string, nullable | Yes | |
> venueCumQty | string, nullable | Yes | Null means the venue never reported a cumulative. A reported cumulative of zero is a value, and says something different. |
> executionsComplete | boolean | Yes | |
> acceptedAtNs | string, nullable | Yes | Epoch-ns as a decimal string; null when the stamp is unset. |
> instructedAtNs | string, nullable | Yes | |
> cancelRequestedAtNs | string, nullable | Yes | |
> venueTsNs | string, nullable | Yes | |
> tradingPolicyId | integer, nullable | Yes | |
> tradingPolicyVersion | string, nullable | Yes | |
> venueOrderId | string, nullable | Yes | The venue’s own id for the order; null before the venue names one. |