Wkhtmltopdf API Wrapper
wkhtmltopdf-api Command Line Tool
In short, the script acts as a wrapper for Wkhtmltopdf. It replaces the local binary and transfers the job of generating pdf files to an external api.
Installation
Install from PyPI:
pip install wkhtmltopdf-api
Configuration
Environment vars
-
REPORT_API_URL: str, required
-
REPORT_API_TIMEOUT: seconds, default 300
-
REPORT_API_SIZE_LIMIT: bytes, default 100000000 (100mb)
-
WKHTMLTOPDF_VERSION: str, default 0.12.6
Usage
Same as wkhtmltopdf, see options : https://wkhtmltopdf.org/usage/wkhtmltopdf.txt
wkhtmltopdf-api --disable-local-file-access --cookie session_id abcd --quiet --page-size A4 --margin-top 40.0 --dpi 90 --zoom 1.0666666666666667 --header-spacing 35 --margin-left 7.0 --margin-bottom 28.0 --margin-right 7.0 --orientation Portrait --header-html /tmp/report.header.tmp.xxx.html --footer-html /tmp/report.footer.tmp.xxx.html /tmp/report.body.tmp.xxx.html /tmp/report.tmp.xxx.pdf
Metadata
Release files for wkhtmltopdf-api 0.1.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 | |
|---|---|---|---|
| wkhtmltopdf_api-0.1.0.tar.gz | 5.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| wkhtmltopdf_api-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.9 kB
Release files / wkhtmltopdf_api-0.1.0.tar.gz
| Download URL | wkhtmltopdf_api-0.1.0.tar.gz |
|---|---|
| Size | 5.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c4e90b892292af0cc5e2c963cfe5306950d0328b91281dc8220f228fc6e879ef
|
|
BLAKE2b-256 checksum How to use checksums |
7c82d08c5e2163b14e5bfe4b719cc7694a701c67191b8ad3801fd6ccc716bfb4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.9.19
|
Release files / wkhtmltopdf_api-0.1.0-py3-none-any.whl
| Download URL | wkhtmltopdf_api-0.1.0-py3-none-any.whl |
|---|---|
| Size | 4.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1819b229ed227990f6ac8efdaf9860d8581900992b1cd6c02b016694b4739249
|
|
BLAKE2b-256 checksum How to use checksums |
c6d6ae947249d3704042cef50d392cebe0e322f6a1d18bace023c3ea405eb05e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.9.19
|