import { APIResource } from "../../core/resource.js"; import { APIPromise } from "../../core/api-promise.js"; import { RequestOptions } from "../../internal/request-options.js"; export declare class MarketChart extends APIResource { /** * To get the historical chart data of a coin including time in UNIX, price, market * cap and 24hrs volume based on particular coin ID */ get(id: string, query: MarketChartGetParams, options?: RequestOptions): APIPromise; /** * To get the historical chart data of a coin within certain time range in UNIX * along with price, market cap and 24hrs volume based on particular coin ID */ getRange(id: string, query: MarketChartGetRangeParams, options?: RequestOptions): APIPromise; } export interface MarketChartGetResponse { /** * Market cap data points as [timestamp, market_cap] pairs */ market_caps: Array>; /** * Price data points as [timestamp, price] pairs */ prices: Array>; /** * Total volume data points as [timestamp, volume] pairs */ total_volumes: Array>; } export interface MarketChartGetRangeResponse { /** * Market cap data points as [timestamp, market_cap] pairs */ market_caps: Array>; /** * Price data points as [timestamp, price] pairs */ prices: Array>; /** * Total volume data points as [timestamp, volume] pairs */ total_volumes: Array>; } export interface MarketChartGetParams { /** * Data up to number of days ago. You may use any integer or `max` for number of * days. */ days: string; /** * Target currency of market data. \*refers to * [`/simple/supported_vs_currencies`](/reference/simple-supported-currencies). */ vs_currency: string; /** * Data interval, leave empty for auto granularity. */ interval?: '1m' | '5m' | 'hourly' | 'daily'; /** * Decimal place for currency price value. */ precision?: 'full' | '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | '13' | '14' | '15' | '16' | '17' | '18'; } export interface MarketChartGetRangeParams { /** * Starting date in ISO date string (`YYYY-MM-DD` or `YYYY-MM-DDTHH:MM`) or UNIX * timestamp. **Use ISO date string for best compatibility.** */ from: string; /** * Ending date in ISO date string (`YYYY-MM-DD` or `YYYY-MM-DDTHH:MM`) or UNIX * timestamp. **Use ISO date string for best compatibility.** */ to: string; /** * Target currency of market data. \*refers to * [`/simple/supported_vs_currencies`](/reference/simple-supported-currencies). */ vs_currency: string; /** * Data interval, leave empty for auto granularity. */ interval?: '1m' | '5m' | 'hourly' | 'daily'; /** * Decimal place for currency price value. */ precision?: 'full' | '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | '13' | '14' | '15' | '16' | '17' | '18'; } export declare namespace MarketChart { export { type MarketChartGetResponse as MarketChartGetResponse, type MarketChartGetRangeResponse as MarketChartGetRangeResponse, type MarketChartGetParams as MarketChartGetParams, type MarketChartGetRangeParams as MarketChartGetRangeParams, }; } //# sourceMappingURL=market-chart.d.ts.map