Quickstart
Create an account
Creating an account is very simple. Go to https://dashboard.groupdocs.cloud to create a free account.
Get Client Id and Client Secret
Before you can make any requests to GroupDocs Cloud API you need to get Client Id and Client Secret.
This will be used to invoke the GroupDocs Cloud API.
You can get it from any existing Application or you can create a new Application.
For further details see Create New Application and Get Client Id and Client Secret
Get your JWT token
After you have created a new application you can obtain a JWT token. See this page for further details about this.
Call Rest API
When you’ve got your access_token you can make Rest API call by adding to Headers of your request:
- Authorization: Bearer access_token
To translate plain text
cURL
Request
curl -X POST "https://api.groupdocs.cloud/v1.0/translation/text" \
-H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
-d "'[{\"pair\": \"en-fr\", \"text\": \"Welcome to Paris\"}]'"
Response
{
"status": "ok",
"message": "Text translated successfully",
"translation": "Bienvenue à Paris"
}
SDKs
To translate document
cURL
Request
curl -X POST "https://api.groupdocs.cloud/v1.0/translation/document" \
-H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
-d "'[ { \"format\":\"docx\", \"outformat\":\"docx\", \"pair\":\"en-fr\", \"name\":\"document.docx\", \"folder\":\"myFolder\", \"savepath\":\"myFolder\", \"savefile\":\"translatedDoc.docx\", \"storage\":\"MyStorage\", \"masters\": false, \"elements\": []}]'"
Response
{
"status": "ok",
"message": ".docx file saved successfully"
}