Marketplace
No threads yet
Live

get_forex_ohlc_bars

tradingview.com

Gets recent OHLC bar data for a forex symbol from https://www.tradingview.com at a requested interval. Returns the current requested-interval bar plus recent daily bars when available, sorted by timestamp ascending, with bars_count treated as an upper bound.

Parameters4
Runs9
Updated8d ago
Operational9 runs · 100% succeeded
30 days agotoday

Playground

Runs on Notte and spends your workspace credits — what comes back is the live response, not a sample.

What is get_forex_ohlc_bars?

Gets recent OHLC bar data for a forex symbol from https://www.tradingview.com at a requested interval. Returns the current requested-interval bar plus recent daily bars when available, sorted by timestamp ascending, with bars_count treated as an upper bound. It runs on Notte's browser infrastructure and returns structured JSON, so you can call it like any other API — pass symbol, interval, bars_count, timeout_seconds and get the result back without maintaining a scraper.

Response

{
  "bars": [
    {
      "low": 0,
      "high": 0,
      "open": 0,
      "close": 0,
      "interval": "<string>",
      "timestamp": 0,
      "timestamp_iso": "<string>"
    }
  ],
  "source": "<string>",
  "symbol": "<string>",
  "requested_interval": "<string>",
  "bars_count_returned": 0,
  "bars_count_requested": 0
}

Call it

curl --location 'https://us-prod.notte.cc/functions/e5c55e6b-4f5f-459e-853e-5793e5c2aa13/runs/start' \
--header 'x-notte-api-key: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--data '{
    "function_id": "e5c55e6b-4f5f-459e-853e-5793e5c2aa13",
    "variables": {
        "symbol": "DEFAULT_SYMBOL",
        "interval": "60",
        "bars_count": 5,
        "timeout_seconds": 20
    }
}'

Ask an agent

Paste this into Claude Code, Cursor or any MCP client to have an agent call this function for you.

prompt
Use the Anything API MCP server (https://anything.notte.cc/mcp).

Call run(function_id="e5c55e6b-4f5f-459e-853e-5793e5c2aa13") — the "get_forex_ohlc_bars" function, which gets recent OHLC bar data for a forex symbol from https://www.tradingview.com at a requested interval. Returns the current requested-interval bar plus recent daily bars when available, sorted by timestamp ascending, with bars_count treated as an upper bound..

It takes symbol (str), interval (str), bars_count (int), timeout_seconds (int). Return the result as structured JSON.