Python SDK for the DopplrHub public API
Project description
DopplrHub Python SDK
A Python SDK for the current DopplrHub public API, including generic conversions, tools, and utility endpoints.
Install
pip install dopplrhub
For this local scaffold:
cd D:\AudioConverter\sdk\python
pip install -e .
If you want to distribute the SDK directly from the backend, this workspace will expose a zip bundle at /api/sdk/python-sdk.zip.
Local file conversion
from dopplrhub import DopplrHub
api = DopplrHub("YOUR_API_KEY", "https://api.dopplrhub.com/api/v1")
(api.start("./input.pdf", "jpg")
.wait()
.download("./input.jpg")
.delete())
Remote file conversion
from dopplrhub import DopplrHub
api = DopplrHub("YOUR_API_KEY", "https://api.dopplrhub.com/api/v1")
(api.start_from_url("https://example.com/brochure.pdf", "png")
.wait()
.download("./brochure.png")
.delete())
Tools
from dopplrhub import DopplrHub
api = DopplrHub("YOUR_API_KEY", "https://api.dopplrhub.com/api/v1")
(api.tools.ocr("./scan.pdf", "ocr-docx", language="eng")
.wait()
.download("./scan.docx"))
(api.tools.image_resize(
"./hero.png",
width=1920,
height=1080,
fit="cover",
output_format="webp",
)
.wait()
.download("./hero.webp"))
(api.tools.pdf_compress("./packet.pdf", "screen")
.wait()
.download("./packet-compressed.pdf"))
(api.tools.video_trim("./clip.mp4", start_time=3, end_time=12, output_format="mp4")
.wait()
.download("./clip-trimmed.mp4"))
api.tools.ada("./brochure.pdf").download("./brochure-ada-report.pdf")
api.tools.ats(
"./resume.pdf",
"Senior Python engineer with API design experience",
industry="technology",
).download("./resume-optimized.docx")
(api.tools.archive(["./a.txt", "./b.txt"], "zip", archive_name="documents")
.wait()
.download("./documents.zip"))
(api.tools.social_resize(
"./hero.png",
platform="instagram",
selected_size_ids=["post-square", "story"],
output_format="jpg",
)
.wait()
.download("./hero-instagram.zip"))
result = api.tools.ats_reexport(report, "modern", download_as="resume-modern.docx")
result.download("./resume-modern.docx")
Tool coverage in the Python SDK includes ocr, pdf, image, video, ada, ats, ats_reexport, archive, and social_resize on api.tools.
Examples
examples/convert_local_file.pyexamples/convert_remote_file.pyexamples/ocr_tool.pyexamples/pdf_tool.pyexamples/image_tool.pyexamples/video_tool.pyexamples/ada_tool.pyexamples/ats_tool.pyexamples/tools_and_utilities.py
Utilities
from dopplrhub import DopplrHub
api = DopplrHub("YOUR_API_KEY", "https://api.dopplrhub.com/api/v1")
formats = api.utilities.supported_formats()
rates = api.utilities.currency_rates("USD")
api.utilities.batch_download(["JOB_ID_1", "JOB_ID_2"], "./converted_files.zip")
Important behavior note
start_from_url() currently downloads the remote resource first, then uploads it into DopplrHub.
It does not perform headless browser webpage rendering.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file dopplrhub-1.0.0.tar.gz.
File metadata
- Download URL: dopplrhub-1.0.0.tar.gz
- Upload date:
- Size: 8.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
393d2557788e81f935d6a353f3bdac1a59450a0ef76cbd9fefe25becfb28d125
|
|
| MD5 |
c2b8dc2d1deb12c6f77f2c35578d13cf
|
|
| BLAKE2b-256 |
aa7310d4a6b8a0ae40254f692bca2bc8576ec3f4666772dc937dbd3a3934a6cf
|
File details
Details for the file dopplrhub-1.0.0-py3-none-any.whl.
File metadata
- Download URL: dopplrhub-1.0.0-py3-none-any.whl
- Upload date:
- Size: 8.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ff868c923e710f7749f0d98f4353e4ea806a2e5835e88c0c17947b2982554b9c
|
|
| MD5 |
18dbf20e1accfc5330b0af67edc2b3be
|
|
| BLAKE2b-256 |
0b6be8eb82a3c8d1fe4e32e84951c6a089191d95df7170aff84607f11a830294
|