Home » Programming Interface

Programming Interface

ICanLocalize can be used as a translation server for any application.

Key features

Professional translation
All translations are done by professional translators, writing in their native languages. ICanLocalize hires the translators and validates their translation qualifications. Clients can choose the translators who work on their projects from the translators in ICanLocalize’s pool.
Self service
Clients set up their projects, choose translators and send contents to translation. There’s no need to a project manager, so projects can run quickly and on a low budget.
Fully embedded solution
All interaction between clients and translators can be embedded in the host application. Clients don’t need to visit ICanLocalize site.

How it works

Generally, there are two types of calls:

  • Calls to ICanLocalize server – done using HTTP / HTTPS using XML data structures.
  • Notification from ICanLocalize server to the host server. These are done using XML-RPC.

Step 1) Set up a project

All translations are grouped into projects. A project can include several translation languages, each assigned to a translator.

To create a project, call:

POST: https://www.icanlocalize.com/websites/create_by_cms.xml

Arguments:

Argument Description
email User email (all communication will be done with that email address)
fname First name
lname Last name
password Password (optional)
create_account 0 – use and existing account (password required), 1 – create a new account (password will be emailed)
is_verified Set to 1
platform_kind Set to 2
interview_translators Set to 0
cms_kind Each type of CMS gets a unique identifier. Contact ICanLocalize.
cms_description Name of the content management system
url URL of website
title Title of website
description Desciption of website
pickup_type 0 – ICanLocalize will send XML-RPC notifications / 1 – host system will poll translations
notifications Integer value, determining which notifications to send
project_kind TBD
from_languageN Name of destination language N (projects can have any number of language pairs)
to_languageN Name of target language N (each destination language needs to have a corresponding target language)

On success, ICanLocalize will return an XML structure with the project information.

Step 2) Send documents to translation

There are two types of documents that can be sent to translation. These are HTML documents and simple texts.

To send HTML documents for translation, do the following call:

POST: https://www.icanlocalize.com/websites/wID/cms_requests.xml

Arguments:

Argument Description
orig_language Name of original language
to_languageN Name of destination language N
key Unique identifier by CMS, to protect against duplicate requests for the same contents
title Title of document
note Note to translators (optional)
doc_count Document count (number of attached files)
fileN Multitype field for the attached file for translation. The number of attached files must agree with the doc_count argument

On successful request creation, ICanLocalize will return the request ID.

To send plain text for translation, use the following call:

POST: https://www.icanlocalize.com/websites/wID/create_message.xml

Arguments:

Argument Description
body Text to translate, base64 encoded
from_language Name of source language
to_language Name of destination language
signature Integrity validation: MD5(body+from_languageto_language)

On successful request creation, ICanLocalize will return the request ID.

Step 3) Return the translation

When translation is complete, ICanLocalize will notify the host system.

This is done using the following XML-RPC call from ICanLocalize:

icanlocalize.update_translation_status

ICanLocalize will send the document ID, language, translation status and signature.

The host system will then contact ICanLocalize server back and fetch the completed translation.