[docs] docs(mcp-scripts): remove redundant content (21% reduction)#21140
Merged
[docs] docs(mcp-scripts): remove redundant content (21% reduction)#21140
Conversation
Remove ~80 lines of bloat (21%) while preserving all essential information: - Collapse tool definition subsections that duplicated the code block comments - Remove redundant first JavaScript example (Quick Start already demonstrates JS) - Remove Supported Types and Validation Options lists that mirrored the code block - Replace Go "Available by default" list + second example with a brief inline note - Remove duplicate CAUTION in Security Considerations (identical to opening CAUTION) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Reduces redundancy in the MCP Scripts reference doc by removing repeated explanations while keeping the core configuration and examples.
Changes:
- Condensed the tool definition requirements into a single sentence.
- Removed an extra JavaScript example and duplicated input-parameter explanations.
- Simplified the Go section by removing repeated environment-variable and import details.
Comments suppressed due to low confidence (1)
docs/src/content/docs/reference/mcp-scripts.md:167
- After removing the “Supported Types” / “Validation Options” subsections, this page no longer states which input
typevalues are allowed (e.g.,boolean,array,object) or summarizes the available validation keys. The example only showsstring/number, so a reader can’t tell what else is supported without jumping to the specification; consider adding a short, non-redundant list here or linking directly to the relevant section inmcp-scripts-specification.md.
## Input Parameters
Define typed parameters with validation:
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Comment on lines
56
to
+59
| timeout: 120 # Optional: timeout in seconds (default: 60) | ||
| ``` | ||
|
|
||
| ### Required Fields | ||
|
|
||
| - **`description:`** - Human-readable description of what the tool does. This is shown to the agent for tool selection. | ||
|
|
||
| ### Optional Fields | ||
|
|
||
| - **`timeout:`** - Maximum execution time in seconds (default: 60). The tool will be terminated if it exceeds this duration. Applies to shell (`run:`) and Python (`py:`) tools. | ||
|
|
||
| ### Implementation Options | ||
|
|
||
| Choose one implementation method: | ||
|
|
||
| - **`script:`** - JavaScript (CommonJS) code | ||
| - **`run:`** - Shell script | ||
| - **`py:`** - Python script (Python 3.1x) | ||
| - **`go:`** - Go (Golang) code | ||
|
|
||
| You can only use one of `script:`, `run:`, `py:`, or `go:` per tool. | ||
| Each tool requires `description:` and exactly one of `script:`, `run:`, `py:`, or `go:`. |
This was referenced Mar 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Removes 80 lines (21%) of bloat from
docs/src/content/docs/reference/mcp-scripts.mdwhile preserving all essential technical information.File improved
docs/src/content/docs/reference/mcp-scripts.md(375 → 295 lines)What was removed
calculate-sum)Supported Types+Validation Optionssubsectionsexample-toolcode block above themapi-callexampleChanges preserved
All essential information is retained:
description:+ one-of-script:/run:/py:/go:requirement (condensed to one line)inputs map[string]anyusage and a cross-reference foros.Getenv()type,required,default,enum,description) visible in the code blockScreenshot
References:
Warning
The following domains were blocked by the firewall during workflow execution:
accounts.google.comclients2.google.comcontentautofill.googleapis.comredirector.gvt1.comwww.google.comTo allow these domains, add them to the
network.allowedlist in your workflow frontmatter:See Network Configuration for more information.