Skip to main content

Submit a translation request

This endpoint allows a translation request to be sent to the Ovesio system. You can send multiple texts in a single request, each with its own keys and contexts, and the translation can be done simultaneously in several languages.

Endpoint URL​

https://api.ovesio.com/v1/translate/request

Method​

POST

Data format​

application/json

Example JSON request​

{
"from": "en",
"to": ["fr", "de"],
"conditions": {
"de": "fr"
},
"use_existing_translation": true,
"delta_mode": false,
"workflow": 1,
"callback_url": "https://example.com/api/callback",
"data": [
{
"ref": "product-123",
"content": [
{
"key": "title",
"value": "Gaming Laptop ASUS ROG"
},
{
"key": "description",
"value": "High-performance laptop for gaming",
"context": "Specificații produs"
}
]
}
]
}

Application parameters​

ParameterTypeRequiredDescription
fromstringyesSource language. If it is not known, it can be omitted (AUTO).
delta_modeBooleannotTurn on callback only if the translation is different from the previous one.
WorkflowintegernotThe ID of the desired workflow.
use_existing_translationBooleannotIf false, forces the retranslation even if the text already exists in the system.
toArrayyesTarget languages (e.g. ["fr", "de"]).
ConditionsObjectnotAllows defining intermediate languages in chain translations (e.g. {"de": "fr"}).
callback_urlstringnotThe URL to which the translation results will be sent via POST.
dataArrayyesTexts to be translated.

Field structure data​

RequiredTypeField Description
refstringnotUnique identifier (e.g. product ID, item, etc.).
contentArrayyesList of texts, each with its own value and optional key and context.

​

Field structure content​

RequiredTypeField Description
keystringnotText tag (e.g., title, description etc.).
ValuestringyesThe actual text to be translated.
contextstringnotSemantic context for the translation (e.g. "product category").

​

Possible answers​

Successful response (HTTP 200)​

{
"success": true,
"data": [
{
"id": 320126,
"ref": "product-123"
}
]
}

Confirm that the application has been accepted and the translation process has been initiated. You can use id it to check the status later.

Error response (HTTP 400 or other ≠ 200 code)​

{
"success": false,
"errors": {
"invalid_data": "Invalid format detected"
}
}

This structure indicates that the request was invalid, and the errors field will contain specific details about the issue encountered.

Integration examples​

You can check out examples of integration available on the official GitHub Ovesio page.