API Developers Guide
One Hour Translation API exposes various methods and services delivered by One Hour Translation and allows external systems to securely launch, monitor and communicate with translation jobs.
Request URLs:
API Base URL: https://www.onehourtranslation.com/api/2
API Sandbox URL: https://sandbox.onehourtranslation.com/api/2
API Sandbox URL: https://sandbox.onehourtranslation.com/api/2
Authentication:
Each request must include the public_key and secret_key parameters, as supplied by One Hour Translation.
To get your API keys on the Production environment, please click here
To get your API keys on the Sandbox environment, please click here
To get your API keys on the Production environment, please click here
To get your API keys on the Sandbox environment, please click here
Response Format:
Responses are encoded according to the JSON scheme, Long and complex values are further encoded with Base64. Each response will include the “status” entity which represent a success or failure in processing your request. The complete status codes list may be viewed here.
Response Example:
{
"status": {
"code": 0,
"msg": "ok"
},
"errors": [ /*array of errors*/ ],
"results": [ /*method-specific parameters as specified below*/ ]
}
"status": {
"code": 0,
"msg": "ok"
},
"errors": [ /*array of errors*/ ],
"results": [ /*method-specific parameters as specified below*/ ]
}
Callbacks:
Some requests allow you to specify a callback URL. This URL will be used on time critical events, for example, when a translation has been received for your project. Read more about callbacks here.
Developer Friendly:
We are developing tools that may accelerate your development and testing process dramatically.
More tools will be published here once available.
Client Libraries:
Testing and Debugging:
- We recommend using the Postman application.
After installing Postman, download and import the Methods Collection. You can also import the Environment paramenters to the "Environment" section in Postman.
Sandbox Usage:
OneHourTranslation provides a separated, semi-functional version on OHT for testing and development purposes. The sandbox environment may be accessed here:
https://sandbox.onehourtranslation.com
In order to use OHT sandbox, please note following:
- The sandbox is fully functional as a website and API interface but is completely non functional for translation purposes or any other professional services.
- To get started, please create a user account on OHT sandbox. Once an account is established, create your API keys here.
- Every text/file you submit for translation will be copied and returned to your system as a translation. For XML/HTML files the translation will return a reversed form of the file content. For XLIFF/PO files the translation will return reversed source in the target field of the file.
- Note: This behavior is limited to the sandbox only. Texts and XMLs you submit to OneHourTranslation.com will only be translated by real human translators.
- The sandbox environment only supports English to French translation at the moment. Other language pair will invoke a "language pair is currently unsupported" (#201) error code.
API V1:
API V1 information can be downloaded here.
IP addresses:
The following IPs will be used on outbound callbacks from API to your infrastructure
Production: 107.23.108.160
Sandbox: 34.201.183.17