Skip to main content
Glama
pbajkovic-hub

tv-cdp-mcp

tv_copy_layout

Destructive

Clone any TradingView chart layout into a new saved layout, optionally from a source URL, with duplicate-name protection and confirmation of the copy.

Instructions

TradingView "Make a copy": clone the layout shown in the bound tab (optionally opening source_url first, e.g. someone else's View Only chart) into a new saved layout with the given name. Settles when the copy appears in the saved-layout list (45-60 s: server clone + page reload); reports which tab shows it (TV Desktop opens a copy of another user's chart in a NEW tab). Refuses an empty name or a name that already exists among the saved layouts unless allow_duplicate_name=true.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesname of the new layout
layoutNochart layout id, target id, or 0-based index; default = the chart tab that is actually painting
timeout_sNodeadline for the clone (and for the open, each), default 120 - the clone is a server round trip plus a full page reload
source_urlNochart URL or layout id to open first (same rules as tv_open_chart_url); default = whatever the tab shows
expect_layoutNolayout id the tab is expected to show right now; the call refuses if it differs (a tab keeps its target id when the user opens another layout in it)
discard_changesNowith source_url: navigate away from unsaved changes
allow_duplicate_nameNoallow a name that already exists (default false)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the destructiveHint annotation, the description explains the timeline (45-60 s), the settling condition (copy appears in saved-layout list), the new-tab behavior on TV Desktop, and the refusal conditions for empty or duplicate names. It also adds detail about how source_url is handled.

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 dense but tightly structured, with the core action first, then performance/settling behavior, then edge-case refusals. Every sentence provides operational detail that an agent needs; there is no filler or repetition of schema text.

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 complex destructive operation with no output schema, the description covers the essential operational context: expected duration, success criterion, tab behavior, duplicate-name policy, and source_url handling. An agent has enough guidance to invoke the tool correctly and interpret the result.

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

Parameters5/5

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

Although the schema already documents all seven parameters, the description enriches their meaning by tying name/allow_duplicate_name to refusal behavior, explaining timeout_s in terms of server round trips plus page reload, and clarifying that source_url follows tv_open_chart_url rules. This goes well beyond the structured schema.

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 states a specific verb ('clone') and resource ('the layout shown in the bound tab'), and includes the TradingView feature name 'Make a copy'. It clearly distinguishes this from related tools like tv_delete_layout or tv_open_chart_url by describing exactly what is created and what is not.

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

Usage Guidelines4/5

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

The description gives clear context: use it to clone the current tab's layout, optionally from a source_url such as someone else's View Only chart. It does not explicitly enumerate when to prefer alternative tools, but the behavior and boundaries are sufficiently clear for an agent to decide.

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