Fetches historical OHLCV chart data for a specific token on the Ethereum network.
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
tokenAddress | string | Yes | The contract address of the token on Ethereum. | 0x6982508145454ce325ddbe47a25d4ec3d2311933 |
from | integer | Yes | The start timestamp (Unix seconds) for the data range. | 1678886400 |
to | integer | Yes | The end timestamp (Unix seconds) for the data range. | 1678972800 |
resolution | string | Yes | The chart resolution/interval (e.g., ‘1’, ‘5’, ‘15’, ‘60’, ‘D’, ‘W’, ‘M’). | 60 |
quoteToken | string | Yes | The token used for quoting the price (e.g., ‘ETH’, ‘USDC’). | ETH |
userID | string | Yes | The ID of the user requesting the data. | user-123 |
https://graph.defined.fi/graphql
).definedAPIKey
configured in the server’s ./config
.2400
.Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
The contract address of the token (e.g., on Ethereum or Base).
The start timestamp (Unix seconds) for the data range.
The end timestamp (Unix seconds) for the data range.
The chart resolution/interval.
1
, 5
, 15
, 60
, D
, W
, M
The token used for quoting the price.
The ID of the user requesting the data.
Successful retrieval of chart data
An array of OHLCV bar objects.