run_jsx
Runs arbitrary ExtendScript inside After Effects and returns its evaluated value, providing an escape hatch for project automation when dedicated tools do not cover the task.
Instructions
Escape hatch — run arbitrary ExtendScript inside AE and return its value. Wrap in (function(){...})(). Prefer dedicated tools when one fits.
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": {
"script": "<script>"
},
"name": "run_jsx"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| force | No | Bypass the safety lint hard-blocks (executeCommand/callSystem/newProject/open). Use only when you know why the pattern is safe here. | |
| script | Yes | ExtendScript source. Should evaluate to a JSON-serializable value. | |
| instance | No | Target a specific AE when more than one is connected (e.g. "2026", "2025", or a major like "26"). Omit when only one AE is open — see list_instances. | |
| description | No | A few words on what the script does, e.g. "Delete the test layers in Safari UI". Shown in the AE panel's Log tab so the user can follow along. |