email_command
Execute IMAP or SMTP primitives when a focused email tool does not cover the operation. Existing tools, including create_mailbox, remain the simpler policy-aware route.
Instructions
Execute IMAP or SMTP primitives when a focused email tool does not cover the operation. Existing tools, including create_mailbox, remain the simpler policy-aware route. Start with commands=[{"command":"HELP"}] or HELP UID COPY for local syntax and examples; no account is needed for help. Execution requires account_name and user-enabled allow_protocol_commands with compatible policy. Commands run in order on one automatically authenticated connection; state lasts only for this call. For example SELECT a mailbox, then UID COPY known UIDs to an existing destination. Put APPEND/DATA message content in data, never in command lines. No login commands, passwords, hosts, shell scripts or local paths. Stops on the first error. Inspect every result: prior effects may exist and unknown completion must not be replayed automatically. HELP lists supported syntax; server CAPABILITY alone does not imply client support for arbitrary extensions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| commands | Yes | ||
| protocol | No | imap | |
| account_name | No | Configured account name; required for execution, omitted for local HELP. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | ||
| status | No | stopped | |
| results | No | ||
| warnings | No |