FindaCat API Wrapper
A lightweight Python wrapper for the finda.cat API, providing easy access to cat images and related data.
Features
- Get random cat images with customizable options (format, blur, saturation, text, etc.)
- Retrieve API statistics
- Get all available cat image IDs
- Access the history of cat images in Base64 format
Installation
- Python 3.7 or higher
pip install findacat
Usage
from findacat import FindaCat, CatOptions
client = FindaCat()
opts = CatOptions(format="png", blur=1)
# Get a random cat image with options
image_bytes = client.get_cat_image(opts)
with open("cat.png", "wb") as f:
f.write(image_bytes)
# Get API statistics (JSON)
stats = client.get_stats()
print(stats)
# Get all cat image IDs (JSON)
all_images = client.get_all_images()
print(all_images)
# Get Base64 cat images history (JSON)
history = client.get_history()
print(history)
Notes
- The get_cat_image method returns the image content as bytes.
- Other methods return JSON responses from the API.
- Use CatOptions to customize the image request parameters.
- Errors from the API are raised as exceptions for image requests, or returned as JSON with an "error" key for data requests.
Links
Metadata
Release files for findacat 1.0.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 |
|---|---|---|---|---|
| findacat-1.0.0.tar.gz | 15.4 kB | Without provenance | Details for findacat-1.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| findacat-1.0.0-py3-none-any.whl | Python 3 | none | any | Details for findacat-1.0.0-py3-none-any.whl |
Total release size: 31.2 kB
Release files / findacat-1.0.0.tar.gz
| Download URL | findacat-1.0.0.tar.gz |
|---|---|
| Size | 15.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7b376fe605865d9f4f5d6543a1dca7daada61508f7d02ac4376e8122e2efaf4a
|
|
BLAKE2b-256 checksum How to use checksums |
a46ad47959e65a889c1b3aef0d3a4e95ab81664ebd48ea9938d4199abf4fcde2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Release files / findacat-1.0.0-py3-none-any.whl
| Download URL | findacat-1.0.0-py3-none-any.whl |
|---|---|
| Size | 15.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1bed988c7ea8d302b1f7c8bedff9895d128c3a74cfd263108f9a06090795a4f8
|
|
BLAKE2b-256 checksum How to use checksums |
b59f07cd7ebb1c52a412c585c542770b57e3cd91d4493b419e114c62280fa394
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Security for findacat 1.0.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.