<dependency>
<groupId>com.groupdocs</groupId>
<artifactId>groupdocs-viewer-cloud</artifactId>
<version>24.8</version>
</dependency>
copied!  
compile(group: 'com.groupdocs', name: 'groupdocs-viewer-cloud', version: '24.8')
copied!  
<dependency org="com.groupdocs" name="groupdocs-viewer-cloud" rev="24.8">
 <artifact name="groupdocs-viewer-cloud" ext="jar"/>
</dependency>
copied!  
libraryDependencies += "com.groupdocs" % "groupdocs-viewer-cloud" % "24.8"
copied!  

Document Viewer Java Cloud REST API

main-banner

Product Page | Docs | Live Demos | Swagger UI | Code Samples | Blog | Free Support | Free Trial

GroupDocs.Viewer Cloud SDK for Java helps you build cloud Document Rendering & Viewing Java Apps that work without installing any 3rd party software. It is a wrapper around GroupDocs.Viewer Cloud REST APIs.

Cloud Document Viewing SDK Features

Please visit our Official Documentation for a more comprehensive list of features.

Supported Document Viewer File Formats

Microsoft Word®: DOC, DOCM, DOCX, DOT, DOTM, DOTX, RTF, TXT
OpenOffice Writer®: ODT, OTT
Microsoft Excel®: XLS, XLSB, XLSM, XLSX
OpenOffice Calc®: ODS, OTS
Microsoft PowerPoint®: PPT, PPTX, PPTM, PPS, PPSX, POTX, POTM
OpenOffice Impress®: ODP, OTP
Microsoft Visio®: VDW, VDX, VSD, VSDM, VSDX, VSS, VSSM, VSSX, VST, VSTM, VSTX, VSX, VTX
Microsoft OneNote®: ONE
Microsoft Project®: MMP, MPT
Microsoft Outlook®: EML, MSG, OST, PST
Apple® Mail: EMLX
CAD: DGN, DWF, DWG, DXF, IFC, STL
eBook: EPUB, MOBI
Images: BMP, DJVU, DNG, DIG, ICO, JP2, JPG, JPEG, ODG, PCL, PNG, TIF, TIFF, WEBP
Medical Imaging: DCM
Adobe Postscript®: PSD
Postscript: PS, EPS
Vector Images: SVG
Markup: HTML, MHT, MHTML
Fixed Layout: PDF, XPS
LaTeX: TEX
Meta Files: CGM, EMF, WMF

Requirements

Building the API client library requires:

  1. Java 1.7+
  2. Maven

Prerequisites

To use GroupDocs.Viewer Cloud SDK for Java you need to register an account with GroupDocs Cloud and lookup/create Client ID and Client Secret at Cloud Dashboard. There is free quota available. For more details, see GroupDocs Cloud Pricing.

Install GroupDocs.Viewer-Cloud from Maven

Add GroupDocs Cloud repository to your application pom.xml

<repository>
    <id>repository.groupdocs.cloud</id>
    <name>repository.groupdocs.cloud</name>
    <url>https://releases.groupdocs.cloud/java/repo/</url>
</repository>

Install from source

To install the API client library to your local Maven repository, simply execute:

mvn clean install

To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:

mvn clean deploy

Refer to the OSSRH Guide for more information.

Maven users

Add this dependency to your project’s POM:

<dependency>
    <groupId>com.groupdocs</groupId>
    <artifactId>groupdocs-viewer-cloud</artifactId>
    <version>21.12</version>
    <type>pom</type>
</dependency>

Others

At first generate the JAR by executing:

mvn clean package

Then manually install the following JARs:

  • target/groupdocs-viewer-cloud-21.12.jar
  • target/lib/*.jar

Get Started

Please follow the Quick Start instructions.

Render a Word® Document including Track Changes via Java Cloud SDK

// For complete examples and data files, please go to https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-java-samples
string MyClientSecret = ""; // Get Client Id and Client Secret from https://dashboard.groupdocs.cloud
string MyClientId = ""; // Get Client Id and Client Secret from https://dashboard.groupdocs.cloud

Configuration configuration = new Configuration(MyClientId, MyClientSecret);
ViewApi apiInstance = new ViewApi(configuration);

FileInfo fileInfo = new FileInfo();
fileInfo.setFilePath("SampleFiles/with_tracked_changes.docx");
ViewOptions viewOptions = new ViewOptions();
viewOptions.setFileInfo(fileInfo);
viewOptions.setViewFormat(ViewFormatEnum.HTML);
HtmlOptions renderOptions = new HtmlOptions();
WordProcessingOptions wordProcessingOptions = new WordProcessingOptions();
wordProcessingOptions.setRenderTrackedChanges(true);
renderOptions.setWordProcessingOptions(wordProcessingOptions);
viewOptions.setRenderOptions(renderOptions);

ViewResult response = apiInstance.createView(new CreateViewRequest(viewOptions));

Authorization & Authentication

Authentication schemes defined for the API is as follows:

JWT

Product Page | Docs | Live Demos | Swagger UI | Code Samples | Blog | Free Support | Free Trial

VersionRelease Date
24.8August 26, 2024
24.3March 26, 2024
24.2February 1, 2024
23.10September 29, 2023
23.7July 10, 2023
23.3March 16, 2023
21.12December 25, 2021
21.10October 25, 2021
21.8August 1, 2021
21.3March 18, 2021
20.5May 1, 2020
20.3March 1, 2020
19.5May 1, 2019
19.4April 25, 2019
19.3.2April 5, 2019
19.3March 7, 2019
18.11November 9, 2018
18.7July 25, 2018
18.5May 25, 2018