Skip to main content

Software Heritage Web client

Project description

Client for Software Heritage Web applications, via their APIs.

Sample usage

from swh.web.client import WebAPIClient
cli = WebAPIClient()

# retrieve any archived object via its PID
cli.get('swh:1:rev:aafb16d69fd30ff58afdd69036a26047f3aebdc6')

# same, but for specific object types
cli.revision('swh:1:rev:aafb16d69fd30ff58afdd69036a26047f3aebdc6')

# get() always retrieve entire objects, following pagination
# WARNING: this might *not* be what you want for large objects
cli.get('swh:1:snp:6a3a2cf0b2b90ce7ae1cf0a221ed68035b686f5a')

# type-specific methods support explicit iteration through pages
next(cli.snapshot('swh:1:snp:cabcc7d7bf639bbe1cc3b41989e1806618dd5764'))

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

swh.web.client-0.1.5.tar.gz (80.3 kB view details)

Uploaded Source

Built Distribution

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

swh.web.client-0.1.5-py3-none-any.whl (78.2 kB view details)

Uploaded Python 3

File details

Details for the file swh.web.client-0.1.5.tar.gz.

File metadata

  • Download URL: swh.web.client-0.1.5.tar.gz
  • Upload date:
  • Size: 80.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.3

File hashes

Hashes for swh.web.client-0.1.5.tar.gz
Algorithm Hash digest
SHA256 3394d08ec6b7d60baa8b03911275da174232af8704f41873b531efb81fe27b19
MD5 8f3990e943d9d32eb8e36e82dfc0ff90
BLAKE2b-256 eb539858c940cd9ddf6da73d776e9aee6802548d50eb96d6d326d7083e802132

See more details on using hashes here.

File details

Details for the file swh.web.client-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: swh.web.client-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 78.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.3

File hashes

Hashes for swh.web.client-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 cce3efc25be6891c147a1bb8ed2a9db8f501d5602653f50f9f1dabd995c6bd8e
MD5 eef6ea3ed066029a4b5a1727040fcd6d
BLAKE2b-256 bcab107e9334a4d029398617b6bdc185371f39c901938e36bd2b193537473836

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