Watermarker.add() returns an AddWatermarkResult describing what was added. It exposes number_applied_watermarks and a succeeded collection; each succeeded item carries a unique identifier (watermark_id), the watermark_type, the page_number, the watermark_position, and the placed geometry (left, top, width, height). This enables tracing, searching, and removing specific watermarks later.
Review the result of added watermarks
The example below adds a text watermark to a two-page PDF and prints the result for each applied watermark.
The watermark was added to both pages, so succeeded contains two items, each with its own watermark_id. The watermark_type and watermark_position are enum values (here type=0 corresponds to a text watermark). The watermark_id GUIDs let you locate and remove these exact watermarks in a later session.
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.
On this page
Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.