Overview
The HTML to PDF Data Operation converts an HTML Text value to a PDF. This can be used to easily create PDF forms that the customer can print, or to tie in with an existing workflow that uses a PDF.
Use Cases
- Generate a form that the customer can download and print out for use with an existing workflow
- Generate a receipt for a customer
- Generate an invoice for a customer
Data Operation Properties
HTML
A Text value containing the HTML that will be rendered to a PDF. This can include CSS tags, but cannot contain any Javascript.
PDF Filename
The filename of the created PDF.
Footer Height
Determines how much space will be added to the bottom of each page of the PDF. Requires a CSS property like "100px".
Header Height
Determines how much space will be added to the top of each page of the PDF. Requires a CSS property like "100px".
Asset Setting
Scope
Determines the scope of the download link. This can either be APP or SESSION. If the generated PDF should be accessible from other user sessions, choose APP. Otherwise, if the created PDF is unique per customer, choose SESSION.
Visibility
Determines the visibility of the download link. This can either be GLOBALor PRIVATE. If the generated PDF has sensitive customer information, it should be marked as PRIVATE. With PRIVATE, the PDF will have an extra layer of access protection. The generated URL will have the necessary credentials to access the file.
NOTE: The generated URL for the PDF allows anyone to access the file. The URL should only be shown to the customer that the PDF belongs to.
Download Url Expiration
Only appears when Visibility is marked PRIVATE, as Global Assets do not expire.
Determines how long the download link to the file is available. For instance, if 30 Minutes is given, the download link will no longer work after thirty minutes. Private Assets must expire after a maximum of 7 days.
Hash Type
The hash type selected from the dropdown will automatically generate a hash when files are uploaded to the Asset store.
Run Results
A Variable is automatically created to hold the results of this Operation. This result will be an object with several keys that describe the generated PDF.
The most important of these keys is downloadUrl
, which is a URL that downloads the generated PDF when accessed.