<dependency>
<groupId>com.groupdocs</groupId>
<artifactId>groupdocs-viewer-cloud</artifactId>
<version>19.5</version>
</dependency>
compile(group: 'com.groupdocs', name: 'groupdocs-viewer-cloud', version: '19.5')
<dependency org="com.groupdocs" name="groupdocs-viewer-cloud" rev="19.5">
<artifact name="groupdocs-viewer-cloud" ext="jar"/>
</dependency>
libraryDependencies += "com.groupdocs" % "groupdocs-viewer-cloud" % "19.5"
Document Viewer Java Cloud REST API
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
- Ability to render files of various supported file formats into PDF, HTML, or Image formats.
- Get the list of attachments from supported file types, such as, Outlook Data File, Archives, PDF etc.
- While rendering documents into
HTML
format, utilize various options:- To reduce size of the rendered
HTML
, you may exclude common fonts from the rendered output. - Control the image size by limiting or restricting the height & width of the output image within the rendered
HTML
. - Remove extra white spaces & comments, etc while keeping the
HTML
content structure intact via HTML minification. - Convert output HTML to vector SVG for better quality printing.
- Render HTML in responsive mode to make it look consistent across all devices.
- To reduce size of the rendered
- While rendering documents into Image format, utilize various options:
- While rendering documents into
PDF
format, utilize various options: - Avail various other rendering options, such as:
- Apply watermark on the rendered PDF, HTML or Image output.
- Rotate pages on 90, 180, 270 degrees while rendering in HTML, PNG, JPG, & PDF formats.
- Render Word® documents, Excel® spreadsheets, PowerPoint® presentations, & PDF files with comments.
- Show PowerPoint® slide notes in the rendering result.
- Render diagrams with hidden pages, presentations with hidden slides, & spreadsheets with hidden worksheets.
- Provide desired starting page number to render
N
number of consecutive pages. - Add custom font sources while rendering.
- Replace missing or non-English fonts.
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:
- Java 1.7+
- 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
- Type: OAuth 2.0
- Flow: application
- Authorization URL: https://api.groupdocs.cloud/connect/token
- Token Lifetime: 1 day (Default)
Product Page | Docs | Live Demos | Swagger UI | Code Samples | Blog | Free Support | Free Trial
Version | Release Date |
---|---|
24.8 | August 26, 2024 |
24.3 | March 26, 2024 |
24.2 | February 1, 2024 |
23.10 | September 29, 2023 |
23.7 | July 10, 2023 |
23.3 | March 16, 2023 |
21.12 | December 25, 2021 |
21.10 | October 25, 2021 |
21.8 | August 1, 2021 |
21.3 | March 18, 2021 |
20.5 | May 1, 2020 |
20.3 | March 1, 2020 |
19.5 | May 1, 2019 |
19.4 | April 25, 2019 |
19.3.2 | April 5, 2019 |
19.3 | March 7, 2019 |
18.11 | November 9, 2018 |
18.7 | July 25, 2018 |
18.5 | May 25, 2018 |
File | Classifier | Size |
---|---|---|
groupdocs-viewer-cloud-19.5-javadoc.jar | javadoc | 876 KB |
groupdocs-viewer-cloud-19.5-sources.jar | sources | 138 KB |
groupdocs-viewer-cloud-19.5.jar | 206 KB | |
groupdocs-viewer-cloud-19.5.pom | 2 KB |