Document Annotation via Java API

Build Java Applications to manage various Annotation Types and to Tag & Comment your Document Contents for Easy Collaboration.

  Download Free Trial
Java document annotation API

GroupDocs.Annotation for Java


GroupDocs.Annotation for Java API provides easy to use document, annotation management and manipulation functionality to be used in your Java based business applications. Our Annotation Java API allows you to work with many types of annotations, which include text, polyline, area, underline, point etc. GroupDocs.Annotation API also offers a comprehensive set of data objects to customize annotation properties as per your requirements, in documents, spreadsheets, presentation slides, CAD & Visio Drawings, images and other supported formats.

GroupDocs.Annotation for Java Features



Add Area Annotation in Document and Link Simple & Nested Comments


Point to a Particular Content using Arrow Annotation


Represent Distance among Objects using Distance Annotation


Add Popup Comments to any Place in the Document using Point Annotation


Use Polyline Annotation to Connect Sequence of Line Segments, Arc Segments or both


Mark Areas in a Document that won’t Change & are Proposed for Redaction


Add Gloss to Highlighted Text


Fetch Coordinates of Text Annotation in Image Representation of a Document


Underline, Strikethrough or Modify Specific Text in a Document


Add Text Stamp or Watermark & Text Field in a Document


Import & Export Annotations among Word Documents & PowerPoint Presentations


Add Text Annotation in Microsoft Excel to a Specific Cell


Add Polyline, Strikethrough, Underline or Text Annotations to Presentation Slides


Mark Point Annotation in Presentations using X, Y Coordinates


Add Strikethrough, Text, Underline or Polyline Annotations to Images


Fetch Document Information & Images for Visio Diagrams, such as, VSS & VSD


Perform Annotation Management Tasks using Data Storage


Add, Modify & Delete Annotations & Replies in Data Storage


Assign Access Rights to Users for Allowed Annotation Actions


Fetch all Annotation of a Document with a Single Function Call


Move Location, Configure Properties for Supported Annotation Types

Support for Multiple Types of Annotation

GroupDocs.Annotation for Java API works with lot of annotation types. This diversity provides easy and efficient means of collaboration among teams, as per their requirement. GroupDocs.Annotation for Java API supports, area annotation (mark an area as rectangle and add notes to it), text annotation (add comment to selected text), strikeout/underline annotation (applied to a paragraph), point annotation (stick comments at any point in document), polyline annotation (draw shapes and freehand lines), distance annotation (draw a line that represents distance among objects), watermark annotation (text stamp or watermark can be added in document) and arrow annotation (arrow pointer with attached comments).

Add Text Annotation using Java

 // Initialize list of AnnotationInfo
List<AnnotationInfo> annotations = new ArrayList<AnnotationInfo>();
 // Initialize text annotation
AnnotationInfo textAnnotation = new AnnotationInfo();
textAnnotation.setBox(new Rectangle(68, 154, 102, 9)); 
// Add annotation to the document
InputStream result = annotator.exportAnnotationsToDocument(cleanPdf, annotations, DocumentType.Pdf);
// Save result stream to file
OutputStream fileStream = new FileOutputStream(Utilities.outputPath + File.separator + "annotated-text.pdf");
IOUtils.copy(result, fileStream);

Configurable Data Object Properties

GroupDocs.Annotation for Java API consists of an extensive collection of data objects with configurable properties, used in data storage. These properties include, Annotation (coordinates, dimensions, type, color, frame style, background color etc.), Annotation Collaborator (ID, document, access rights etc.), Annotation Reply (reply, parent annotation, GUID, message, time etc.), Document (GUID, name, owner, type, access rights etc.), User (ID, nick, email, password, photo etc.).

User Rights Access Management

GroupDocs.Annotation for Java API empowers you to easily manage user rights for accessing annotations. You can assign or revoke user access rights by configuring properties, such as, View, Annotate, Download, Export, Delete etc.

Support and Learning Resources


GroupDocs.Annotation offers document automation APIs for other popular development environments as listed below: