---
title: "public/get_tradingview_chart_data"
method: POST
path: "/public/get_tradingview_chart_data"
tags: ["Market Data"]
---

# public/get_tradingview_chart_data

`POST /public/get_tradingview_chart_data`

## Request

- Base URL: `https://api.derive.xyz/v3`
- URL: `https://api.derive.xyz/v3/public/get_tradingview_chart_data`
- Auth: none declared

Returns traded-price OHLCV candles for an `instrument_name` between required `start_timestamp` and `end_timestamp` (UTC seconds) at the given `period` (1m up to 1w), aggregated from executed trade history. Each candle includes open/high/low/close prices plus USD and contract volume, formatted for charting. Public endpoint.

## Request body

- GetTradingviewChartDataRequest: Parameters for `public/get_tradingview_chart_data`. Numeric fields accept either a JSON number or a string-encoded integer. Timestamps are UTC seconds.
  - `end_timestamp` integer, required
  - `instrument_name` string, required
  - `period` integer, required
  - `start_timestamp` integer, required

## Response `200`

Success

- TradingviewCandle[]
  - `close_price` string, required
  - `high_price` string, required
  - `low_price` string, required
  - `open_price` string, required
  - `timestamp` integer, required
  - `timestamp_bucket` integer, required
  - `volume_contracts` string, required
  - `volume_usd` string, required

## Other responses

- `default`: JSON-RPC error (see Error Codes)

## Changes

- **2026-10-20** `0c500202be49`: 1 info
  - added the media type `application/json` for the response with the status `default`

[Operation history](https://skmtc.dev/lyra/apis/derive-v3-api/changes/public/get_tradingview_chart_data/post.md)

---

[API](https://skmtc.dev/lyra/apis/derive-v3-api.md) - [All operations](https://skmtc.dev/lyra/apis/derive-v3-api/llms.txt) - [OpenAPI document](https://skmtc.dev/lyra/apis/derive-v3-api/revisions/415f8a73b10c?raw)
