curl -X POST "https://api.widar.com/v1/markings?system_id=sys_4kT9qWm2RbXe" \
-H "Authorization: Bearer $WIDAR_API_KEY" \
-H "Content-Type: image/png" \
-H "Idempotency-Key: lumen-out-7731" \
--data-binary @output.png \
-D headers.txt -o marked.pngWhat comes back
The answer’s body is the file, marked and signed, in the format you sent. Its headers carry the ids to keep beside it.
HTTP/1.1 201 Created
Content-Type: image/png
Widar-Mark-Id: mrk_2Xq9vBn4LsKe
Widar-Manifest-Id: mft_8Wc3jRt6NyPa
Widar-Timestamp-Id: tst_4Hd7kMq1ZvBx
X-Request-Id: req_9Vb3nKs7QwLx
<the marked and signed image>Retries are safe
Send an Idempotency-Key with each output. A repeat with the same key and the same file within 24 hours returns the same marked output and is billed once, though widar kept nothing of the first.
A visible label too
label=burn_in adds the system’s visible label to an image before it is marked, where its policy allows, so the watermark and the credential cover the labelled file. See Disclose.