AddImageToPDFValve

Add an image to one or more pages of an existing PDF document.

Valve operates on a single item.

Properties

Name Description Default value Mandatory Supports property expansion
pathToImage File path for image to add. Yes No
pdfSource Location of the B64 encoded pdf data. pdf No Yes
imagelocation Where in the document to add the image. Allowed values are: 'northwest', 'northeast', 'southwest' or 'southeast'. southeast No No
addimagetopage Which page to add image. Allowed values are: first, last or all. last No No
keyword Adds key word to pdf in order to hinder multiple image being added. image_added No No
ignoreifadded Ignores adding image if key word is found. true No No
imagepadding Adds X and Y padding to image. 0 No No

Example Configuration

{
   "name" : "AddImageToPDFValve",
   "enabled" : "true",
   "config" : {
      "pathToImage" : "<path to my image>/theimage.png",
      "pdfSource" : "{{session.pdf_data}}",
      "imagelocation" : "northwest",
      "imagepadding":"10"
    }
}

More information about the use of this valve can be found here.

Requirements

Item set must have one entry. Image must be located on local filesystem and be of typ .png.