Delete email

Email inbox
Delete email
Success
Email(Email)
Error
Mode(Email delete mode) TRASH

Description

Deletes a message. In TRASH mode (the default) it is moved to the server's trash folder and stays recoverable; in PERMANENT mode it is expunged and cannot be recovered. Takes an email object from Find/Get email — the server connection comes from the email itself. Branches on success/error.

When to use

Use Delete email for messages that genuinely have no further value — processed notifications, expired alerts, duplicates.

Prefer TRASH. It is the default because it is recoverable: the message moves to the server’s trash folder, where a human can retrieve it if the pipeline turns out to have been wrong about it. The trash folder is found through the server’s own special-use flag, so it works whatever the folder is named in the account’s language. A message already in the trash is left alone rather than being deleted for real — TRASH never destroys anything.

PERMANENT expunges the message immediately and it is gone. Use it only where the data genuinely must not persist, and be confident about the filter that selected the message: a Find emails query that is one character wrong is unrecoverable in this mode.

Consider whether you want a delete at all. Moving to an archive folder keeps the audit trail and costs almost nothing on modern mailboxes, and Set email flag alone is enough to stop a polling pipeline from reprocessing something.

Pins

Input pins

Pin Type Default Notes
Email Email — An email object from Find emails or Get email. The folder and the server connection both come from the email itself, so this node needs no credentials.
Mode Email delete mode TRASH `TRASH` (the default) moves the message to the folder the server flags as its trash, falling back to a folder literally named `Trash`; the message stays recoverable. `PERMANENT` marks it deleted and expunges it immediately — it cannot be recovered.

Execution pins

Pin Direction
In Input
Success Output
Error Output

Example

Clear out automated monitoring noise nightly. With Simple schedule (daily), run Find emails on Folder INBOX with From [email protected] and Before set to Now minus 30 days. For each result, wire the element into Delete email with Mode TRASH, so a mistake in the filter is still recoverable from the trash folder for as long as the server keeps it.

See also