GitHub | PyPI | Documentation | Issues | Changelog
pypi-simple is a client library for the Python Simple Repository API as specified in PEP 503 and updated by PEP 592, PEP 629, PEP 658, PEP 691, PEP 700, PEP 708, PEP 714, PEP 740, and PEP 792. With it, you can query the Python Package Index (PyPI) and other pip-compatible repositories for a list of their available projects and lists of each project’s available package files. The library also allows you to download package files and query them for their project version, package type, file digests, requires_python string, PGP signature URL, and metadata URL.
See the documentation for more information.
Installation
pypi-simple requires Python 3.8 or higher. Just use pip for Python 3 (You have pip, right?) to install it:
python3 -m pip install pypi-simple
pypi-simple can optionally make use of tqdm. To install it alongside pypi-simple, specify the tqdm extra:
python3 -m pip install "pypi-simple[tqdm]"
Examples
Get information about a package:
>>> from pypi_simple import PyPISimple
>>> with PyPISimple() as client:
... requests_page = client.get_project_page('requests')
>>> pkg = requests_page.packages[0]
>>> pkg.filename
'requests-0.2.0.tar.gz'
>>> pkg.url
'https://files.pythonhosted.org/packages/ba/bb/dfa0141a32d773c47e4dede1a617c59a23b74dd302e449cf85413fc96bc4/requests-0.2.0.tar.gz'
>>> pkg.project
'requests'
>>> pkg.version
'0.2.0'
>>> pkg.package_type
'sdist'
>>> pkg.digests
{'sha256': '813202ace4d9301a3c00740c700e012fb9f3f8c73ddcfe02ab558a8df6f175fd'}
Download a package with a tqdm progress bar:
from pypi_simple import PyPISimple, tqdm_progress_factory
with PyPISimple() as client:
page = client.get_project_page("pypi-simple")
pkg = page.packages[-1]
client.download_package(
pkg, path=pkg.filename, progress=tqdm_progress_factory(),
)
Metadata
Release files for pypi-simple 1.8.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pypi_simple-1.8.0.tar.gz | 57.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pypi_simple-1.8.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 84.1 kB
Release files / pypi_simple-1.8.0.tar.gz
| Download URL | pypi_simple-1.8.0.tar.gz |
|---|---|
| Size | 57.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
466f2fcd0d723822aae3a0ccfda22e68ff8cd7f50aae68911946ab1dd1d587e1
|
|
BLAKE2b-256 checksum How to use checksums |
f5bc6c1e5caa5cd13b57cde193e1c1a17f370603dd78c55a3a01c1fcbe5149d3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / pypi_simple-1.8.0-py3-none-any.whl
| Download URL | pypi_simple-1.8.0-py3-none-any.whl |
|---|---|
| Size | 26.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
85f56420ab1d8e7ef5e55daabcee20c73e714f2bfee5505d811b075cc72d9ecc
|
|
BLAKE2b-256 checksum How to use checksums |
c4ad5ce88458a6d01147d600d72bb55f5086ff3ffa5f4085c6d3e37e91f4d591
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|