Query Limit Order Status in DEX API

ยท

Overview

Query the status of a limit order on a decentralized exchange (DEX) using this API endpoint.

Endpoint

GET https://web3.okx.com/api/v5/dex/aggregator/limit-order/detail

Request Parameters

ParameterTypeRequiredDescription
orderHashStringYesPost-signature data

Response Parameters

ParameterTypeDescription
createTimestringOrder creation timestamp
expireTimestringOrder expiration deadline
failureReasonstringError message (if applicable)
orderHashstringPost-signature data
signaturestringWallet-signed data
chainIdstringBlockchain ID (e.g., 1 for Ethereum)
makerAssetAddressstringOrder creator's wallet address
makerTokenAddressstringSold token contract address
makingAmountstringAmount of sold tokens
takerTokenAddressstringPurchased token contract address
takingAmountstringAmount of purchased tokens
makerRatestringtakingAmount/makingAmount
takerRatestringmakingAmount/takingAmount
receiverstringDefault: zero address. If set, assets route to specified address
remainingMakerAmountstringRemaining tradable quantity
saltstringRandom nonce for idempotency (current timestamp in seconds)
statusstringOrder status (1โ€“7; see details below)
takerAssetAddressstringDefault: zero address. If set, order executes only at specified address

Order Status Codes

  1. Active
  2. Temporarily inactive
  3. Processing on-chain
  4. Expired
  5. Cancelled
  6. Successful
  7. Failed

๐Ÿ‘‰ Explore advanced DEX trading strategies

FAQ

How do I find my orderHash?

The orderHash is generated after signing the order data via your wallet. Check your transaction logs or API response from order placement.

What chain IDs are supported?

Refer to the official chain ID list. Common examples include Ethereum (1) and BSC (56).

Can I modify a limit order after submission?

No. DEX limit orders are immutable once signed. To change terms, cancel the existing order and create a new one.