Docs
搜索⌘ K
  • 主页
  • 关于 The Graph
  • 支持的网络
  • 协议合约
  • 子图
    • 子流
      • 代币 API
        • Hypergraph
          • AI Suite
            • 索引
              • 资源
                代币 API > EVM端点

                OHLCV by Pool

                GET/ohlc/pools/evm/{pool}

                Provides pricing data in the Open/High/Low/Close/Volume (OHCLV) format.

                路径参数

                参数描述值
                pool
                string

                Filter by pool address

                  必填

                  查询参数

                  参数描述值
                  network_id
                  string

                  The Graph Network ID for EVM networks https://thegraph.com/networks

                  • 默认值: mainnet
                  • 可选值: arbitrum-one, avalanche, base, bsc, mainnet, matic, optimism, unichain
                  必填
                  mainnet
                  interval

                  The interval for which to aggregate price data (hourly, 4-hours, daily or weekly).

                    startTime
                    integer

                    UNIX timestamp in seconds.

                    • 默认值: 1735689600
                    • 最小值: -9007199254740991
                    • 最大值: 9007199254740991
                    endTime
                    integer

                    UNIX timestamp in seconds.

                    • 默认值: 9999999999
                    • 最小值: -9007199254740991
                    • 最大值: 9007199254740991
                    limit
                    integer

                    The maximum number of items returned in a single request.

                    • 默认值: 10
                    • 最小值: 1
                    • 最大值: 1000
                    page
                    integer

                    The page number of the results to return.

                    • 默认值: 1
                    • 最小值: 1
                    • 最大值: 767465558638

                    可能的反应

                    状态描述
                    200Successful Response
                    400Client side error
                    401Authentication failed
                    403Forbidden
                    404Not found
                    500Server side error
                    ⁠在GitHub上编辑⁠

                    按合约地址列出的代币OHLCV价格Supported DEXs
                    测试此终点

                    1curl --request GET \2  --url 'https://token-api.thegraph.com/ohlc/pools/evm/{pool}?network_id=mainnet&startTime=1735689600&endTime=9999999999&limit=10&page=1' \3  --header 'Authorization: Bearer {token}'

                    1{2  "data": [3    {4      "datetime": "2025-05-29 15:00:00",5      "ticker": "WETHUSDC",6      "open": 2674.206768283323,7      "high": 2674.206768283323,8      "low": 2648.1288363948797,9      "close": 2648.1288363948797,10      "volume": 5062048.294222999,11      "transactions": 16912    }13  ]14}
                    The GraphStatusTestnetBrand AssetsForum安全Privacy PolicyTerms of Service