Skip to main content
Glama

draw_shape

Draw technical analysis shapes on TradingView charts to annotate support/resistance levels, patterns, or trade targets. Provide time and price coordinates for lines, rectangles, or text.

Instructions

Create and render a graphical drawing primitive on the chart (horizontal_line, vertical_line, trend_line, rectangle, text, ray). WHEN TO USE: Call when annotating key support/resistance levels, chart patterns, breakout zones, or trade entry/target targets visually. SIDE EFFECTS: STATE_MUTATING (Adds drawing primitive to chart canvas). LIMITATIONS: Requires point coordinates in unix timestamp and price values.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textNoText content for text shapes
pointYes{ time: unix_timestamp, price: number }
shapeYesShape type: horizontal_line, vertical_line, trend_line, rectangle, text
point2NoSecond point for two-point shapes (trend_line, rectangle)
overridesNoJSON string of style overrides (e.g., '{"linecolor": "#ff0000", "linewidth": 2}')

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden and does well: it explicitly discloses STATE_MUTATING ('Adds drawing primitive to chart canvas') and the coordinate-format LIMITATION. It stops short of covering permissions, reversibility/undo, or persistence across sessions.

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?

Labeled sections (WHEN TO USE, SIDE EFFECTS, LIMITATIONS) make the definition scannable, and the core capability is front-loaded in the first sentence. No filler sentences.

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

Completeness4/5

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

For a mutation tool without annotations or an output schema, the description covers purpose, usage context, the mutation side effect, and required coordinate formats. The only gaps are edge behavior such as what identifier is returned and whether the drawing can be undone.

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 description coverage is 100%, so all five parameters (shape, point, point2, text, overrides) are already documented. The description restates the coordinate format (unix timestamp + price) and shape list but adds no new syntax or semantics beyond the schema, so the baseline 3 applies.

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?

States a specific verb+resource combination ('Create and render a graphical drawing primitive on the chart') and enumerates the supported shape types. An agent can tell this apart from siblings like draw_list, draw_clear, and draw_remove_one without opening any schema.

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 WHEN TO USE clause gives concrete conditions (support/resistance levels, chart patterns, breakout zones, trade entry/targets), which is clear contextual guidance. It does not, however, name alternatives such as draw_list or draw_get_properties for inspection workflows.

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