The script reading tools let an AI agent access the source code of everyDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/Chrrxs/robloxstudio-mcp/llms.txt
Use this file to discover all available pages before exploring further.
Script, LocalScript, and ModuleScript in your place without modifying anything. Use get_script_source to read a specific script, grep_scripts to search across all scripts at once with ripgrep-style result formatting, and get_roblox_docs to look up authoritative engine API documentation before generating or editing code. These three tools cover the full read side of any script-editing workflow.
get_script_source
Read the source code of any Script, LocalScript, or ModuleScript. The response always includes both source (the raw text) and numberedSource (with 1-based line numbers prepended), making it easy to reference exact positions for subsequent edits.
For large scripts, the response may be truncated — check the truncated flag and the accompanying note. When a script is too large to read in full, pass line_range to read only the section you need.
Canonical path to a
LuaSourceContainer (e.g. game.ServerScriptService.RoundManager or game.ReplicatedStorage.Modules[".dir"].Combat).Line range to return. Supports several formats:
"start-end"— e.g."100-200"returns lines 100 through 200"100-"— from line 100 to the end of the file"-200"— from line 1 to line 200"42"— a single line
Which connected Studio place to target. Required when multiple places are connected; omit when only one is open. Use
get_connected_instances to list available IDs.grep_scripts
Ripgrep-inspired search across all script sources in your place. Returns results grouped by script, each with line numbers, column numbers, and optional context lines. Supports both literal text search and Lua pattern matching.
The text to search for. With
usePattern: false (the default) this is a literal string. With usePattern: true it is interpreted as a Lua pattern with top-level | alternation (e.g. "foo|bar" matches any line containing "foo" or "bar").Whether literal search is case-sensitive. Defaults to
false. When usePattern: true, matching is always case-sensitive; passing caseSensitive: false together with usePattern: true is rejected.Enable case-sensitive Lua pattern matching instead of literal string search. Defaults to
false. Supports top-level alternation: "a|b" matches a line containing "a" or "b".Number of lines to include before and after each match (like
grep -C). Defaults to 0.Maximum total matches before the search stops. Defaults to
100.Maximum matches per individual script (like
rg -m). Useful when a single frequently-used helper would otherwise swamp the results.When
true, return only the paths of scripts that contain at least one match — no line details. Defaults to false. Useful for a quick inventory before a full search.Limit the search to a specific subtree (e.g.
"game.ServerScriptService" to ignore client and shared code).Restrict results to a single script class:
"Script", "LocalScript", or "ModuleScript".Which connected Studio place to target. Required when multiple places are connected.
get_roblox_docs
Fetch official Roblox engine API documentation from create.roblox.com as markdown. Returns descriptions, properties, methods, events, and code samples for any class, enum, datatype, Luau library, or global. Results are cached, making repeat lookups cheap.
Call this tool before writing or editing any code that uses an engine class you are not fully certain about. The page includes the exact property types, method signatures, and event payloads needed to write correct Luau on the first attempt.
Exact PascalCase name of the class, enum, datatype, or library (e.g.
"ProximityPrompt", "KeyCode", "CFrame", "TweenService", "table").Documentation category. One of
classes (default), enums, datatypes, libraries, or globals.Optional
##-level section to read instead of the entire page. Examples: "Properties", "Methods", "Events", "Code Samples". Very large pages are automatically truncated with a section index; use this parameter to read a truncated section in full.