GET https://platform.api.onesky.io/1/projects/:project_id/orders
Authentication
Required. Details described here
Parameters
Name | Required? | Default | Sample | Description |
page | optional | 1 |
Set page number to retrieve. (min: 1) | |
per_page | optional | 50 |
Set how many groups to retrieve for each time. (max: 100, min: 1) | |
file_name | optional | string.po |
Filter orders by file name. |
Response
status 200 OK
{
"meta": {
"status": 200,
"record_count": 26
},
"data": [
{
"id": 123,
"status": "in-progress",
"ordered_at": "2013-08-15T08:12:40+0000",
"ordered_at_timestamp":13283746583
},
{
"id": 122,
"status": "completed",
"ordered_at": "2013-08-15T08:12:40+0000",
"ordered_at_timestamp":13283746583
},
...
]
}
Remark: status
can be either pending
, in-progress
, completed
or failed
. Details please refer to Order Status
GET https://platform.api.onesky.io/1/projects/:project_id/orders/:order_id
Authentication
Required. Details described here
Parameters
NONE
Response
status 200 OK
{
"meta": {
"status": 200
},
"data": {
"id": 123,
"status": "in-progress",
"amount": "695.00",
"files": [
{
"name": "string.po"
},
{
"name": "string2.po"
},
...
],
"from_language": {
"code": "en-US",
"english_name": "English (United States)",
"local_name": "English (United States)",
"locale": "en",
"region" : "US"
},
"tasks": [
{
"status": "completed",
"to_language": {
"code": "ko-KR",
"english_name": "Korean",
"local_name": "한국어",
"locale": "ko",
"region" : "KR"
},
"translator":{
"name": "Jinny O."
},
"string_count": 835,
"word_count": 3056,
"will_complete_at": null,
"will_complete_at_timestamp": null,
"seconds_to_complete": 0,
"completed_at": "2013-08-17T13:05:20+0000",
"completed_at_timestamp": 1376744720
},
...
],
"order_type": "translate-only",
"tone": "formal",
"specialization": "general",
"note": "Message to translator",
"ordered_at": "2013-08-15T08:12:40+0000",
"ordered_at_timestamp":13283746583
}
}
Remark:
status
of order (insidedata
) can be eitherpending
,in-progress
,completed
orfailed
. Details please refer to Order Statusstatus
of order tasks (insidetasks
) can be eitherin-progress
orcompleted
. Details please refer to Order Task Status
POST https://platform.api.onesky.io/1/projects/:project_id/orders
Authentication
Required. Details described here
Parameters
Name | Required? | Default | Sample | Description |
files | required | ['string.po'] |
Files to be translated in the order | |
to_locale | required | zh-TW |
Target language to tranlate. Please refer to GET locales | |
order_type | optional | translate-only |
review-only |
Specify type of order.
Types:
|
is_including_not_translated | optional | true |
false |
Include not translated phrases to translate |
is_including_not_approved | optional | true |
false |
Include not approved phrases to translate |
is_including_outdated | optional | true |
false |
Include outdated phrases to translate that is updated since last order. |
translator_type | optional | preferred |
fastest |
Specify type of translator used in translation.
Types:
|
tone | optional | not-specified |
formal |
Specify the tone used in translation.
Currently supported:
|
specialization | optional | general |
game |
Specify specialization in order to translate phrases in a specific area.
Currently supported:
|
note | optional | Note to translator. |
Response
status 201 Created
{
"meta": {
"status": 201
},
"data": {
"id": 372,
"files": [
{
"name": "string.po"
},
{
"name": "string2.po"
},
...
],
"from_language": {
"code": "en-US",
"english_name": "English (United States)",
"local_name": "English (United States)",
"locale": "en",
"region" : "US"
},
"to_language": {
"code": "ja-JP",
"english_name": "Japanese",
"local_name": "日本語",
"locale": "ja",
"region" : "JP"
},
"order_type": "translate-only",
"is_including_not_translated": true,
"is_including_not_approved": false,
"is_including_outdated": true,
"tone": "formal",
"specialization": "general",
"note": "Message to translator",
"ordered_at": "2013-08-15T08:12:40+0000",
"ordered_at_timestamp":13283746583,
}
}