POST/data/v2/protocol-stats
Auth X-Hub-Key from API_HUB_KEYExecute
POST /run/uniswap/data/v2/protocol-statsCache executed live on every call — a read-only POST answer is never cachedCost free · weight 0 · standard rate classSource billing freeAggregate Uniswap TVL, 24h volume, and 1d changes broken down by v2, v3 and v4.
Try this endpoint
Reads the credential from API_HUB_KEY; it never appears in the URL.
curl -sX POST "https://openapihub.dev/run/uniswap/data/v2/protocol-stats" \
-H "X-Hub-Key: $API_HUB_KEY" -H "Content-Type: application/json" \
-d '{"chainIds": [1, 8453, 42161, 10, 137, 56, 130], "protocolVersions": ["PROTOCOL_VERSION_V2", "PROTOCOL_VERSION_V3", "PROTOCOL_VERSION_V4"]}'Parameters
| name | in | type | description | |
|---|---|---|---|---|
chainIds | body | list[int] | required | List of chain IDs to include in protocol totals. example: [1,8453,42161,10,137,56,130] |
protocolVersions | body | list[str] | required | Protocol versions to include: PROTOCOL_VERSION_V2, PROTOCOL_VERSION_V3, PROTOCOL_VERSION_V4. example: ["PROTOCOL_VERSION_V2","PROTOCOL_VERSION_V3","PROTOCOL_VERSION_V4"] |
Response
type: object
data key: protocolVersionStats
pagination: none
sample: {
"asOf": "str",
"stats": {
"tvl": "float",
"volume1d": "float",
"tvlChange1d": "float",
"volumeChange1d": "float"
},
"protocolVersionStats": "array[3]"
}