Receive Mail
🔗 Original page — Source of this material
Description
Work with email accounts without using a browser window. Allows you to find the needed email and information inside it. Suitable for bulk processing of incoming messages.

How do I add this action to a project?
Via the context menu Add action → Work with mail → Receive mail

Or use the ❗→ smart search.
What is this used for?
- Quick access to emails
- Getting data from an email
- Activating accounts on websites
- Deleting specific emails from the inbox
- Deleting downloaded emails
How do I use the action?
Before using this action, please make sure the IMAP option is enabled in your account.
“Main” tab

Advanced view
Clicking this button will open the ❗→ Mail Processing window.
Email
Email address.
Password
Password for the email account.
Connection settings
Auto-detect settings
When enabled, ZennoPoster will automatically select the parameters needed to connect to the mail server.
This does not work with all mail providers.
Server, Port, Username, Use SSL, Protocol
All these parameters should be clarified in the documentation for your chosen mail provider.
How to search for an email

IMAP Folders

Here you can select the folders in your email account where the search for emails will be performed.
Using the button to the right of the selected folders field, you can refresh the folder list.
Reg. exp. (Regular Expression)
In this field, you need to enter a ❗→ regular expression by which the mail will be searched.
Email loading intervals
Emails from services might arrive with a delay, so you should specify the time interval in seconds and the number of attempts to download the message list. The delimiter ";" in the screenshot indicates the number of attempts. The first attempt after *15 sec, the second after *30 sec, the third after *60 sec.
No more than emails to load from folder
Specify the number of emails to be loaded.
Delete found email
If this is enabled, the found email will be deleted from the mailbox after processing.
Search for text in email

You can save the results of several regular expressions at once! For example, if an email contains an activation code, website address, phone number, first and last name — you can extract all this in one go! Just create a regular expression for each item and add variables to store the results.
Regular Expression
Enter the regular expression here to find the desired text.
Match number
Often a single ❗→ regular expression can produce several results. This shows the serial number of the found item (counting starts from zero!).
It’s not recommended to hard-code the match number in your projects. Today the email might have one structure and the required link is the second match, but tomorrow the structure may change and the link could be the seventh match. Try to write your regular expressions so that only one result remains.
Save to variable
In this column you should select an existing variable or create a new one to save the result of the regular expression.
Save error to variable
If an error occurs during execution of the action, you can save its message by enabling this setting and selecting (or creating) a variable where the message will be stored.
“Proxy” tab

No proxy
The action will run using the real IP address of the computer/server.
Current project proxy
Uses the ❗→ proxy set in the project.
Format string

Enter the proxy in this format (you can use a ❗→ variable):
a) With authentication – socks5://login:password@ip:port or http://login:password@ip:port
b) Without authentication – socks5://ip:port or http://ip:port
c) Without protocol (default is http://) – login:password@ip:port or ip:port
Other

Select this if you need to set detailed proxy settings: type, authentication data, address, and port. Please check with your service provider for details.
You can use variables in any input field.
If the proxy protocol is not specified, http:// will be used by default.
Example usage
After registering on a website, you'll need to confirm your account by going to your mailbox, getting the activation link, and following it to verify your account.
- Register on the website.
- Add the Receive mail action to your project and configure it.
- Get the activation link from the required email.
- Go to the link.
- Your account is activated.
When working with mass actions on websites, working without a browser saves time and resources. The project won't load the email provider's site. So this action allows you to quickly process emails in mailboxes.