Skip to main content

No project description provided

Project description

Sitemap Parser

Under construction! Not ready for use yet! Currently experimenting and planning!

Developed by Satyam Singh 2024

Examples of How To Use (Alpha Version)

Initialise SitemapScraper

from sitemap_url_parser import BaseSitemapScraper

scraper = BaseSitemapScraper(
    restaurant_name="Wendy's", # the name of the restaurant (this will be changed to scrape any sites, not just restaurants)
    source_path="https://locations.wendys.com/sitemap.xml", # path to the sitemap URL
    result_path="Sitemaps/wendys.csv", # path where the output CSV will be saved
    url_component_length=7, # Check for only saving the URL with at least the given number of datapoints
    datapoints={
    "base_url": 2,
    "country": 3,
    "state": 4,
    "city": 5,
    "location": 6,
    }, # mapping of which data resides at which index in the URL (index are calulated by splitting URL on '/')
    substring_check="https://locations.wendys.com", # Check for asserting a specific substring that must be present in the URL
)
scraper.scrape()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sitemap_url_parser-0.1.1.tar.gz (9.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sitemap_url_parser-0.1.1-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file sitemap_url_parser-0.1.1.tar.gz.

File metadata

  • Download URL: sitemap_url_parser-0.1.1.tar.gz
  • Upload date:
  • Size: 9.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.5

File hashes

Hashes for sitemap_url_parser-0.1.1.tar.gz
Algorithm Hash digest
SHA256 7560fedcf0e590ef5c1c5998f0525f48c2e812402f98b9ba768611c251ff035f
MD5 9c281bf3072c5c013c446ddb3e7326de
BLAKE2b-256 37c2b9cf96d2f77183f3ada400e31936a3a195d578dbd3b5914e508ca04d37e5

See more details on using hashes here.

File details

Details for the file sitemap_url_parser-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for sitemap_url_parser-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3fc85efddf9d96423b5653bf4e6e08144647fca5f47a237420d0db2e0d35a641
MD5 66ce9968ee93a49181780743ef79883b
BLAKE2b-256 51788fd4c2446ae5606fcba7adfe8d7c84ba478a8d2e831f175b4334aced7426

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page