Etchv Python SDK
Official server-side Python client for Etchv: embed and detect invisible forensic watermarks in images, PDFs and videos.
Install
pip install etchv-sdk
Requires Python 3.14. Import it as etchv. Fully typed.
Quickstart
Create an API key in the Etchv dashboard
and set ETCHV_API_KEY on your server. Embedding needs the watermarks:embed
scope, detection watermarks:detect, and both use credits.
import os
from pathlib import Path
from etchv import Etchv
with Etchv(os.environ["ETCHV_API_KEY"]) as client:
result = client.embed_image(Path("photo.jpg").read_bytes(),
{"recipient": "customer-123"}, filename="photo.jpg")
Path(result.filename).write_bytes(result.image) # write bytes as-is
detection = client.detect_image(result.image)
print(detection.watermarked, detection.watermark_id, detection.confidence)
Use embed_document / detect_document for PDFs and embed_video /
detect_video for H.264 MP4/MOV. Uploads are limited to 20 MB. Detection
recovers a SHA-256 digest of your data, not the data itself.
Async jobs
job = client.submit_embed("documents", pdf_bytes, {"recipient": "customer-123"},
filename="report.pdf", idempotency_key="report-001")
status = client.get_job(job["request_id"]) # ["status"]: queued, running, retrying, succeeded, failed
result = client.get_embed_result(job["request_id"]) # waits for the file
submit_detection, get_job(..., detect=True) and get_detection_result work
the same way. Reusing an idempotency_key with the same input returns the saved
result (kept 24 hours) without another charge.
Also included
- API key check:
check_api_key()(no credits used). - Assets:
list_assets,get_asset,update_asset,download_asset,delete_asset,delete_assets. - Webhooks:
create_webhook,list_webhooks,update_webhook,delete_webhook,list_webhook_deliveries,redeliver_webhook; verify deliveries withverify_webhook(raw_body, headers, signing_secret), which raisesWebhookVerificationError. - Customer storage (S3, GCS, Azure):
create_storage_destination,list_storage_destinations,update_storage_destination,verify_storage_destination,delete_storage_destination,create_storage_delivery,list_storage_deliveries,get_storage_delivery,retry_storage_delivery,download_storage_delivery.
Errors
API failures raise EtchvError or a subclass such as AuthenticationError,
PermissionDeniedError, ConflictError, GoneError, RateLimitError or
DeadlineExceededError. Each carries status_code, detail and request_id
(quote it to support). Messages never include your API key.
from etchv import EtchvError
try:
client.detect_image(image)
except EtchvError as error:
print(error.status_code, error.request_id)
Links
- Full guide: https://etchv.com/docs/sdks/python
- API reference: https://etchv.com/docs
- Support: hello@etchv.com
License: MIT (covers this SDK, not the hosted Etchv service).
Questions or bug reports: open an issue here or email hello@etchv.com.
Release files for etchv-sdk 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 | |
|---|---|---|---|
| etchv_sdk-1.0.0.tar.gz | 16.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| etchv_sdk-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 28.6 kB
Release files / etchv_sdk-1.0.0.tar.gz
| Download URL | etchv_sdk-1.0.0.tar.gz |
|---|---|
| Size | 16.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1c639b219257a1bfe5e3dfb2c47b0377bc25bad0d14db1736e609ee53512219b
|
|
BLAKE2b-256 checksum How to use checksums |
dfd3f532aee76418d9ff8da57bead680ef3396cca47cb99e0223b3375cdac445
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.18 {"installer":{"name":"uv","version":"0.12.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / etchv_sdk-1.0.0-py3-none-any.whl
| Download URL | etchv_sdk-1.0.0-py3-none-any.whl |
|---|---|
| Size | 12.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e7fb2a989802469069534f420c2cee44fe3b74d4eeb0795d23e199c3e895452a
|
|
BLAKE2b-256 checksum How to use checksums |
6f4086fe5d02a957ab928cd0b72c70fb9eaaed9c6c66e2cd5630bf9056009450
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.18 {"installer":{"name":"uv","version":"0.12.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|