Skip to main content

Scrapetools

A collection of tools to aid in web scraping.

Install using:

pip install scrapetools

Scrapetools contains three functions (scrape_emails, scrape_phone_numbers, scrape_inputs) and one class (LinkScraper).

Basic usage

import scrapetools
import requests

url = 'https://somewebsite.com'
source = requests.get(url).text

emails = scrapetools.scrape_emails(source)

phoneNumbers = scrapetools.scrape_phone_numbers(source)

scraper = scrapetools.LinkScraper(source, url)
scraper.scrape_page()
# links can be accessed and filtered via the get_links() function
same_site_links = scraper.get_links(same_site_only=True)
same_site_image_links = scraper.get_links(link_type='img', same_site_only=True)
external_image_links = scraper.get_links(link_type='img', excluded_links=same_site_image_links)

# scrape_inputs() returns a tuple of BeautifulSoup Tag elements for various user input elements
forms, inputs, buttons, selects, text_areas = scrapetools.scrape_inputs(source)

Metadata

Release files for scrapetools 1.1.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for scrapetools 1.1.9
File Size Uploaded Provenance Actions
scrapetools-1.1.9.tar.gz 7.8 kB Without provenance Details for scrapetools-1.1.9.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for scrapetools 1.1.9
File Interpreter ABI Platform Actions
scrapetools-1.1.9-py3-none-any.whl Python 3 none any Details for scrapetools-1.1.9-py3-none-any.whl

Total release size: 17.5 kB

Release files / scrapetools-1.1.9.tar.gz

Download URL scrapetools-1.1.9.tar.gz
Size 7.8 kB
Tags Source
SHA-256 checksum
How to use checksums
11d9a694466f7054a2f87916f55c562348b9753ed45a4129ab10447fe5453dcc
BLAKE2b-256 checksum
How to use checksums
b8c1d69cce44217659f00270a67df065c013ddf4601b4976685a395b89e389e7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.11.0

Release files / scrapetools-1.1.9-py3-none-any.whl

Download URL scrapetools-1.1.9-py3-none-any.whl
Size 9.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
03a4ff71507be0f5b402299120913777f6914c33347008367cf5c441b0ba05fa
BLAKE2b-256 checksum
How to use checksums
551a3ce12edacb8df6ec1ca1d0f6921944dff2832fdf9a4870560e42b4f05d3d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.11.0

Security for scrapetools 1.1.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page