imgproxykit
A typed Python toolkit for building imgproxy URLs.
Features
- Fully typed and checked with
mypy,pyright,tyandpyreflyin strict modes - Expressive transforms: combine option objects with concise scalar arguments
- Immutable, reusable transforms for consistent image settings across your app
- Support for named presets configured on your imgproxy server
Installation
Requires Python 3.12+ and a running imgproxy server.
pip install imgproxykit
Example
Define a WebP thumbnail once and reuse it across a product catalog:
from imgproxykit import Client, Transform
from imgproxykit.options import Gravity, Resize
# Public URL of your imgproxy server.
client = Client('https://imgproxy.example.com')
thumbnail = Transform(
Resize(width=300, height=300, mode='fill'), # Pass typed option objects.
Gravity(position='sm'), # Let imgproxy choose the crop's focus.
quality=80, # Or scalar keywords, equivalent to Quality(80).
format='webp',
)
source_urls = [
'https://originals.example.com/products/backpack.jpg',
'https://originals.example.com/products/sneakers.jpg',
]
# Reuse one immutable transformation across your catalog.
thumbnail_urls = [
client.url(source=source_url, transform=thumbnail)
for source_url in source_urls
]
Use these URLs in your images' src attributes. Building a URL makes no
network requests: when a browser requests it, imgproxy fetches the original
image from originals.example.com and processes it.
Sign URLs and reuse presets configured on your imgproxy server:
from imgproxykit import Client, Transform
from imgproxykit.options import Preset
client = Client(
'https://imgproxy.example.com',
# Replace with your imgproxy server's hex-encoded key and salt.
key='736563726574',
salt='73616c74',
)
thumbnail = Transform(
Preset('product-card'), # Reuse a preset from your imgproxy server.
format='webp', # Combine server presets with explicit processing options.
)
source_url = 'https://originals.example.com/products/backpack.jpg'
# The client signs the URL using your server's key and salt.
thumbnail_url = client.url(source=source_url, transform=thumbnail)
See the full documentation for client configuration, transformations, and processing options. Find published releases on PyPI.
Contributing
See the contributing guide for development setup and checks. Bug reports and feature requests are welcome on the issue tracker.
License
Credits
Generated with
wemake-python-package
(template version).
Metadata
Release files for imgproxykit 0.3.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 | |
|---|---|---|---|---|
| imgproxykit-0.3.0.tar.gz | 23.8 kB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| imgproxykit-0.3.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 69.0 kB
Release files / imgproxykit-0.3.0.tar.gz
| Download URL | imgproxykit-0.3.0.tar.gz |
|---|---|
| Size | 23.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
934f3f118abee622db0979d9f26d6c819656c41681182a2ec5e26d0214c72cb3
|
|
BLAKE2b-256 checksum How to use checksums |
de9a4cfc78613299f4bde811f0294ad11811091dec4d9996f9f749a658eb99bd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.
Transparency logRelease files / imgproxykit-0.3.0-py3-none-any.whl
| Download URL | imgproxykit-0.3.0-py3-none-any.whl |
|---|---|
| Size | 45.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8e8ffdd81d80a8a3498e4ae21e02f185544daffe3f91bf3c76914c778e1389a3
|
|
BLAKE2b-256 checksum How to use checksums |
04a6b4ed2421603cb3e0615109bb6e5fa0a757386b26b3319d4d4229de67d390
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.
Transparency logSecurity for imgproxykit 0.3.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.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for imgproxykit-0.3.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.
Transparency logA 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.