Modules

Translation API

Translate text between 44 languages, find out which language a text is written in, and list the languages on offer. Names, numbers, links and line breaks are kept.

44languages
5,000characters per call
3methods
1,000free calls a month

These figures are counted from the data the API answers from.

What you get

Translate

Send a text and the language you want. The language it is written in can be given or left to be worked out.

Detect

Send a text and get back its language and how sure the answer is.

Languages

The list of languages with their codes, for the choices in your own form.

A call and its answer

curl -X POST https://developer.tratok.net/v1/ \
  -d "request=translate" \
  -d "id=YOUR_APP_ID" \
  -d "secret=YOUR_SECRET" \
  -d "text=Where is the nearest pharmacy?" \
  -d "targetLanguage=es"
{
  "status": "Ok",
  "originalLanguage": "auto",
  "newLanguage": "es",
  "originalMessage": "Where is the nearest pharmacy?",
  "translatedMessage": "¿Dónde está la farmacia más cercana?"
}

An illustration of the shape of the answer. Your own call returns the real text.

Good to know

  • One call translates up to 5,000 characters. Longer texts are sent in parts.
  • 1,000 free calls every calendar month for every module except Tara AI, then 0.01 TRAT a call.
  • A key is issued after a person has read your request. We usually answer within one working day.

The methods

Questions

Is the translation API free?

Every developer gets 1,000 free calls each calendar month, and translation calls count towards them. After the free calls a call costs 0.01 TRAT.

How long may a text be?

Up to 5,000 characters per call.

Which languages are there?

The supportedLanguages method returns the current list of 44 languages with their codes.

The other modules