Skip to main content

Wayback Machine utils (web.archive.org)

Project description

wayback_utils.py

This module provides a Python interface to interact with the Wayback Machine web page archiving service (web.archive.org). It allows you to save URLs, check the status of archiving jobs, and verify if a URL has already been indexed.

Main classes:

  • WayBackStatus: Represents the status of an archiving job.
  • WayBackSave: Represents the response when requesting to archive a URL.
  • WayBack: Main class to interact with the Wayback Machine API.

Basic usage:

  1. Initialize the WayBack class with your access keys:

    wb = WayBack(ACCESS_KEY="your_access_key", SECRET_KEY="your_secret_key")

  2. Save a URL:

    result = wb.save("https://example.com")

  3. Check the status of a job:

    status = wb.status(result.job_id)

  4. Verify if a URL is already archived:

    is_indexed = wb.indexed("https://example.com")

Notes:

  • You need valid access keys (ACCESS_KEY and SECRET_KEY) to use the archiving API.
  • You can provide an on_confirmation callback function to save() to receive the final archiving status asynchronously.
  • The module uses requests and threading.

License:

MIT license.

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

wayback_utils-0.0.1.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

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

wayback_utils-0.0.1-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file wayback_utils-0.0.1.tar.gz.

File metadata

  • Download URL: wayback_utils-0.0.1.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.14.0b2

File hashes

Hashes for wayback_utils-0.0.1.tar.gz
Algorithm Hash digest
SHA256 503410499504ffbbc268ab30107dece6d39cd680ecc43304fea4f782c72cf715
MD5 b305efcb97e1601bdfbc92483d2474b0
BLAKE2b-256 e0fce80bac4ff707b2cf36449c10eebddc78501a5a000dbb6cb997c400d74d05

See more details on using hashes here.

File details

Details for the file wayback_utils-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: wayback_utils-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.14.0b2

File hashes

Hashes for wayback_utils-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0882b58659808f6fd22d5f3f28b6026e6d5763fb9edf24c29b908cdfbb5027e7
MD5 acc169e1b12142e2d95eb43264f6ac4b
BLAKE2b-256 8e06b41e1705557cd1cef50cf374f46a017461b2840da9db28963da1200c6b7d

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