GetAccountExchangeRequests
Retrieves exchange requests for a specific account, optionally filtered by currency or base currency.
Request
GET /nxt?requestType=get-account-exchange-requests
All endpoints use port 22024 by default.
Parameters
| Name | Type | Description | Required |
|---|---|---|---|
account | string | Account ID or SHAMWARI address | Yes |
currency | long | Filter by currency ID | Optional |
baseCurrency | long | Filter by base currency ID | Optional |
includeCurrencyInfo | boolean | Include currency metadata | Optional |
firstIndex | int | Pagination start index | Optional |
lastIndex | int | Pagination end index | Optional |
Response
{
"exchangeRequests": [
{
"exchangeRequest": {
"account": "1234567890",
"accountRS": "SHAMWARI-ABCD-EFGH-IJKL-MNOPQ",
"currency": "987654321",
"baseCurrency": "555555555",
"unitsQNT": "5000000000",
"rateQNTPerUnit": "500",
"height": 250
}
}
]
}
Response Fields
| Field | Type | Description |
|---|---|---|
account | string | Account ID |
accountRS | string | Account Reed-Solomon address in SHAMWARI format |
currency | string | Currency ID |
baseCurrency | string | Base currency ID |
unitsQNT | string | Number of units |
rateQNTPerUnit | string | Exchange rate |
height | int | Block height |
Error Codes
| Code | Description |
|---|---|
| 3 | Unknown account |
Example
curl "http://localhost:22024/nxt?requestType=get-account-exchange-requests&account=SHAMWARI-ABCD-EFGH-IJKL-MNOPQ"