Callback - Automatic sending of results

To avoid constant checks by the client regarding the status of translations or content generation, the Ovesio platform offers an automatic callback notification mechanism.

This mechanism involves automatically sending the result to a URL provided by the client, as soon as the operation has been successfully completed.

How it works

  • If a callback_url address is set in the API request or in the Workflow, the system will automatically send the result using the POST method to that address.
  • The response sent is of type application/json and contains the result structure specific to each type of operation:
    • translations (one post for each language)
    • generate descriptions
    • generate SEO meta tags

Callback URL requirements

  • Must return HTTP status code 200
  • It must respond with the JSON:
     {
    "success": true
    }
  • Any other type of response or status code will be considered invalid.

Retry mechanism

In case of an invalid response, the system will automatically try 3 times (first time + 2 retries).

If a valid response is not received after 3 attempts, the operation will be marked as failed upon submission . Subsequently, the client has two options:

  • Can manually resend the result directly from the Ovesio app
  • Can obtain the result using the dedicated status API endpoint or other endpoints intended for retrieving status

Specific rules for translations

The translation callback is only sent under the following conditions :

  1. If the callback option is enabled in Workflow and:
    • a default callback_url is defined
    • "Ignore Duplicate Callback" option is disabled

    If the "Ignore Duplicate Callback" option is enabled, a callback will only be sent for new translations . Requests that target previously translated texts will not trigger a new callback.

  2. If a callback_url is explicitly sent in the API request , even if the Workflow has a different default URL.
    • If you want to enable the behavior of avoiding duplicate callbacks, you can use the parameter:
     "delta_mode": true

    The default value is false .

⚠ In the case of content generation (descriptions, meta tags), the "Ignore Duplicate Callback" option does not apply , and the response will always be sent if a callback_url is present.

Format of responses sent via callback

1. Text translation
{
  "id": 346,
  "ref": "product/7492",
  "to": "en",
  "from": "ro",
  "content": [
    {
      "key": "description",
      "value": "<p>...</p>"
    }
  ]
}
2. Generate descriptions
{
  "id": 3419,
  "ref": "product/72017",
  "to": "ro",
  "content": {
    "description": "<p>...</p>"
  }
}
3. Generate SEO meta tags
{
  "id": 3422,
  "ref": "product/71072",
  "to": "ro",
  "content": {
    "seo_h1": "...",
    "seo_h2": "...",
    "seo_h3": "...",
    "meta_title": "...",
    "meta_description": "...",
    "meta_keywords": "..."
  }
}