Apply a plan (human gate)
applyRun a pending write plan by planId after human approval. Refuses if the resource changed or is gone, then writes, re-reads to confirm, and logs the result.
Instructions
The second step of a write, and the human gate: runs one pending plan by its planId. Re-reads the resource and refuses when a field the plan touches (or its version) changed since the plan or the resource is gone; otherwise writes, re-reads to confirm, appends a record to the org's apply log and returns the confirmed state. A plan is applied once. Call it only after the human has seen the plan: the client's permission prompt on this tool is how the human approves the write, so this tool must never be allow-listed. Refused in read-only mode.
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": {
"planId": "<planId>"
},
"name": "apply"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| planId | Yes | The planId that plan returned. | |
| secrets | No | Only when the plan lists secretFields: the value of each, by its dotted path ({"body.apiKey": "..."}). The plan file keeps them redacted; they are sent with the write and never saved or logged. |