amm
List swap events for a pool
get
/liquidity/swaps
operationId: pool-listSwaps

Returns swap events for the given pool, ordered newest-first. Each row captures the signed asset1 / asset2 amount changes for the swap.

Unlock protected endpoints

Enter your Bearer token once to enable every protected route in this API reference.

HTTP bearer

Saved for this browser tab only. The credential is never sent until you test an endpoint.

Authorizations
NameLocationDetails
BearerAuthAuthorization header · bearerJWT issued by the Honeycluster auth service for the `indexer` audience. Present as `Authorization: Bearer <token>`.
Query Parameters
NameTypeDefaultDescription
cursor
string
limit
integer20
poolId
required
string
Liquidity pool identifier (UUID v4).
Responses
200
application/json
Successful response
FieldTypeDescription
items
object[]
Page of results.
items[].id
string
UUID — part of the composite PK (id, timestamp).
items[].poolId
string
Parent liquidity_data.id.
items[].txHash
string
Transaction hash of the pool event.
items[].ledgerIndex
integer
Ledger sequence of the event.
items[].timestamp
integer
When the event occurred on-ledger, Unix-seconds.
items[].eventType
string
Event kind: `deposit` | `withdraw` | `swap` | `vote`.
items[].account
string
XRPL address that triggered the event.
items[].asset1Amount
object
items[].asset2Amount
object
items[].asset1ReserveAfter
object
items[].asset2ReserveAfter
object
items[].lpTokenAmount
object
items[].tradingFee
object
items[].createdAt
integer
Record creation timestamp, Unix-seconds.
nextCursor
object
Cursor to fetch the next page, or null if this is the last page.
Example
Json
{
  "items": [
    {
      "id": "00000000-0000-0000-0000-000000000000",
      "poolId": "00000000-0000-0000-0000-000000000000",
      "txHash": "string",
      "ledgerIndex": 0,
      "timestamp": 1745798400,
      "eventType": "string",
      "account": "string",
      "asset1Amount": "string",
      "asset2Amount": "string",
      "asset1ReserveAfter": "string",
      "asset2ReserveAfter": "string",
      "lpTokenAmount": "string",
      "tradingFee": 0,
      "createdAt": 1745798400
    }
  ],
  "nextCursor": "string"
}
400
application/json
Invalid input data
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "BAD_REQUEST",
  "message": "Invalid input data",
  "issues": []
}
401
application/json
Authorization not provided
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "UNAUTHORIZED",
  "message": "Authorization not provided",
  "issues": []
}
403
application/json
Insufficient access
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "FORBIDDEN",
  "message": "Insufficient access",
  "issues": []
}
404
application/json
Not found
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "NOT_FOUND",
  "message": "Not found",
  "issues": []
}
500
application/json
Internal server error
FieldTypeDescription
message
string
The error message
code
string
The error code
issues
object[]
An array of issues that were responsible for the error
issues[].message
string
Example
Json
{
  "code": "INTERNAL_SERVER_ERROR",
  "message": "Internal server error",
  "issues": []
}