Patch Effect
patch_effectApply RFC 6902 add, replace, or remove operations to a stored effect and revalidate it, enabling diff-based iteration with rollback and failing-op reporting on any error.
Instructions
Apply a small list of RFC 6902 ops (replace/add/remove) to a stored effect, then re-validate. Iterate by sending only the diff, not the whole document. Any failure — bad path/index or a post-patch validation error — rolls back: the stored doc is left unchanged and the failing op index is named. Handles live only for this session (server process); they do not survive a reconnect.
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": {
"handle": "<handle>",
"ops": "<ops>"
},
"name": "patch_effect"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ops | Yes | Restricted RFC 6902 ops (replace/add/remove) applied IN ORDER (max 64). Any failure — bad path, bad index, or a post-patch validation error — rolls back: the stored doc is unchanged. | |
| handle | Yes | A handle from open_effect. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | ||
| errors | Yes | ||
| handle | Yes | A session handle ("fx-1", …) to pass as `handle` to patch/validate/simulate/render; null on failure. | |
| warnings | Yes | ||
| migratedFrom | Yes | The doc's ORIGINAL schemaVersion if it was migrated up, else null. | |
| schemaVersion | Yes |