This repository contains a collection of automation tools designed to streamline various tasks related to Linkedin and email management. Each tool serves a specific purpose and can be used individually or in combination with others.
The Linkedin Company Extractor is an automation tool that allows users to scrape and extract company data from Linkedin Sales Navigator. This tool simplifies the process of gathering company information for purposes such as market research, lead generation, and competitor analysis.
To use the Linkedin Companies Extractor, follow these steps:
-
Ensure you have Python 3.12 installed. If not, download and install it from the official Python website.
-
Install the Playwright Pytest plugin:
pip install pytest-playwright
-
Install the required browsers for Playwright:
playwright install
-
In
Settings
section ofextract_companies.py
configure your Linkedin login credentials and Sales Navigator start url(search results page 1) -
Run the companies extractor script:
python extract_companies.py
-
companies.json
will be created with all scraped linkedin companies
The Email Scraper extracts email addresses for companies and updates the companies.json
file (initially created by the LinkedIn Company Extractor) with this data.
- Install Scrapy:
pip install scrapy
-
In
Settings
section ofscrape_emails.py
configure your settings. -
To scrape emails for all companies listed in
companies.json
, run:
python scrape_emails.py
This will scrape emails and append to companies.json
.
Send mails to companies listed in companies.json
with Gmail API by using personal gmail account.
-
Create a Google Cloud project https://developers.google.com/workspace/guides/create-project#project
-
Enable Gmail API for this project https://developers.google.com/gmail/api/quickstart/python#enable_the_api
-
Configure the OAuth consent screen https://developers.google.com/gmail/api/quickstart/python#configure_the_oauth_consent_screen
-
Authorize credentials for a desktop application https://developers.google.com/gmail/api/quickstart/python#authorize_credentials_for_a_desktop_application
-
Install the Google client library https://developers.google.com/gmail/api/quickstart/python#install_the_google_client_library
-
In
Settings
section ofsend_emails.py
update email template and most relevant email keywords as needed. -
To start cold mailing, run:
python send_emails.py
This will send emails to companies at 3-minute intervals to comply with Gmail's sending policy.