MCP-Server

Pine Script v6 Documentation

io.github.paulieb89/pinescript-mcp
Entwicklertools Wissen & Dokumentation Öffentlich und erreichbar MCP 2025-11-25

Was dieses MCP kann

Provides Pine Script v6 documentation search, section retrieval, function discovery and validation, and reusable coding prompts.

get_doc
USE WHEN reading the full content of a Pine Script v6 documentation file. Returns the file content; when limit is set, a header shows the char range and offset to continue reading. AFTER calling this tool, use offset=<end> to continue if the header indicates more content is available. For large files (ta.md, strategy.md, collections.md, drawing.md, general.md), prefer list_sections() + get_section() instead. Data sourced from bundled Pine Script v6 documentation.
Nur Lesen Idempotent
Eingabeschema
{'type': 'object', 'required': ['path'], 'properties': {'path': {'type': 'string', 'description': "Relative path to the documentation file (e.g., 'reference/functions/ta.md')."}, 'limit': {'type': 'integer', 'default': 0, 'minimum': 0, 'description': 'Maximum characters to return. Use 30000 for large files. 0 = no limit.'}, 'offset': {'type': 'integer', 'default': 0, 'minimum': 0, 'description': 'Character offset to start reading from.'}}, 'additionalProperties': False}
get_functions
USE WHEN browsing valid Pine Script v6 functions, optionally filtered to a namespace. Returns function names grouped by namespace (e.g. ta.*, strategy.*) or filtered to the requested namespace. AFTER calling this tool, call validate_function(fn_name) to check a specific name, or get_section() to read its documentation. Data sourced from bundled pine_v6_functions.json.
Nur Lesen Idempotent
Eingabeschema
{'type': 'object', 'properties': {'namespace': {'type': 'string', 'default': '', 'description': "Filter by namespace (e.g., 'ta', 'strategy', 'request'). Empty string returns all functions grouped by namespace."}}, 'additionalProperties': False}
get_prompt
Get a prompt by name with optional arguments. Returns the rendered prompt as JSON with a messages array. Arguments should be provided as a dict mapping argument names to values.
Eingabeschema
{'type': 'object', 'required': ['name'], 'properties': {'name': {'type': 'string', 'description': 'The name of the prompt to get'}, 'arguments': {'anyOf': [{'type': 'object', 'additionalProperties': True}, {'type': 'null'}], 'default': None, 'description': 'Optional arguments for the prompt'}}, 'additionalProperties': False}
Ausgabeschema
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
get_section
USE WHEN reading a specific named section from a Pine Script v6 documentation file. Returns the section content from the matched header to the next same-level header, with file path and line range. AFTER calling this tool, call list_sections(path) if the header was not found, or get_section() again with a child header for a narrower subsection. Data sourced from bundled Pine Script v6 documentation.
Nur Lesen Idempotent
Eingabeschema
{'type': 'object', 'required': ['path', 'header'], 'properties': {'path': {'type': 'string', 'description': "Documentation file path (e.g., 'reference/functions/strategy.md')."}, 'header': {'type': 'string', 'description': "Header text to find (e.g., 'strategy.exit()' or '## strategy.exit()')."}, 'include_children': {'type': 'boolean', 'default': True, 'description': 'Include nested subsections under the matched header.'}}, 'additionalProperties': False}
list_docs
USE WHEN discovering what Pine Script v6 documentation is available. Returns a categorised list of doc file paths with one-line descriptions. AFTER calling this tool, call get_doc(path) for small files or list_sections(path) then get_section(path, header) for large files (ta.md, strategy.md, collections.md, drawing.md, general.md). Data sourced from bundled Pine Script v6 documentation.
Nur Lesen Idempotent
Eingabeschema
{'type': 'object', 'properties': {}, 'additionalProperties': False}
list_prompts
List all available prompts. Returns JSON with prompt metadata including name, description, and optional arguments.
Eingabeschema
{'type': 'object', 'properties': {}, 'additionalProperties': False}
Ausgabeschema
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
list_sections
USE WHEN navigating a large documentation file before reading a specific section. Returns a newline-separated list of # and ## headers (### excluded) in the file. AFTER calling this tool, call get_section(path, header) with a header from this list. Data sourced from bundled Pine Script v6 documentation.
Nur Lesen Idempotent
Eingabeschema
{'type': 'object', 'required': ['path'], 'properties': {'path': {'type': 'string', 'description': "Documentation file path (e.g., 'reference/functions/ta.md')."}}, 'additionalProperties': False}
resolve_topic
USE WHEN looking up an exact Pine Script API term or known concept keyword. Returns the best-matching doc paths with matched keywords and a retrieval suggestion (get_doc or list_sections + get_section). AFTER calling this tool, follow the suggestion: call get_doc() for small files or list_sections() + get_section() for large files. For natural language questions use search_docs() instead. Data sourced from bundled TOPIC_MAP and doc file content scan.
Nur Lesen Idempotent
Eingabeschema
{'type': 'object', 'required': ['query'], 'properties': {'query': {'type': 'string', 'minLength': 1, 'description': "Exact Pine Script term or known concept keyword (e.g., 'ta.rsi', 'strategy.entry', 'repainting')."}}, 'additionalProperties': False}
Ausgabeschema
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
search_docs
USE WHEN finding documentation sections that match specific terms across all Pine Script v6 docs. Returns up to max_results sections ranked by match count, each with a preview and a get_section() call hint. AFTER calling this tool, call get_section(file, header) for each result you want to read in full. Data sourced from bundled Pine Script v6 documentation.
Nur Lesen Idempotent
Eingabeschema
{'type': 'object', 'required': ['query'], 'properties': {'query': {'type': 'string', 'minLength': 1, 'description': 'Search terms (case-insensitive). Multi-word queries match sections containing ALL terms.'}, 'max_results': {'type': 'integer', 'default': 5, 'maximum': 20, 'minimum': 1, 'description': 'Maximum sections to return.'}}, 'additionalProperties': False}
validate_function
USE WHEN confirming a Pine Script v6 function name is valid before using it in code. Returns a valid/invalid verdict with namespace suggestions or known replacement hints (e.g. ta.adx → ta.dmi, security → request.security). AFTER calling this tool, call get_functions(namespace) to list all valid functions in the relevant namespace if the function is invalid. Data sourced from bundled pine_v6_functions.json.
Nur Lesen Idempotent
Eingabeschema
{'type': 'object', 'required': ['fn_name'], 'properties': {'fn_name': {'type': 'string', 'minLength': 1, 'description': "Function name to validate (e.g., 'ta.sma', 'strategy.entry', 'plot')."}}, 'additionalProperties': False}
Ausgabeschema
{'type': 'object', 'required': ['result'], 'properties': {'result': {'type': 'string'}}, 'x-fastmcp-wrap-result': True}
Hinzugefügt
get_prompt
17. September 2026 12:45
Hinzugefügt
list_prompts
17. September 2026 12:45
Hinzugefügt
resolve_topic
17. September 2026 12:45
Hinzugefügt
validate_function
17. September 2026 12:45
Hinzugefügt
get_functions
17. September 2026 12:45
Hinzugefügt
search_docs
17. September 2026 12:45
Hinzugefügt
get_section
17. September 2026 12:45
Hinzugefügt
get_doc
17. September 2026 12:45
Hinzugefügt
list_sections
17. September 2026 12:45
Hinzugefügt
list_docs
17. September 2026 12:45