TradingView Chart

API docs
https://api.sandbase.ai/v1/api/tradingview/chart

Get recent OHLC bar data for a forex pair at the specified interval.

Price
$0.03USD / call
Method
POST
Response
JSON
Parameters
0 required · 4 optional

Playground

Input
Maximum number of bars to return (1-30). Fewer bars may be returned depending on available data.
Forex pair symbol (e.g., EURUSD, GBPUSD, USDJPY, AUDUSD, USDCAD, NZDUSD, EURGBP, EURJPY)
Exchange/data source (FX, OANDA, FX_IDC)
Bar interval/timeframe
OutputReady

Your output will appear here

Complete the inputs, then click Run.

API README

TradingView Chart API

Get recent OHLC bar data for a forex pair at the specified interval.

Request

curl -X POST "https://api.sandbase.ai/v1/run" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "tradingview/chart", "bars": 10, "symbol": "EURUSD", "exchange": "FX", "interval": "1m"}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
barsintegerNoMaximum number of bars to return (1-30). Fewer bars may be returned depending on available data.
exchangestringNoExchange/data source (FX, OANDA, FX_IDC) One of: FX, OANDA, FX_IDC.
intervalstringNoBar interval/timeframe One of: 1m, 5m, 15m, 1H, 4H, 1D, 1W.
symbolstringNoForex pair symbol (e.g., EURUSD, GBPUSD, USDJPY, AUDUSD, USDCAD, NZDUSD, EURGBP, EURJPY)

Pricing

Flat $0.03 per call. Failed calls are not charged.

Explore more

Related APIs

All APIs
APIPriceResponse
TradingView$0.03 per callJSON
TradingView$0.03 per callJSON
TradingView$0.03 per callJSON
TradingView$0.03 per callJSON

Questions

FAQ

How do I use the TradingView Chart API?

Send a POST request to https://api.sandbase.ai/v1/api/tradingview/chart with your SandBase API key in the Authorization header (Bearer) and the parameters as a JSON body. You can also try it in the Playground on this page without writing code.

How much does the TradingView Chart API cost?

$0.03 per call, billed from your SandBase balance. You are only charged for calls you make; there is no subscription.

What parameters does the TradingView Chart API accept?

No parameters are required. Optional: bars (integer), symbol (string), exchange (one of FX, OANDA, FX_IDC) and interval (one of 1m, 5m, 15m, 1H, 4H, 1D, 1W). The Parameters table and the Playground on this page list every field.

What does the TradingView Chart API return?

A JSON response returned in the same HTTP request (synchronous).

Do I need a TradingView developer account or API key?

No. TradingView Chart runs through SandBase, so one SandBase API key covers this endpoint and every other API and model in the catalog. You do not need to apply for TradingView API access separately.