Skip to main content
WSS
Place Order
type:object
Cancel Order
type:object
Cancel All Orders
type:object

Cancels every open order for (address, accountIndex). Pass marketId to scope the cancel to a single market; omit it to cancel across all markets. Untriggered TPSL orders in scope are canceled too. Mirrors POST /v1/cancelAllOrders.

Schedule Cancel
type:object

Dead man's switch. Arm, refresh, or disarm a cancel-all deadline. Mirrors POST /v1/scheduleCancel.

Keep the switch armed by sending a new time (updated absolute epoch microseconds, 5s–5min ahead of now — typically now + 60s) before the current deadline. Reusing a past time does not extend the previous arm. Omit time (or send null) to disarm. If the deadline elapses without a refresh, the gateway fires cancelAllOrders.

Omit marketId for an account-wide switch (fires cancel-all across every market), or set it to scope the switch to a single market. A per-market switch is independent of the account-wide switch and of other per-market switches on the same subaccount, and marketId selects which switch a given arm/refresh/disarm targets.

A wallet may hold only a bounded number of switches armed at once (across all subaccounts and markets); arming a new switch beyond that limit is rejected. Refreshing an already-armed switch is always allowed.

Modify Order
type:object
Batch Place Orders
type:object

Places up to 100 orders in one request. All orders must share the same address / accountIndex. Signed PER ELEMENT using the typed canonical payload: each element of orders carries its own signature over the same typed placeOrder payload the element would carry if submitted standalone (op=1 for regular orders, op=4 for TPSL legs). The request envelope carries only the shared apiKey + timestamp; there is no outer request.signature. Mirrors POST /v1/batchPlaceOrders.

Batch Cancel Orders
type:object

Cancels up to 100 orders in one request. All cancels must share the same address / accountIndex. Signed PER ELEMENT using the typed canonical payload: each element of cancels carries its own signature over the same typed cancelOrder payload the element would carry if submitted standalone. The request envelope carries only the shared apiKey + timestamp; there is no outer request.signature. Mirrors POST /v1/batchCancelOrders.

Batch Modify Orders
type:object

Modifies up to 100 resting orders in one request. All modifies must share the same address / accountIndex. Signed PER ELEMENT using the typed canonical payload: each element of modifies carries its own signature over the same typed modifyOrder payload the element would carry if submitted standalone (op=3). The request envelope carries only the shared apiKey + timestamp; there is no outer request.signature. Failures are per element — an element that fails validation or signature verification surfaces as a status: ERROR row in the response while the rest of the batch proceeds. Mirrors POST /v1/batchModifyOrders.

Set Leverage
type:object

Per-(account, market) leverage. Mirrors POST /v1/setLeverage. leverage is an integer in [1, market max]; values outside this range are rejected with 400. The WS path returns immediately on accept (envelope status: 202, body status: ACK); subscribe to the accountAttributes channel to observe the engine-confirmed outcome: an APPLIED change arrives as a leverage entry, a REJECTED one as a leverageReject entry (carrying the same requestId for correlation).

Adjust Isolated Margin
type:object

Move margin between the cross bucket and an isolated-mode position's leg for (account, market). Mirrors POST /v1/adjustIsolatedMargin. amount is dollars as a decimal string (e.g. "100" for $100) — do not send quote quantums; the gateway converts dollars to quantums for the engine. Positive adds to the leg (cross → isolated), negative removes from the leg (isolated → cross), zero is rejected with 400. The WS path returns immediately on accept (envelope status: 202, body status: ACK); the engine-confirmed post-state arrives on the positions channel as a PositionUpdate (correlated by requestId).

Get Snapshot (RPC)
type:object
RPC Response
type:object

Response to a post or get request. id is always echoed from the request. Order mutations reply with status: 202 (accepted, not terminal). Other methods reply with status: 200 on success.