get AMM pool trade transactions

流量控制: 每 秒

摘要


HTTP 方法

GET

访问路径

/api/v3/amm/trades

功能

get AMM pool trade transactions

API 描述


HTTP头

请求参数

字段 类型 必须 说明 举例
ammPoolAddress string The address of the pool on which the swap was submitted. "0xbbbbca6a901c926f24
0b89eacb641d8aec7aea
fd"
limit integer Used to limit the number of returned records. Useful in implementing pagination. 50
offset integer Used to apply an offset when looking for valid records. Useful in implementing 0

请求示例

HTTP
CURL
GET https://api3.loopring.io/api/v3/amm/trades?ammPoolAddress=0xbbbbca6a901c926f240b89eacb641d8aec7aeafd&limit=50&offset=0 HTTP/1.1
Host: api3.loopring.io
Connection: keep-alive
Accept: */*
Accept-Encoding: gzip, deflate, br
Accept-Language: zh,en;q=0.9
curl https://api3.loopring.io/api/v3/amm/trades\?ammPoolAddress\=0xbbbbca6a901c926f240b89eacb641d8aec7aeafd\&limit\=50\&offset\=0

响应字段

字段 类型 必须 说明 举例
totalNum integer Number of trades 12345
trades List[AmmTradeDataV3] AMM trade list /

响应示例

{
    "totalNum" : 12345,
    "trades" : [
        {
            "accountId" : 12345,
            "orderHash" : "0xf7c932351186c3a9053f313eefa16209c018f7f1dba8aa8ca7100400f7c31085",
            "market" : "AMM-DAI-ETH",
            "side" : "BUY",
            "size" : "100000000",
            "price" : 0.03,
            "feeAmount" : "100000000",
            "createdAt" : 1608189538074
        }
    ]
}

状态码

状态码 描述
100000 Unknown error
107001 User ID cannot be empty
104001 Empty ApiKey
104002 Invalid ApiKey
104003 Invalid Account ID

模型


AmmTradeDataV3

AMM trade info data

字段 类型 必须 说明 举例
accountId integer trader's accountId 12345
orderHash string AMM trade's order hash "0xf7c932351186c3a905
3f313eefa16209c018f7
f1dba8aa8ca7100400f7
c31085"
market string The trade market "AMM-DAI-ETH"
side string The trade direction, buy or sell
取值范围 : ['BUY', 'SELL']
"BUY"
size string The trade volume "100000000"
price number The trade price 0.03
feeAmount string The trade fee "100000000"
createdAt integer The trade's creation time 1608189538074

results matching ""

    No results matching ""