Docs
Search⌘ K
  • Home
  • About The Graph
  • Supported Networks
  • Protocol Contracts
  • Subgraphs
    • Substreams
      • Token API
        • Hypergraph
          • AI Suite
            • Indexing
              • Graph Horizon
                • Resources
                  Token API > SVM DEX Endpoints

                  Pool OHLCV Data

                  GET/v1/svm/pools/ohlc

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

                  Query Parameters

                  ParameterDescriptionValue
                  network
                  string

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

                  • Accepted values: solana
                  Required
                  solana
                  amm_pool
                  string

                  Filter by AMM pool address

                  • Accepted pattern: ^[1-9A-HJ-NP-Za-km-z]{32,44}$
                  • Format: svm-address
                  Required
                  interval
                  string

                  The interval* for which to aggregate price data (1-minute, 5-minutes, 10-minutes, 30-minutes, hourly, 4-hours, daily or weekly).
                  *Plan restricted.

                  • Default value: 1d
                  • Accepted values: 1m, 5m, 10m, 30m, 1h, 4h, 1d, 1w
                  1d
                  start_time
                  string

                  UNIX timestamp in seconds or date string (e.g. "2025-01-01T00:00:00Z", "2025-01-01", ...).

                    end_time
                    string

                    UNIX timestamp in seconds or date string (e.g. "2025-01-01T00:00:00Z", "2025-01-01", ...).

                      limit
                      integer

                      Number of items* returned in a single request.
                      *Plan restricted.

                      • Default value: 10
                      • Minimum value: 1
                      • Maximum value: 1000
                      page
                      integer

                      Page number to fetch.
                      Empty data array signifies end of results.

                      • Default value: 1
                      • Minimum value: 1
                      • Maximum value: 767465558638

                      Potential Responses

                      StatusDescription
                      200

                      Successful Response

                      400

                      Client side error

                      401

                      Authentication failed

                      403

                      Forbidden

                      404

                      Not found

                      500

                      Server side error

                      ⁠Edit on GitHub⁠

                      Liquidity PoolsSwap Events
                      Test this endpoint

                      1curl --request GET \2  --url 'https://token-api.thegraph.com/v1/svm/pools/ohlc?network=solana&amm_pool=AmmpSnW5xVeKHTAU9fMjyKEMPgrzmUj3ah5vgvHhAB5J&interval=1d&limit=10&page=1' \3  --header 'Authorization: Bearer {token}'

                      1{2  "data": [3    {4      "datetime": "2025-07-03 00:00:00",5      "amm": "pAMMBay6oceH9fJKBRHGP5D4bD4sWpmSwMn52FMfXEA",6      "amm_pool": "AmmpSnW5xVeKHTAU9fMjyKEMPgrzmUj3ah5vgvHhAB5J",7      "token0": "GfMuixkXCBb612QNnPUTG696mn3R7ptnvsK31KN1e3q9",8      "token0_decimals": 9,9      "token1": "So11111111111111111111111111111111111111112",10      "token1_decimals": 9,11      "open": 0.12678061315003716,12      "high": 0.12836499025514422,13      "low": 0.12403664449646414,14      "close": 0.12422606595970508,15      "volume": 0.029977608000000003,16      "uaw": 1,17      "transactions": 918    }19  ]20}
                      The GraphStatusTestnetBrand AssetsForumSecurityPrivacy PolicyTerms of Service