Extract email addresses and linkedin profiles from given URL.
Project description
Extract Emails
Extract emails and linkedins profiles from a given website
Requirements
- Python >= 3.10
Installation
pip install extract_emails[all]
# or
pip install extract_emails[httpx]
# or
pip install extract_emails[playwright]
playwright install chromium --with-deps
Quick Usage
As library
from pathlib import Path
from extract_emails import DefaultWorker
from extract_emails.browsers import ChromiumBrowser, HttpxBrowser
from extract_emails.models import PageData
def main():
with ChromiumBrowser() as browser:
worker = DefaultWorker("https://example.com, browser)
data = worker.get_data()
PageData.to_csv(data, Path("output.csv"))
with HttpxBrowser() as browser:
worker = DefaultWorker("https://example.com, browser)
data = worker.get_data()
PageData.to_csv(data, Path("output.csv"))
async def main():
async with ChromiumBrowser() as browser:
worker = DefaultWorker("https://example.com, browser)
data = await worker.aget_data()
await PageData.to_csv(data, Path("output.csv"))
async with HttpxBrowser() as browser:
worker = DefaultWorker("https://example.com, browser)
data = await worker.aget_data()
await PageData.to_csv(data, Path("output.csv"))
As CLI tool
$ extract-emails --help
$ extract-emails --url https://en.wikipedia.org/wiki/Email -of output.csv
$ cat output.csv
email,page,website
bob@b.org,https://en.wikipedia.org/wiki/Email,https://en.wikipedia.org/wiki/Email
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
extract_emails-6.0.0.tar.gz
(232.3 kB
view details)
Built Distribution
File details
Details for the file extract_emails-6.0.0.tar.gz
.
File metadata
- Download URL: extract_emails-6.0.0.tar.gz
- Upload date:
- Size: 232.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.16
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
e429023a1316696882a21635877b66225bdee55c2a214e2f8872448652243d4d
|
|
MD5 |
825c7810ee6dc69712cd9edb0b99e407
|
|
BLAKE2b-256 |
f3fbcce6557353572832aa127f7a8f087eeba168350a2b019e1abbe5d57ddee8
|
File details
Details for the file extract_emails-6.0.0-py3-none-any.whl
.
File metadata
- Download URL: extract_emails-6.0.0-py3-none-any.whl
- Upload date:
- Size: 24.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.16
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
bb46d0753b81dc781ca424a7d9c55432a1bfb6ffa642c2b3ae4d9798a94c75a4
|
|
MD5 |
a116616b752aebff6a2310155dd3d3ce
|
|
BLAKE2b-256 |
4bad8e07dbab436b8a9a581e107a8978e3f4dae35b05b46ba2642579ea1b1869
|