Skip to main content
Glama
tedorigawa001

TradingView-MCP

add_pine_to_chart

Add your saved Pine script to a TradingView chart as a study to display the latest indicator. Existing studies remain untouched; for strategies, use run_backtest.

Instructions

Add one of the user's OWN saved Pine scripts (latest version) to a TradingView chart as a study — e.g. to show an improved indicator after save_pine_script. Additive only: never removes or replaces existing studies (the user can remove it from the chart UI). For strategies prefer run_backtest, which cleans up after itself.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pine_idYesScript id from list_pine_scripts
chart_indexNoChart index in a multi-chart layout. Default: the active chart

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.10

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It discloses important behavioral traits: it uses the latest version, is additive only, never removes or replaces existing studies, and the user can remove the study from the chart UI. This is strong, though it does not mention persistence, error behavior, or whether adding the same script twice creates duplicates.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded with the core action and resource. Every sentence adds value: the purpose, the additive-only guarantee, the manual removal path, and the strategy alternative. There is no filler or redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple side-effecting tool with no output schema and fully documented parameters, this description covers purpose, scope, side-effect safety, and the primary alternative. An agent has enough context to invoke it correctly and understand the consequences.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, and both parameters have meaningful descriptions: pine_id is 'Script id from list_pine_scripts' and chart_index is a chart index defaulting to the active chart. The tool description adds little parameter-specific detail beyond implying the script must be user-owned and saved.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Add one of the user's OWN saved Pine scripts (latest version) to a TradingView chart as a study.' It clearly distinguishes this from siblings by restricting scope to user-owned scripts and emphasizing additive-only behavior, which contrasts with remove_owned_study and run_backtest.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly states when to use the tool: after save_pine_script, to show an improved indicator. It also gives a clear when-not and alternative: 'For strategies prefer run_backtest, which cleans up after itself.' This is direct, actionable routing guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools