Issue
After replacing or removing PDFTron integration, the interactive rubber stamp annotation tool (for example, Approved / Not Approved stamps) is no longer available when users view existing PDF attachments in the inline PDF viewer.

Symptoms and Impact
Users who relied on a PDFTron-based integration to drag and place rubber stamps onto PDF attachments in the inline viewer lose that capability when PDFTron is removed. The inline PDF viewer no longer presents stamp or annotation tools.
Developers who attempt to restore the feature programmatically encounter the following:
- Calling viewerInstance.UI.enableFeatures(...) from custom JavaScript fails at the viewerInstance.UI access step. The browser throws an exception and returns only the constructor name, indicating that the viewerInstance object does not expose the expected UI namespace in this context.
- Attempting to reference com.lowagie or the itext JAR in custom code fails to compile in Pega Platform 24.2.2 and later releases.
- The itext-2.1.7.jar or itext-2.0.8.jar file is absent from the platform classpath after updating to Pega Platform '24.2 or a later release.
Impact: users cannot place visual approval stamps on PDF attachments without a custom solution.
Steps to Reproduce
- Open a Case that contains an existing PDF attachment.
- Open the attachment in the inline PDF viewer. The PDF is displayed inside an <iframe> using a base64-encoded data URI.
- Attempt to interact with the PDF viewer to place a rubber stamp annotation.
- Result: No stamp or annotation tool is displayed. The browser's native PDF viewer controls the available tools, and no stamp functionality is present.
To reproduce the programmatic failure:
- Add custom JavaScript to a section or activity that attempts to call viewerInstance.UI.enableFeatures([viewerInstance.UI.Feature.Annotations]).
- Run the section.
- Result: The code fails at the viewerInstance.UI access step. The catch block fires and returns an alert containing only the constructor name. The test script did not enable interactive rubber stamping in the browser’s PDF preview.
Root Cause
Pega Platform™ does not provide this capability out of the box.
When a PDF attachment is displayed in an <iframe>, the browser's native PDF viewer controls what tools are available. Pega Platform does not provide an out-of-the-box control for selecting and placing interactive stamps in that viewer context. The interactive stamp experience previously observed was provided by the PDFTron integration, not by the platform itself. The viewerInstance object referenced in custom code is not a Pega Platform API and cannot enable additional annotation functionality in the browser viewer.
Additional Details
iText library removal and Apache PDFBox
Starting with Pega Platform '24.2, the platform no longer bundles iText 2.1.7 or any other version of iText. The eForms feature was refactored to use Apache PDFBox exclusively. iText is not available as a platform-provided library in Pega Platform '24.2 or any later release.
iText is a server-side PDF processing library and would not add an interactive drag-and-drop stamp tool to the browser viewer. Similarly, Apache PDFBox supports programmatic rubber stamp annotations through its PDAnnotationRubberStamp API but only adds stamp data to a PDF file server-side.
|
Layer |
Library |
Purpose |
|
Server-side |
iText / Apache PDFBox |
Generate, merge, stamp, and flatten PDFs |
|
Client-side |
PDFTron (Apryse) |
View, annotate, and sign PDFs in the browser |
If your application depends on iText APIs, you can upload the iText JAR as a custom library dependency using the application import feature. Be aware that this is a customization, that you are responsible for maintaining and carrying forward the dependency on each future update, and that compatibility is not guaranteed. Direct calls to third-party libraries bundled with or imported into Pega Platform are unsupported, and backward compatibility for those APIs is not guaranteed. For guidance, see the external reference below.
Solution
Local Change (Options)
Pega Platform does not provide a built-in replacement for the interactive stamp experience. The following options are available, depending on your requirements.
- Continue using PDFTron (now called ‘Apryse’). The existing PDFTron integration provides the interactive rubber stamp experience. If the goal is to replace PDFTron while keeping the stamp workflow, evaluate whether PDFTron can be retained for that specific use case.
- Implement a custom PDF annotation solution. You can integrate an alternative third-party PDF annotation library that supports interactive browser-based stamp placement. This is a customization and is not supported by Pega GCS beyond guidance on integration patterns.
- Manage the approval decision as Case data. If a visual stamp on the PDF document is not required, record the Approved / Not Approved decision as a Case property and reflect it in the Case lifecycle. This eliminates the PDF annotation requirement entirely and uses platform-native capabilities.
References
Pega Support: Troubleshooting document attachment issues with PDF inline preview