GET
/
v1
/
swaps
Get Swaps
curl --request GET \
  --url https://api.amm.flashnet.xyz/v1/swaps
{
  "swaps": [
    {
      "amountIn": "1000000",
      "amountOut": "500000",
      "assetInAddress": "66471063147ab9f53515bf18d1cea9a8ad166840ba9de93d46018d7007426e17",
      "assetOutAddress": "020202020202020202020202020202020202020202020202020202020202020202",
      "createdAt": "2025-01-15T10:30:00Z",
      "feePaid": "5000",
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "inboundTransferId": "550e8400-e29b-41d4-a716-446655440001",
      "outboundTransferId": "550e8400-e29b-41d4-a716-446655440001",
      "poolAssetAAddress": "66471063147ab9f53515bf18d1cea9a8ad166840ba9de93d46018d7007426e17",
      "poolAssetBAddress": "020202020202020202020202020202020202020202020202020202020202020202",
      "poolLpPublicKey": "0315299b3f9f4e2beb8576ea2bf72ea1bc741eb255bfc3f6387de4d47b5c05972d",
      "poolType": "CONSTANT_PRODUCT",
      "price": "0.5",
      "swapperPublicKey": "03a1b2c3d4e5f6789012345678901234567890123456789012345678901234567890"
    }
  ],
  "totalCount": 1500
}

Query Parameters

limit
integer | null
default:20

Maximum number of swaps to return in the response. Helps manage response size when dealing with large swap volumes.

Required range: 1 <= x <= 100
offset
integer | null
default:0

Number of swaps to skip before starting to collect results. Used for paginating through large result sets.

Required range: x >= 0
pool_type
string | null

Filter by pool type (CONSTANT_PRODUCT or SINGLE_SIDED). If not specified, returns swaps from all pool types.

asset_address
string | null

Filter by asset address (will match either input or output asset). Useful for finding all swaps involving a specific asset.

start_time
string | null

Start timestamp (inclusive) in RFC3339 format.

end_time
string | null

End timestamp (inclusive) in RFC3339 format.

Response

200
application/json

Global swap history retrieved successfully

Response for listing global swaps