Get AMM pool balance snapshot

Rate limit: every seconds

API Overview


HTTP method

GET

Path

/api/v3/amm/balance

Summary

Returns the snapshot of specific AMM pool

API description


HTTP Header

Field Type Required Description Example
X-API-KEY string Y ApiKey "HlkcGxbqBeaF76j4rvPaOasyfPwnkQ
6B6DQ6THZWbvrAGxzEdulXQvOKLrRW
ZLnN"

Request parameters

Field Type Required Description Example
poolAddress string Y input AMM pool address "0xbbbbca6a901c926f24
0b89eacb641d8aec7aea
fd"

Request example

HTTP
CURL
GET https://api3.loopring.io/api/v3/amm/balance?poolAddress=0xbbbbca6a901c926f240b89eacb641d8aec7aeafd HTTP/1.1
Host: api3.loopring.io
Connection: keep-alive
Accept: */*
Accept-Encoding: gzip, deflate, br
Accept-Language: zh,en;q=0.9
X-API-KEY: sra1aavfa
curl -H "X-API-KEY:sra1aavfa" https://api3.loopring.io/api/v3/amm/balance\?poolAddress\=0xbbbbca6a901c926f240b89eacb641d8aec7aeafd

Response fields

Field Type Required Description Example
poolName string Y field.AmmSnapshot.poolName "AMM-LRC-ETH"
poolAddress string Y field.AmmSnapshot.poolAddress "0xbbbbca6a901c926f24
0b89eacb641d8aec7aea
fd"
pooled List[TokenVolumeV3] Y AMM in pool tokens balances "[{tokenId: 0, volume:1000000000}, {tokenId: 1, volume:1000000000}]"
lp TokenVolumeV3 Y AMM pool mint token balance "{tokenId: 0, volume:1000000000}"
risky boolean Y AMM pool risky flag, true if AMM pool TVL is low which means big slippage. "false"

Response example

{
    "poolName" : "AMM-LRC-ETH",
    "poolAddress" : "0xbbbbca6a901c926f240b89eacb641d8aec7aeafd",
    "pooled" : [{tokenId: 0, volume:1000000000}, {tokenId: 1, volume:1000000000}],
    "lp" : {
        "tokenId" : "0",
        "volume" : "1000000000000"
    },
    "risky" : false
}

Status code

Value Description
100000 Unknown error

Model


TokenVolumeV3

Wrapper object used to describe a token associated with a certain quantity.

Field Type Required Description Example
tokenId string Y The Loopring's token identifier. "0"
volume string Y The volume of the token "1000000000000"

results matching ""

    No results matching ""