Expand description
Data transfer objects for deserializing OKX HTTP API payloads.
Structsยง
- OKXAccount
- Represents an account balance snapshot from
GET /api/v5/account/balance
. - OKXBalance
Detail - Represents a balance detail for a single currency in an OKX account.
- OKXCancel
Algo Order Request - Represents the request body for
POST /api/v5/trade/cancel-algos
(cancel algo order). - OKXCancel
Algo Order Response - Represents the response from
POST /api/v5/trade/cancel-algos
(cancel algo order). - OKXCandlestick
- Represents a candlestick from the GET /api/v5/market/history-candles endpoint. The tuple contains [timestamp(ms), open, high, low, close, volume, turnover, base_volume, count].
- OKXFee
Rate - Represents a fee rate entry from
GET /api/v5/account/trade-fee
. - OKXIndex
Ticker - Represents an index price from the GET /api/v5/public/index-tickers endpoint.
- OKXMark
Price - Represents a mark price from the GET /api/v5/public/mark-price endpoint.
- OKXOrder
Algo - Represents an algo order response from
/trade/order-algo-*
endpoints. - OKXOrder
History - Represents a single historical order record from
GET /api/v5/trade/orders-history
. - OKXPlace
Algo Order Request - Represents the request body for
POST /api/v5/trade/order-algo
(place algo order). - OKXPlace
Algo Order Response - Represents the response from
POST /api/v5/trade/order-algo
(place algo order). - OKXPlace
Order Response - Represents the response from
POST /api/v5/trade/order
(place order). This model is designed to be flexible and handle the minimal fields that the API returns. - OKXPosition
- Represents a single open position from
GET /api/v5/account/positions
. - OKXPosition
History - Represents a single historical position record from
GET /api/v5/account/positions-history
. - OKXPosition
Tier - Represents a position tier from the GET /api/v5/public/position-tiers endpoint.
- OKXServer
Time - Represents the response from
GET /api/v5/public/time
(get system time). - OKXTrade
- Represents a trade tick from the GET /api/v5/market/trades endpoint.
- OKXTransaction
Detail - Represents a transaction detail (fill) from
GET /api/v5/trade/fills
.