An API wrapper for the Python Package Index
Project description
pypiwrap
Documentation · PyPI · Changelog
pypiwrap is an API wrapper for the Python Package Index (PyPI) providing interfaces for retrieving project information, releases and statistics from the PyPI JSON API, the Statistics API, and the Index API. pypiwrap also parses information from the PyPI RSS feeds.
Installation
pypiwrap requires Python 3.10 or later and can be installed with pip:
python3 -m pip install pypiwrap(Linux/Mac)py -3 -m pip install pypiwrap(Windows)
Examples
import pypiwrap
# Fetching data from the PyPI API
with pypiwrap.PyPIClient() as pypi:
project = pypi.get_project("requests")
print(project.name) # requests
print(project.author) # Kenneth Reitz
print(project.summary) # Python HTTP for Humans.
stats = pypi.get_stats()
print(stats.total_size.si) # 24.61 TB
# Fetching data from the Index API
with pypiwrap.SimpleRepoClient() as repo:
page = repo.get_project_page("requests")
print(page.files[-1].url) # https://files.pythonhosted.org/packages/63/70/[...]
print(page.files[-1].size.si) # 131.22 KB
# Fetching data from the RSS feeds
with pypiwrap.PyPIFeedClient() as rss:
feed = rss.get_newest_packages()
print(feed.title) # PyPI newest packages
for item in feed.items:
print(item.title) # ... added to PyPI
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pypiwrap-2.1.0.tar.gz.
File metadata
- Download URL: pypiwrap-2.1.0.tar.gz
- Upload date:
- Size: 14.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b05957a4b6dc45b6ed8a3b822444ec839019982d255c5c271d9c4610788928ea
|
|
| MD5 |
4368d55520f2ca2e8e901d7435d817d8
|
|
| BLAKE2b-256 |
d4821c6f738270ca1435143cc9b4ab3beee38d79141abc135fb5c64f33cfe41a
|
Provenance
The following attestation bundles were made for pypiwrap-2.1.0.tar.gz:
Publisher:
python-publish.yml on aescarias/pypiwrap
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pypiwrap-2.1.0.tar.gz -
Subject digest:
b05957a4b6dc45b6ed8a3b822444ec839019982d255c5c271d9c4610788928ea - Sigstore transparency entry: 1463111709
- Sigstore integration time:
-
Permalink:
aescarias/pypiwrap@29395ccbd8813a501300fc3f3af64e6d33f82f11 -
Branch / Tag:
refs/tags/v2.1.0 - Owner: https://github.com/aescarias
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@29395ccbd8813a501300fc3f3af64e6d33f82f11 -
Trigger Event:
release
-
Statement type:
File details
Details for the file pypiwrap-2.1.0-py3-none-any.whl.
File metadata
- Download URL: pypiwrap-2.1.0-py3-none-any.whl
- Upload date:
- Size: 15.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e5e09e6e9db12b1b1a10b435ef9a235e39ff37635b4274f98cff4da0116ba87a
|
|
| MD5 |
cdf6ae0a50ab976abf2dfb8bf1cd9c0c
|
|
| BLAKE2b-256 |
e0f1d83e12fae5cecac4270c3fcdb86b9ca695050c88965d1b6d6fc5f3665914
|
Provenance
The following attestation bundles were made for pypiwrap-2.1.0-py3-none-any.whl:
Publisher:
python-publish.yml on aescarias/pypiwrap
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pypiwrap-2.1.0-py3-none-any.whl -
Subject digest:
e5e09e6e9db12b1b1a10b435ef9a235e39ff37635b4274f98cff4da0116ba87a - Sigstore transparency entry: 1463111770
- Sigstore integration time:
-
Permalink:
aescarias/pypiwrap@29395ccbd8813a501300fc3f3af64e6d33f82f11 -
Branch / Tag:
refs/tags/v2.1.0 - Owner: https://github.com/aescarias
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@29395ccbd8813a501300fc3f3af64e6d33f82f11 -
Trigger Event:
release
-
Statement type: