<dependency>
<groupId>com.groupdocs</groupId>
<artifactId>groupdocs-rewriter-cloud</artifactId>
<version>24.11</version>
</dependency>
compile(group: 'com.groupdocs', name: 'groupdocs-rewriter-cloud', version: '24.11')
<dependency org="com.groupdocs" name="groupdocs-rewriter-cloud" rev="24.11">
<artifact name="groupdocs-rewriter-cloud" ext="jar"/>
</dependency>
libraryDependencies += "com.groupdocs" % "groupdocs-rewriter-cloud" % "24.11"
Java SDK for GroupDocs.Rewriter Cloud
Product Page | Documentation | Demos | Swagger UI | Examples | Blog | Search | Free Support | Free Trial
GroupDocs.Rewriter Cloud SDK for Java is a simple Python SDK that enables your cloud Apps to perform paraphrasing, simplification, summarization and paraphrasing detection of Microsoft Word®, OpenOffice, Markdown, HTML and Adobe Acrobat® PDF documents as well as plain text by adding just a few lines of code.
In other words, it’s a SDK for document and plain text rewriting, summarization, etc. in our Cloud, that supports paraphrasing of .doc, .docx, .docm, .pdf, .rtf, .odt, .md, .html, .txt files. Just pass a specific file or text to the GroupDocs.Rewriter Cloud API, and it will process and save result in our Cloud or will return resulting text.
It is easy to get started with GroupDocs.Rewriter Cloud and there is nothing to install. Create an account at GroupDocs Cloud and get your application information, then you are ready to use SDKs.
Cloud Features
- Paraphrasing / summarization / simplification / paraphrase detection of documents
- Paraphrasing / summarization / simplification / paraphrase detection / comparison of plain text
- Words and idioms synonyms finder
- Return resulting text in response
- Save processed file in cloud
- No need to install any 3rd party software
Supported Document Formats
You can specify format of document to process putting in the request’s body:
- Microsoft Word®: DOC, DOCX, DOCM
- Adobe®: PDF
- Markdown: MD
- HTML: HTML
- Other: RTF, ODT, TXT
Additionally, user could obtain processed file in any other format available for conversion. Just specify output format of paraphrased document by putting file extension in the request’s body:
- doc, docx — docx, rtf, html, odt, txt, md, pdf, tiff, svg, xps
- pdf — docx, pptx, html, svg, xps
- html — md, pdf, docx, tiff, xps
Please visit Supported Formats for details.
Supported Languages
- ar — to process Arabic text or document
- de — to process German text or document
- en — to process English text or document
- es — to process Spanish text or document
- fr — to process French text or document
- id — to process Indonesian text or document
- ru — to process Russian text or document
- uk — to process Ukrainian text or document
- sk — to process Slovak text or document
- pt — to process Portuguese text or document
- it — to process Italian text or document
How to use the SDK?
Our API is completely independent of your operating system, database system, or development language. You can use any language and platform that supports HTTP to interact with our API. However, manually writing client code can be difficult, error-prone, and time-consuming. Therefore, we provide and support SDKs in many development languages to make it easier for your Cloud Apps to integrate with us.
Requirements
Building the API client library requires:
- Java 1.8+
- Maven (3.8.3+)/Gradle (7.2+)
Installation
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-rewriter-cloud</artifactId>
<version>24.4</version>
<scope>compile</scope>
</dependency>
Gradle users
Add this dependency to your project’s build file:
repositories {
mavenCentral() // Needed if the 'GroupDocs-rewriter-cloud' jar has been published to maven central.
mavenLocal() // Needed if the 'GroupDocs-rewriter-cloud' jar has been published to the local maven repo.
}
dependencies {
implementation "com.groupdocs:GroupDocs-rewriter-cloud:24.4"
}
Others
At first generate the JAR by executing:
mvn clean package
Then manually install the following JARs:
target/GroupDocs-rewriter-cloud-24.4.jar
target/lib/*.jar
Quickstart
1. Get Started
It is easy to get started with GroupDocs.Rewriter Cloud. Simply, create an account at GroupDocs Cloud and get your application information, then you are ready to use the SDKs.
2. Run Demo
- Checkout the SDK
- Open Demo.java
- Set Your ClientId & ClientSecret
- Run
Rewrite plain text
package com.groupdocs;
// Import classes:
import com.groupdocs.model.*;
import org.openapitools.client.api.ParaphraseApi;
public class Demo {
public static void main(String[] args) {
String basePath = "https://api.groupdocs.cloud/v2.0/rewriter";
// Get Client Id and Client Secret from https://dashboard.groupdocs.cloud
String cliendId = "YOUR_CLIENT_ID";
String clientSecret = "YOUR_CLIENT_SECRET";
// Create instance of the API
ApiClient defaultClient = new ApiClient(basePath, cliendId, clientSecret, null);
ParaphraseApi apiInstance = new ParaphraseApi(defaultClient);
String s = "TEXT_TO_PARAPHRASE";
ParaphraseTextRequest request = new ParaphraseTextRequest();
request.setLanguage("en");
request.setText(s);
try {
StatusResponse response = apiInstance.paraphraseTextPost(request);
String response_id = response.getId();
if (!response.getStatus().toString().equals("BadRequest")){
while (true){
ParaphraseTextResponse paraphraseTextResponse = apiInstance.paraphraseTextRequestIdGet(response_id);
if (paraphraseTextResponse.getStatus().toString().equals("OK")) {
System.out.println(paraphraseTextResponse);
break;
}
try {
Thread.sleep(2000);
} catch (InterruptedException e) {
e.printStackTrace();
}
}
}
} catch (ApiException e) {
System.err.println("Exception when calling ParaphraseApi#paraphraseTextPost");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Product Page | Docs | Demos | Swagger UI | Examples | Blog | Search | Free Support | Free Trial
File | Classifier | Size |
---|---|---|
groupdocs-rewriter-cloud-24.11.jar | 6 MB | |
groupdocs-rewriter-cloud-24.11.pom | 13 KB |