Detailed Pairs Stats

Endpoint: getDetailedPairsStats

Method: POST

Arguments

NameTypeDescription
input[GetDetailedPairsStatsInput!]!

Required

NameTypeDescription
bucketCountInt

The number of aggregated values to receive. Note: Each duration has predetermined bucket sizes.
The first n-1 buckets are historical. The last bucket is a snapshot of current data.
duration day1: 6 buckets (4 hours each) plus 1 partial bucket
duration hour12: 12 buckets (1 hour each) plus 1 partial bucket
duration hour4: 8 buckets (30 min each) plus 1 partial bucket
duration hour1: 12 buckets (5 min each) plus 1 partial bucket
duration min5: 5 buckets (1 min each) plus 1 partial bucket
For example, requesting 11 buckets for a min5 duration will return the last 10 minutes worth of data plus a snapshot for the current minute.

durations[DetailedPairStatsDuration]

The list of durations to get detailed pair stats for.

networkIdInt!

The network ID the pair is deployed on.

Required
pairAddressString!

The contract address of the pair.

Required
statsTypeTokenPairStatisticsType

The type of statistics returned. Can be FILTERED or UNFILTERED

timestampInt

The unix timestamp for the stats. Defaults to current.

tokenOfInterestTokenOfInterest

The token of interest used to calculate token-specific stats for the pair. Can be token0 or token1.

Response

NameTypeDescription
bucketCountIntNumber of aggregated buckets specified in input
lastTransactionIntThe unix timestamp for the last transaction to happen on the pair.
networkIdInt!The network ID the pair is deployed on.
pairPair
pairAddressString!The contract address of the pair.
queryTimestampIntThe timestamp specified as input to the query
stats_day1WindowedDetailedPairStatsThe breakdown of stats over a 24 hour window.
stats_day30WindowedDetailedPairStatsThe breakdown of stats over a 30 day window.
stats_hour1WindowedDetailedPairStatsThe breakdown of stats over an hour window.
stats_hour4WindowedDetailedPairStatsThe breakdown of stats over a 4 hour window.
stats_hour12WindowedDetailedPairStatsThe breakdown of stats over a 12 hour window.
stats_min5WindowedDetailedPairStatsThe breakdown of stats over a 5 minute window.
stats_min15WindowedDetailedPairStatsThe breakdown of stats over a 15 minute window.
stats_week1WindowedDetailedPairStatsThe breakdown of stats over a 7 day window.
statsTypeTokenPairStatisticsType!The type of statistics returned. Can be FILTERED or UNFILTERED
tokenOfInterestTokenOfInterestThe token of interest used to calculate token-specific stats.