HHaven
A well-documented and typed API wrapper for Hentai Haven, providing efficient asynchronous requests, built-in cache support, and Pydantic Models for seamless autocompletion and linter support.
Key Features
- Efficient Asynchronous Structure: Utilize a fully asynchronous structure that enhances request speed without affecting other processes in your code.
- Built-in Cache Support: Benefit from built-in cache support using the aiocache library, reducing unnecessary API requests and improving overall performance.
- Pydantic Model Output: Receive all data in the form of Pydantic Models, enabling comprehensive autocompletion and linter support.
- Comprehensive Documentation: Explore extensive and user-friendly documentation, covering all aspects of this library.
Links
Documentation - https://hhaven.nekolab.app
API Reference - https://jokelbaf.github.io/hhaven-api-reference
Requirements
- Python 3.8+
- pydantic
- aiohttp
- aiocache
Installation
From PyPi:
pip install hhaven
From GitHub:
pip install git+https://github.com/JokelBaf/hhaven.git
Examples
Search for hentai by it's name:
from hhaven import Client
import asyncio
async def main():
client = await Client().build()
results = await client.search("Maid Kyouiku")
hentai = await results[0].full()
print(hentai)
if __name__ == "__main__":
asyncio.run(main())
Get all episodes of the latest hentai:
from hhaven import Client
import asyncio
async def main():
client = await Client().build()
home = await client.home()
hentai = await home.last[0].full()
for episode in hentai.episodes:
print(episode.name)
if __name__ == "__main__":
asyncio.run(main())
Development
Uv is a preferred tool for managing dependencies and running the development environment in hhaven. To setup the project locally, use the following commands:
git clone https://github.com/JokelBaf/hhaven.git
cd hhaven
uv sync --group test
To run tests, use the following commands:
uv run pytest
To run documentation locally, use the following command:
uvx --with mkdocs-material[emoji] mkdocs serve
License
This project is licensed under the MIT License - see the LICENSE file for details.
Metadata
Release files for hhaven 0.2.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 | Provenance | Actions |
|---|---|---|---|---|
| hhaven-0.2.0.tar.gz | 10.0 kB | Without provenance | Details for hhaven-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| hhaven-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for hhaven-0.2.0-py3-none-any.whl |
Total release size: 20.9 kB
Release files / hhaven-0.2.0.tar.gz
| Download URL | hhaven-0.2.0.tar.gz |
|---|---|
| Size | 10.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
dd719a08fafa40dab6fd54c62988e81a4e52a44e1a65b0669f88c875c6b6259d
|
|
BLAKE2b-256 checksum How to use checksums |
7d5b947c259cd7893990bc4190b9e279682384651f4b61815fa030da092ec555
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.4 CPython/3.13.7 Linux/6.11.0-1018-azure
|
Release files / hhaven-0.2.0-py3-none-any.whl
| Download URL | hhaven-0.2.0-py3-none-any.whl |
|---|---|
| Size | 11.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
659e12089a01afb0eeeb43d07b2d60ddd15adad11567f3726528e5e3cf51d9cc
|
|
BLAKE2b-256 checksum How to use checksums |
1b663a183b04099948304643579f8922db011224dab5ebf6955ee2df964645e7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.4 CPython/3.13.7 Linux/6.11.0-1018-azure
|
Security for hhaven 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.