wss://honeycluster.iobook_offersReturns the current offers in a given order book (the DEX exchange rates between two currencies).
{
"result": {
"ledger_index": 89012345,
"offers": [
{
"Account": "rG1QQv2nh2gr7RCZ1P8YYcBUKCCN633jCn",
"BookDirectory": "7E5F614417C2D0A7CEFEB73C4AA773ED5B078DE2B5771F6D5505DCAA",
"Flags": 0,
"OwnerNode": "0",
"TakerGets": "5000000",
"TakerPays": {
"currency": "USD",
"issuer": "rPT1Sjq2YGrBMTttX4GZHjKu9dyfzbpAYe",
"value": "2.5"
},
"quality": "0.0000005"
}
]
},
"status": "success",
"type": "response",
"id": 1
}| Field | Type | Description |
|---|---|---|
commandrequired | string | WebSocket command name |
id | object | Client-supplied identifier to correlate requests with responses. |
taker_gets | object | The currency the taker would receive (the "ask" side). |
taker_gets.required | string | Three-letter ISO 4217 currency code, or 160-bit hex currency code. |
taker_gets. | string | Account address of the token issuer. Omit for XRP. |
taker_pays | object | The currency the taker would pay (the "bid" side). |
taker_pays.required | string | Three-letter ISO 4217 currency code, or 160-bit hex currency code. |
taker_pays. | string | Account address of the token issuer. Omit for XRP. |
taker | string | Account address to use as a perspective for unfunded offers. |
limit | integer | Maximum number of results to return. Clio servers may return more than this. |
ledger_index | object | A ledger index (sequence number) or shortcut string identifying which ledger to use. |
ledger_hash | string | 256-bit hex hash identifying a specific ledger version. |
api_version | object | API version for the response format. Version 2 is the default for rippled 2.0+. |
{
"command": "book_offers",
"id": 1,
"taker_gets": {
"currency": "XRP"
},
"taker_pays": {
"currency": "USD",
"issuer": "rPT1Sjq2YGrBMTttX4GZHjKu9dyfzbpAYe"
},
"limit": 10
}| Field | Type | Description |
|---|---|---|
result | object | |
status | enum<string> | Available successerror |
type | string | |
id | stringnumber | Echo of the client-provided correlation ID |
{
"result": {
"ledger_index": 89012345,
"offers": [
{
"Account": "rG1QQv2nh2gr7RCZ1P8YYcBUKCCN633jCn",
"BookDirectory": "7E5F614417C2D0A7CEFEB73C4AA773ED5B078DE2B5771F6D5505DCAA",
"Flags": 0,
"OwnerNode": "0",
"TakerGets": "5000000",
"TakerPays": {
"currency": "USD",
"issuer": "rPT1Sjq2YGrBMTttX4GZHjKu9dyfzbpAYe",
"value": "2.5"
},
"quality": "0.0000005"
}
]
},
"status": "success",
"type": "response",
"id": 1
}