Rename a folder or label
rename_folder_or_labelRename a Proton Mail folder or label in place while preserving its type; requires confirming old and new names before execution.
Instructions
Rename a folder or label where it stands: a label stays a label and a folder keeps its parent. INBOX and the special mailboxes (Sent, Drafts, Trash, Spam, Archive, All Mail) are refused. GATED: confirm the old and new names with the user, then call with confirmed=true.
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": {
"name": "<name>",
"new_name": "<new_name>"
},
"name": "rename_folder_or_label"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | The folder or label, exactly as list_folders shows it, e.g. 'Labels/Receipts'. | |
| dry_run | No | Preview exactly what would happen and change nothing. Needs no confirmation. | |
| new_name | Yes | The new name only, no 'Labels/' or 'Folders/' prefix. | |
| confirmed | No |