Skip to main content

getAskOrderIds

Retrieves a paginated array of unsigned 6464-bit order identifiers for active sell-side (ask) orders matching a specific Totem-currency pair, sorted by price ascending.


Endpoint Details

  • HTTP Method: POST
  • Gateway Path: /nxt
  • Content-Type: application/x-www-form-urlencoded
  • API Tags: AE
  • Chain Specific: Yes

Request Parameters

ParameterTypeRequiredDescription
requestTypeStringYesMust be set to getAskOrderIds.
totemlong / StringYesUnique 6464-bit identifier of the Totem.
currencylong / StringYesUnique 6464-bit identifier of the payment currency.
chainintYesSovereign BetaChain ID.
firstIndexintNoZero-based start index for pagination. Default: 0.
lastIndexintNoEnd index for pagination. Default: -1.

Example Request

curl -X POST http://localhost:22024/nxt \
-d "requestType=getAskOrderIds" \
-d "chain=2" \
-d "totem=9876543210123456789" \
-d "currency=5544332211" \
-d "firstIndex=0" \
-d "lastIndex=10"

Successful Response

{
"askOrderIds": [
"88492019481029384",
"88492019481029385",
"88492019481029389"
]
}

Error Codes

Error CodeCause / Description
UNKNOWN_TOTEMTotem ID does not exist on the network.
UNKNOWN_CURRENCYCurrency ID does not exist on the specified BetaChain.
INCORRECT_CHAINInvalid or inactive BetaChain ID specified.