Update mail rule
update_mail_ruleUpdate an existing mail rule while preserving its ID and history: rename, enable/disable, change condition matching, or replace conditions and actions; optionally apply it to existing mail.
Instructions
Update an existing mail rule while keeping its id and history: rename it, enable or disable it, change how conditions combine (match), or replace its conditions or actions. Only the provided fields change; conditions/actions replace the current ones wholesale when given. Optionally applies the updated rule to existing mail via existingMail (same confirmation policy as create_mail_rule). Find the id with list_mail_rules.
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": {
"ruleId": "<ruleId>"
},
"name": "update_mail_rule"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Optional human-readable rule name, e.g. "Archive GitHub Notifications". | |
| match | No | How multiple conditions combine: "all" = every condition must match (AND), "any" = one is enough (OR). | |
| ruleId | Yes | The id of the rule to update, as returned by create_mail_rule or list_mail_rules. | |
| actions | No | Replacement action list (replaces all current actions, in order). | |
| enabled | No | Enable (true) or disable (false) the rule without deleting it. | |
| conditions | No | Replacement conditions (replace all current conditions; at least one required when given). | |
| existingMail | No | Optionally apply the UPDATED rule to existing mail after saving, same policy as create_mail_rule. |