Tutorial 11: Create a PDF stamp
Introduction
This tutorial is targeting
Low-Code Developers who wants to learn how create a PDF document with stamp that enhance document security, workflow management, and Automating Document processing.
What you will learn
In this tutorial, you will learn how you can put text stamps on PDF files. With this, you can put incoming date stamps or watermarks on PDFs.
Step 1: Provide the invoice PDF in Drive
In the first step, you need to upload a sample PDF which can be used for this tutorial.
If you don’t have a sample invoice PDF at hand, you can use this one:
Login to the portal https://NAMESPACE.pipeforce.net
Click on Files / Drive. The Drive WebUI opens.
Upload the sample invoice PDF in the root folder of your drive. Keep the nameÂ
invoice.pdf
:Â
Step 2: Create and execute the stamp pipeline
In the next step, you will create a pipeline which loads the PDF, puts a stamp on it, and saves the stamped PDF back to drive:
Login to the portal https://NAMESPACE.pipeforce.net
Navigate to LOW CODE → Workbench
Select the node of your app or create a new one.
Click the plus icon at the top of the tree.
Name your Pipeline Then ClickÂ
Create
The new property has been created, and the content editor was opened for you.
Now copy and paste this content into the editor, and overwrite any existing data there by this:
pipeline:
- drive.read:
path: "invoice.pdf"
- pdf.stamp:
text: "RECEIVED ${@date.timestamp()}"
- drive.save:
path: "invoice-received.pdf"
Your pipeline now consists of three commands:
Load the PDF document from drive using the commandÂ
drive.read
.Put a PDF stamp on this loaded invoice using theÂ
pdf.stamp
 command. Additionally, we use theÂ@date
 PEL util here to return the current date and time.Store the stamped PDF document back to drive under a new nameÂ
invoice-received.pdf
 using the commandÂdrive.save
.
10. Click SAVE
 and then RUN
 to execute the pipeline.
11. After a refresh of the drive page, you should see a new PDF invoice-received.pdf:
12. Open the invoice-received.pdf
. You should see the generated stamp at the top right corner:
Â
Â