Roblox Inject Code
roblox_inject_codeInsert a block of Luau code at the top or bottom of an existing Roblox script by specifying the instance path.
Instructions
Inject/append a block of Luau code to the top or bottom of an existing Roblox script.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>",
"codeBlock": "<codeBlock>"
},
"name": "roblox_inject_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Full instance path of the script. | |
| codeBlock | Yes | Block of Luau code to inject. | |
| position | No | Where to inject the code (top or bottom of the script). | bottom |
| waitForResponseMs | No | How long to wait for a runtime response. |