API REFERENCE

The details that make it work.

Request formats, response fields and error handling for Etchv’s image watermarking API.

Authentication

Send an X-API-Key header with a scoped Etchv machine key. Image endpoints do not accept Clerk session tokens. Account administration uses Clerk session authentication separately.

POST /watermarks/images

Requires watermarks:embed. Submit multipart/form-data with the following fields:

FieldTypeMeaning
fileBinary imageMaximum 20 MB and 40 megapixels.
dataJSON stringNon-empty object. Its canonical SHA-256 digest is embedded.

Returns 200 image/png. The X-Watermark-ID response header contains the embedded identifier as a hexadecimal string. Save it with your record; the API does not retain the supplied payload as a searchable attribution record.

curl "$ETCHV_API_URL/watermarks/images" \
  -H "X-API-Key: $ETCHV_API_KEY" \
  -F 'file=@campaign.jpg' \
  -F 'data={"asset":"campaign_01","recipient":"partner_42"}' \
  -D response-headers.txt \
  --output protected.png
POST /watermarks/imagesimage/png

POST /watermarks/images/detect

Requires watermarks:detect. Submit the recovered image as multipart field file.

curl "$ETCHV_API_URL/watermarks/images/detect" \
  -H "X-API-Key: $ETCHV_API_KEY" \
  -F 'file=@recovered.png'
Response fieldMeaning
watermarkedBoolean indicating a detected watermark.
confidenceNumber from 0 to 1: mean certainty of decoded bits, not a calibrated attribution probability.
watermark_idRecovered hexadecimal identifier, or null when no identifier is returned.

Error handling

StatusRecommended handling
401Check missing, invalid, expired or revoked credentials.
403Check key permissions and account or organization status.
413Reduce the upload size or pixel dimensions.
422Check image validity and the data JSON object.
503Model unavailable. Retry with bounded backoff and handle continued failure.

Use timeouts and check the HTTP status before treating a response as an image or a successful detection. Never log your API key.

MAKE EVERY COPY ACCOUNTABLE

Your content has a story.
Keep it connected.

Let’s find the right watermarking workflow for your platform.

Talk to the team