0% found this document useful (0 votes)
19 views3 pages

Email Verification Tool Setup

This document provides a comprehensive guide for setting up and using the Email Verification Tool, which validates email addresses by checking their domain's MX records and connecting to the SMTP server. It includes instructions for installing necessary Python libraries, configuring a Telegram bot, preparing an email list, and running the script to verify emails. Results are displayed in the terminal and saved in text files, with notifications sent to the Telegram bot for easy access.

Uploaded by

pubgid2784
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views3 pages

Email Verification Tool Setup

This document provides a comprehensive guide for setting up and using the Email Verification Tool, which validates email addresses by checking their domain's MX records and connecting to the SMTP server. It includes instructions for installing necessary Python libraries, configuring a Telegram bot, preparing an email list, and running the script to verify emails. Results are displayed in the terminal and saved in text files, with notifications sent to the Telegram bot for easy access.

Uploaded by

pubgid2784
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Email Verification Tool Setup and Usage Guide

Introduction:

This document will guide you through the setup and usage of the Email Verification Tool. The tool is

designed to validate emails by checking their domain's MX (Mail Exchange) records and connecting

to the SMTP server to verify if the email is valid. You will learn how to install, configure, and run the

tool effectively.

Setup Instructions:

1. Install Dependencies:

The tool requires the following Python libraries:

- aiosmtplib: For asynchronous SMTP communication.

- dns.resolver: For DNS resolution and retrieving MX records.

- requests: For interacting with the Telegram API.

- rich: For a colorful and well-structured terminal UI.

- fpdf: To generate the PDF.

Install the dependencies using pip:

pip install aiosmtplib dnspython requests rich fpdf

2. Configure Telegram Bot:

- Create a Telegram bot by chatting with the BotFather on Telegram.

- Get your bot's token and chat ID.

- Replace the following in the script with your bot's token and chat ID:

TELEGRAM_BOT_TOKEN = "YOUR_BOT_TOKEN"

TELEGRAM_CHAT_ID = "YOUR_CHAT_ID"
3. Prepare Email List:

- Create a file named `emails.txt` with each email address on a new line.

- Place this file in the same directory as the script.

4. Run the Script:

- Once everything is set up, you can run the script using:

python email_verification_tool.py

- The script will connect to each email domain's MX server and attempt to verify the email

addresses.

- Results will be displayed in the terminal and saved in `valid_emails.txt`, `invalid_emails.txt`, and

`unknown_emails.txt`.

5. Check Results:

- After the script completes, you can view the results by checking the generated text files.

- The script will also send these results to your Telegram bot as files.

Script Explanation:

The script follows these main steps:

1. Loading the Email List: The script reads the email addresses from the `emails.txt` file.

2. Checking Email Validity: For each email, the script resolves the MX records of the domain and

attempts to connect to the SMTP server to validate the email.

3. Collecting Results: The script categorizes each email into three groups: 'Valid', 'Invalid', or

'Unknown'.
4. Displaying Results: A colorful table displaying the results is shown in the terminal using the `rich`

library.

5. Storing Results: Valid, invalid, and unknown emails are saved to separate text files

(`valid_emails.txt`, `invalid_emails.txt`, and `unknown_emails.txt`).

6. Sending Results: The results are sent to the Telegram bot in the form of documents for easy

access.

Running the Script:

To run the script:

1. Ensure that you have Python 3.x installed on your machine.

2. Ensure that the required libraries (aiosmtplib, dnspython, requests, rich, fpdf) are installed.

3. Place the `emails.txt` file with the list of email addresses in the same folder as the script.

4. Modify the `TELEGRAM_BOT_TOKEN` and `TELEGRAM_CHAT_ID` variables in the script with

your bot's details.

5. Run the script by executing:

python email_verification_tool.py

6. Once the script finishes, you will see the results in the terminal and the results will also be saved

in respective text files.

7. Your Telegram bot will receive the `valid_emails.txt` and `invalid_emails.txt` files as well.

You might also like