apyhub
ARTIFICIAL INTELLIGENCE · SMART GENERATION

Translate Text API

What it does

Text Translator translates content asynchronously and returns the translated text with the source and target languages. Send text in content, optionally add context, language, and voice_tone, then poll the job with the returned job_id until it finishes.

Use context when the same phrase needs a different meaning in product copy, support replies, or domain-specific documents. language tells the service what language the source text is in, and voice_tone lets you steer the style of the output, from casual wording to a specific writing tone. The response from job submission is just a job_id, so the workflow is built for queued translation work rather than immediate inline text replacement.

When the job completes, the status endpoint returns a structured result with content, to_language, and from_language, along with a job status of queued, running, success, or failed. That makes Text Translator useful for localization pipelines, support tooling, and multilingual content workflows where you need to submit text, track progress, and read back the translated result.

▣ ENDPOINT 01 / 02
POST
Translate Text Submit Job
https://api.eu.apyverse.com/sharpapi/translate-text

QUICKSTART

GUIDE

Quickstart

Send the text you want translated as JSON to start a translation job.

curl -X POST "https://api.eu.apyverse.com/sharpapi/translate-text" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"content":"Hello, world!","language":"German"}'

What you'll get back

Returns a JSON object with a job_id string field identifying the translation job.

{
  "job_id": "5de4887a-0dfd-49b6-8edb-9280e468c210"
}
TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
Provide the content to translate.
Provide additional context to the translated text, such as use case examples or additional explanations.
Specify the language of the content which needs to be translated.(For example: 'German').
Specify the voice tone of the output. It can be adjectives like `funny` or `joyous`, or even the name of a `famous writer`.

About this endpoint

What it does

Submits a text translation job for asynchronous processing. Send the text content and optional translation guidance in the request body; the response returns a job identifier you can use to track the job.

Request Body

ParameterTypeMandatoryDescription
contentStringYesProvide the content to translate.
contextStringNoProvide additional context to the translated text, such as use case examples or additional explanations.
languageStringNoSpecify the language of the content which needs to be translated. For example: German.
voice_toneStringNoSpecify the voice tone of the output. It can be adjectives like funny or joyous, or even the name of a famous writer.

Response

Returns a JSON object with a job_id string field — the identifier for the submitted translation job.

ParameterTypeMandatoryDescription
job_idStringYesJob identifier returned after the translation job is submitted.

Notes

This endpoint kicks off an async job and returns immediately with a job identifier; the actual work runs in the background. Pair this call with the corresponding job_check endpoint — poll that until the status reaches a terminal state to retrieve the result. Extract the job identifier from job_id.

Body

Name
Type
Description
bodyREQUIRED
object
▣ ENDPOINT 02 / 02
GET
Translate Text Check Job Status
https://api.eu.apyverse.com/sharpapi/translate-text/job/status/:job_id

QUICKSTART

GUIDE

Quickstart

Check the status of a translation job by its job ID.

curl -X GET "https://api.eu.apyverse.com/sharpapi/translate-text/job/status/:job_id" \
  -H "apy-token: $APY_TOKEN"

What you'll get back

Returns a JSON object with a data object. data contains id and type for the job result, plus an attributes object with the job status and type; when the job has finished successfully, attributes.result includes the translated content and source/target languages.

{
  "data": {
    "id": "5de4887a-0dfd-49b6-8edb-9280e468c210",
    "type": "api_job_result",
    "attributes": {
      "type": "content_translate",
      "status": "success",
      "result": {
        "content": "The rise in sea levels threatens to engulf the Maldives...",
        "to_language": "English",
        "from_language": "French"
      }
    }
  }
}
TRY ITLIVE · 1 ATOM
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.

About this endpoint

What it does

Checks the status of a previously submitted text translation job by job ID. On success, it returns the job record under a data object, including job metadata and, once the job is complete, the translated result details.

Path Parameter(s)

AttributeTypeMandatoryDescription
job_idStringYesThe translation job identifier, formatted as a string.

Response

Returns a JSON object with a required data object field. The data object contains id and type strings, plus an attributes object with type, status, and result fields; result is an object containing translated content and language metadata.

AttributeTypeMandatoryDescription
dataObjectYesJob result wrapper. Contains id, type, and attributes.
data.idStringYesThe job identifier, formatted as a string.
data.typeStringYesThe result resource type.
data.attributesObjectYesJob attributes wrapper. Contains type, status, and result.
data.attributes.typeStringYesThe job type.
data.attributes.statusENUMYesJob status. Allowed values: success, failed, running, queued.
data.attributes.resultObjectYesTranslation result object. Contains content, to_language, and from_language.
data.attributes.result.contentStringYesThe translated text content.
data.attributes.result.to_languageStringYesThe target language name.
data.attributes.result.from_languageStringYesThe source language name.

Notes

Poll this endpoint with the job_id returned by the submit call. The data.attributes.status field cycles through transitional values (queued, running) before reaching a terminal state (success, failed). The result fields under data.attributes.result are only populated once status is success; treat them as absent otherwise.

Path parameters

Name
Type
Description
job_idREQUIRED
string
▣ COMMON ERRORS

Errors any endpoint can return

400bad_request

Required parameter missing or malformed body.

401unauthorized

API key missing, revoked, or not authorized for this service.

429rate_limited

Your plan's per-second rate exceeded. Retry with exponential backoff.

503upstream_busy

Backend temporarily unavailable. Try again in a few seconds.