Metadata-Version: 2.4
Name: letsbuilda-pypi
Version: 5.2.2
Summary: A wrapper for PyPI's API and RSS feed
Author-email: Bradley Reynolds <bradley.reynolds@darbia.dev>
License: MIT
Project-URL: repository, https://github.com/letsbuilda/letsbuilda-pypi/
Project-URL: documentation, https://docs.letsbuilda.dev/letsbuilda-pypi/
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: httpx
Requires-Dist: xmltodict
Requires-Dist: pydantic
Provides-Extra: dev
Requires-Dist: pre-commit; extra == "dev"
Requires-Dist: nox; extra == "dev"
Requires-Dist: ruff; extra == "dev"
Requires-Dist: mypy; extra == "dev"
Requires-Dist: types-xmltodict; extra == "dev"
Provides-Extra: tests
Requires-Dist: pytest; extra == "tests"
Provides-Extra: docs
Requires-Dist: sphinx; extra == "docs"
Requires-Dist: furo; extra == "docs"
Requires-Dist: sphinx-autoapi; extra == "docs"
Requires-Dist: releases; extra == "docs"
Dynamic: license-file

# letsbuilda-pypi

A wrapper for [PyPI's API and RSS feeds](https://warehouse.pypa.io/api-reference/index.html).

## Usage

### Sync client

```py
from httpx import Client
from letsbuilda.pypi import PyPIServices

http_client = Client()
pypi_client = PyPIServices(http_client)

print(pypi_client.get_rss_feed(pypi_client.NEWEST_PACKAGES_FEED_URL))
print(pypi_client.get_package_metadata("letsbuilda-pypi"))
```

### Async client

```py
from httpx import AsyncClient
from letsbuilda.pypi.async_client import PyPIServices

http_client = AsyncClient()
pypi_client = PyPIServices(http_session)

print(await pypi_client.get_rss_feed(pypi_client.NEWEST_PACKAGES_FEED_URL))
print(await pypi_client.get_package_metadata("letsbuilda-pypi"))
```
