TVControl
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| tv_health_checkB | Check CDP, TradingView market-data connection, compatibility, and current chart state |
| tv_chart_healthA | Check whether each chart pane has a live data session. Finds the failure where ONE pane sits in a reconnect loop forever while the rest of the layout is fine: a study whose id never registered with the server kills that pane's session on every reconnect, and the pane cannot recover on its own. Read-only. Use tv_repair_chart to fix what this reports. |
| tv_repair_chartA | Repair a chart pane stuck in a reconnect loop, without rebuilding the layout. Removes the studies whose id never registered with the server (they are what kill the session on every reconnect) and reconnects the pane. Names every study it removes so you can add them back with indicator_add_from_search. Run tv_chart_health first, or pass dry_run to see the plan. |
| tv_discoverA | Report which known TradingView API paths are available and their methods |
| tv_compatibility_checkB | Canary for critical TradingView internal APIs used by TVControl. Reports the Desktop version and exactly which required capabilities are missing. |
| tv_capability_matrixB | Map every TVControl tool to its required TradingView APIs and report which tools are currently available or blocked. |
| tv_support_bundleA | Create a privacy-safe compressed diagnostics bundle with identifiers, source code, URLs, titles, and secret-like values removed. |
| tv_compatibility_snapshotA | Record, compare, or list immutable per-version TradingView API compatibility baselines. Critical failures and informational method drift are reported separately. |
| tv_watchdog_sampleA | Run one read-only health watchdog sample. Persists only state transitions and never chart symbols, URLs, or account data. |
| tv_watchdog_startA | Start the read-only in-process health watchdog. Samples are coalesced and only state transitions are persisted. |
| tv_watchdog_stopA | Stop the in-process health watchdog |
| tv_watchdog_statusB | Return watchdog runtime status and its latest privacy-safe sample |
| tv_watchdog_historyC | Return bounded privacy-safe watchdog state-transition history |
| tv_ui_stateA | Get current UI state: which panels are open, what buttons are visible/enabled/disabled |
| tv_launchA | Launch TradingView Desktop with Chrome DevTools Protocol (remote debugging) enabled. Auto-detects install location on Mac, Windows, and Linux. |
| tv_updateA | Safely fast-forward a clean git checkout from its configured upstream. Refuses package installs, untracked branches, dirty trees, and diverged history. |
| chart_get_stateA | Get current chart state (symbol, timeframe, chart type, indicators) |
| chart_set_symbolC | Change the chart symbol |
| chart_set_timeframeB | Change the chart timeframe/resolution |
| chart_set_typeC | Change chart type |
| chart_manage_indicatorB | Add or remove an indicator/study on the chart |
| chart_get_visible_rangeB | Get the visible date range (unix timestamps) and bars range on the chart |
| chart_set_visible_rangeA | Zoom the chart to a specific date range (unix timestamps) |
| chart_scroll_to_dateA | Jump the chart view to center on a specific date |
| symbol_infoA | Get detailed metadata about the current symbol (name, exchange, type, description) |
| symbol_searchC | Search for symbols by name or keyword |
| pine_get_sourceA | Get current Pine Script source code from the editor |
| pine_set_sourceA | Set Pine Script source code in the editor. Refuses to overwrite a buffer holding real content unless confirm_overwrite is set. |
| pine_compileA | Compile the current Pine Script and add it to the chart. WARNING: this SAVES first, clicking Save and add to chart, which persists the current editor buffer to the saved script it is bound to. |
| pine_get_errorsA | Get Pine Script compilation errors from Monaco markers |
| pine_saveA | Save the current Pine Script buffer to the saved script the editor is bound to. WARNING: this persists to the cloud and overwrites that script. Verified by reading the editor Save/Saved state; an unverified save is never reported as success. |
| pine_get_consoleA | Read Pine Script console/log output (compile messages, log.info(), errors) |
| pine_smart_compileB | Intelligent compile: detects button, compiles, checks errors, reports study changes WARNING: like pine_compile this SAVES the current buffer to the bound saved script before compiling. |
| pine_newA | Replace the Pine editor buffer with a blank template. WARNING: this does NOT create a new saved script. It overwrites whatever script the editor currently has open, and a following pine_save or pine_compile persists that overwrite to the cloud. It refuses to run when the buffer holds real content unless confirm_overwrite is set. |
| pine_openA | Open a saved Pine Script by name |
| pine_list_scriptsA | List saved Pine Scripts. Returns a page, not the whole library — pass name_filter to find one by name. |
| pine_analyzeA | Run static analysis on Pine Script code WITHOUT compiling — catches array out-of-bounds, unguarded array.first()/last(), bad loop bounds, and implicit bool casts. Works offline, no TradingView connection needed. |
| pine_checkA | Compile Pine Script via TradingView's server API without needing the chart open. Returns compilation errors/warnings. Useful for validating code before injecting into the chart. |
| data_get_ohlcvA | Get OHLCV bar data from the chart. Use summary=true for compact stats instead of all bars (saves context). |
| data_get_indicatorC | Get indicator/study info and input values |
| data_get_strategy_resultsA | Get strategy performance metrics. Pass entity_id when more than one strategy is loaded. Auto-opens Strategy Tester and unhides the selected strategy so TradingView computes its report. |
| data_get_tradesA | Get the most recent strategy orders. Pass entity_id when more than one strategy is loaded. Auto-opens Strategy Tester and unhides the selected strategy. |
| data_get_equityA | Get equity curve data from Strategy Tester. Pass entity_id when more than one strategy is loaded. |
| quote_getA | Get quote data. A different symbol briefly switches the chart, serializes concurrent quote calls, and restores the original chart. |
| depth_getA | Get order book / DOM (Depth of Market) data from the chart |
| quote_batchA | Get live quotes for MANY symbols in ONE request without touching the chart. Use this for watchlist and universe sweeps: 29 symbols return in about 270ms. quote_get switches the chart symbol and takes ~20s each, so never loop it. |
| data_get_pine_linesA | Read horizontal price levels drawn by Pine Script indicators (line.new). Returns deduplicated price levels per study. Use study_filter to target a specific indicator. |
| data_get_pine_labelsA | Read text labels drawn by Pine Script indicators (label.new). Returns text and price pairs. Use study_filter to target a specific indicator. |
| data_get_pine_tablesA | Read table data drawn by Pine Script indicators (table.new). Returns formatted text rows per table. Use study_filter to target a specific indicator. |
| data_get_pine_boxesA | Read box/zone boundaries drawn by Pine Script indicators (box.new). Returns deduplicated {high, low} price zones. Use study_filter to target a specific indicator. |
| data_get_study_valuesA | Get current indicator values from the data window for all visible studies (RSI, MACD, Bollinger Bands, EMAs, custom indicators with plot()). |
| capture_screenshotA | Take a screenshot of the TradingView chart |
| draw_shapeC | Draw a shape/line on the chart |
| draw_listA | List shapes/drawings on the ACTIVE PANE ONLY. On a multi-pane layout the other panes are not included and a count of 0 does NOT mean the chart is empty: use pane_list to see every pane and pane_focus to switch. |
| draw_clearA | Remove ALL drawings from the ACTIVE PANE. On a multi-pane layout this is NOT the whole chart: use pane_list to see the panes and pane_focus to pick one first. DESTRUCTIVE and there is no undo through this API: every trendline, level and annotation on the active chart is deleted, not just ones you added. Use draw_remove_one with an entity_id to remove a single drawing. |
| draw_remove_oneA | Remove a specific drawing by entity ID |
| draw_get_propertiesA | Get properties and points of a specific drawing |
| alert_createB | Create a price alert on the current chart using TradingView's authenticated alert API |
| alert_create_bulkA | Create price alerts across MANY symbols, or the whole watchlist, in one call. Does NOT touch the chart. Each alert can carry a webhook URL so every fire posts to your own endpoint instead of your inbox. Use percent_from_last to set a level per symbol from its live price, which is the only thing that makes sense across a mixed watchlist. |
| alert_listA | List active alerts |
| alert_deleteC | Delete all alerts or open context menu for deletion |
| alert_delete_by_idA | Delete a single alert by ID |
| batch_runC | Run an action across multiple symbols and/or timeframes |
| replay_startA | Start bar replay mode, optionally at a specific date |
| replay_stepA | Advance one bar in replay mode |
| replay_autoplayA | Turn autoplay on or off in replay mode, optionally setting the speed. Pass enabled to say which state you want; omit it to flip whatever the current state is. Confirms the result by reading autoplay back. |
| replay_stopA | Stop replay and return to realtime |
| replay_tradeA | Execute a trade action in replay mode (buy, sell, or close position) |
| replay_statusA | Get current replay mode status |
| indicator_searchB | Search TradingView built-in, community, strategy, and saved-script studies |
| indicator_add_from_searchA | Search the TradingView Indicators dialog and add a matching built-in, strategy, community, or saved study |
| indicator_set_inputsA | Change indicator/study input values (e.g., length, source, period) |
| indicator_toggle_visibilityA | Show, hide, or flip an indicator on the chart. Omit visible to toggle. Confirms the result by reading the study back rather than trusting setVisible(). |
| watchlist_getA | Get every symbol in the active TradingView watchlist. Membership comes from the symbols_list API so it is complete even when the panel is scrolled or closed. Quote cells are best effort and only present when the watchlist panel is open; check quotes_available. |
| watchlist_addA | Add a symbol to the TradingView watchlist |
| watchlist_add_bulkA | Add multiple symbols sequentially and report per-symbol results |
| watchlist_removeB | Remove a symbol from the TradingView watchlist |
| watchlist_remove_bulkA | Remove multiple symbols sequentially and report per-symbol results |
| watchlist_exportB | Export the current watchlist to a JSON file on disk |
| watchlist_importB | Import symbols into the TradingView watchlist from a JSON file |
| ui_clickB | Click a UI element by aria-label, data-name, text content, or class substring |
| ui_open_panelB | Open, close, or toggle TradingView panels (pine-editor, strategy-tester, watchlist, alerts, trading) |
| ui_fullscreenA | Toggle TradingView fullscreen mode |
| layout_listB | List saved chart layouts with bounded pagination |
| layout_switchA | Switch to a saved chart layout by name or ID. Stops rather than discarding unsaved changes on the current chart unless discard_unsaved is set. |
| ui_keyboardB | Press keyboard keys or shortcuts (e.g., Enter, Escape, Alt+S, Ctrl+Z) |
| ui_type_textA | Type text into the currently focused input/textarea element. Refuses when nothing is focused or the focused element cannot accept text, and reports which element received the characters. |
| ui_hoverB | Hover over a UI element by aria-label, data-name, or text content |
| ui_scrollB | Scroll the chart or page up/down/left/right |
| ui_mouse_clickA | Click at specific x,y coordinates on the TradingView window |
| ui_find_elementA | Find UI elements by text, aria-label, or CSS selector and return their positions |
| pane_listA | List all chart panes in the current layout with their symbols and active state |
| pane_set_layoutC | Change the chart grid layout (e.g., single, 2x2, 2h, 3v) |
| pane_focusB | Focus a specific chart pane by index (0-based) |
| pane_set_symbolB | Set the symbol on a specific pane by index |
| tab_listA | List all open TradingView chart tabs |
| tab_newA | Open a new TradingView tab, optionally loading a saved layout |
| tab_closeA | Close the currently active chart tab. Names the tab it is about to close and refuses when no tab is marked active. Closing a chart tab cannot be undone through this API, so pass expect_title when it matters which one goes. |
| tab_switchB | Switch to a chart tab by index |
| state_snapshotA | Capture full chart state (symbol, timeframe, studies, drawings, visible range) to a named snapshot file |
| state_restoreA | Restore a saved chart state snapshot by name. DESTRUCTIVE: this makes the chart MATCH the snapshot, which removes every study and every drawing that is not in it. Take a state_snapshot of the current chart first if you might want it back. |
| state_listA | List all saved chart state snapshots sorted by capture date |
| state_deleteB | Delete a named chart state snapshot |
| strategy_sweepB | Iterate a strategy across symbols × timeframes × indicator input combinations |
| chart_vision_readA | Take a screenshot and read all chart data in one call (quote, indicators, Pine graphics, OHLCV). Returns mixed content: inline image when <= max_image_bytes, else file_path only. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/FerroxLabs/tvcontrol'
If you have feedback or need assistance with the MCP directory API, please join our Discord server