Email Delete
In this article
Overview
You can use this Snap to delete email messages from the IMAP server.
Snap Type
Email Archive Snap is a WRITE-type Snap that passes the data to the downstream Snap.
Prerequisites
This Snap requires a valid IMAP account to handle access to this endpoint.
Clicking the "Preview" button does not read any email message if the account is IMAP and the Unread only property is checked. When unread messages are read, they are all marked as "read" in the mail server. Therefore, they should not be read during the preview. Otherwise, the execution of the Snap does not read any message.
Test this Snap in your environment to ensure it performs as expected. This may delete emails forever, not move them to "Trash" where they could be recovered.
Support for Ultra Pipelines
Works in Ultra Pipelines.
Limitations and Known Issues
None.
Snap Views
Type | Format | Number of Views | Examples of Upstream and Downstream Snaps | Description |
---|---|---|---|---|
Input | Document |
| Any Document Snap | This Snap can have a most one document input view. If you do not specify an input view, the Snap generates a downstream flow of one row. |
Output | Document |
| Any Document Snap | This Snap has exactly one output view and produces documents in the view. Each document contains a Map data which represents a deleted email message. The keys in the Document are "subject", "dateSent". The value of "subject" and "dateSent" keys is a string. The following is an example of an Output Document:
|
Error | Error handling is a generic way to handle errors without losing data or failing the Snap execution. You can handle the errors that the Snap might encounter while running the Pipeline by choosing one of the following options from the When errors occur list under the Views tab. The available options are:
Learn more about Error handling in Pipelines. |
Snap Settings
Asterisk (*): Indicates a mandatory field.
Suggestion icon (): Indicates a list that is dynamically populated based on the configuration.
Expression icon (): Indicates whether the value is an expression (if enabled) or a static value (if disabled). Learn more about Using Expressions in SnapLogic.
Add icon (): Indicates that you can add fields in the fieldset.
Remove icon (): Indicates that you can remove fields from the fieldset.
Field Name | Field Type | Description |
---|---|---|
Label*
Default Value: Email Delete | String | Specify the name for the Snap. You can modify this to be more specific, especially if you have more than one of the same Snap in your Pipeline.
|
Mail folder*
Default Value: None | String/Expression | Enter the name of email folder from where the Snap should delete messages. |
Email Category*
Default Value: All | Dropdown list | Select an option to choose category of emails to delete, like READ, UNREAD and ALL corresponding to read email messages, unread email messages and all messages. Please note that POP3 servers may ignore this property and the Snap deletes all messages regardless of whether this property is checked or not. |
Number of messages
Default Value: All | Integer | Enter the maximum number of messages to delete from the given folder. Any non-integer or negative value will lead to "All" messages to be deleted. |
From
Default Value: None | String | Specify the sender of the email. This field is used to filter email messages to delete, based on the sender name. |
Subject
Default Value: None | String | Specify the subject of the email. This field is used to filter email messages to delete based on the specified subject. |
Snap Execution
Default Value: Execute only | Dropdown list | Select one of the three modes in which the Snap executes. Available options are:
|
Examples
Deleting Email from the SMTP server
This example pipeline demonstrates how to delete an email residing in the SMTP server using the SMTP account.
Step 1: Configure the Email Sender Snap to send an email to the SMTP server. On validation, the Snap displays the output with the details of the email.
|
Step 2: Configure the Email Delete Snap to delete the email with the subject testdan323. On validation, the Snap displays the output of a confirmation message indicating that the email with the Subject testdan323 is successfully deleted.
|
Downloads
Snap Pack History
Related Content
Have feedback? Email documentation@snaplogic.com | Ask a question in the SnapLogic Community
© 2017-2024 SnapLogic, Inc.