Resource to translate given keys (optionally including parameters)
Get the current session language
media type | data type | description |
---|---|---|
application/json | LanguageResponse (JSON) | session language |
GET /i18n/get
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"code" : "...",
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
media type | data type | description |
---|---|---|
application/json | UILanguagesResponse (JSON) |
GET /i18n/list
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"items" : [ { }, { } ],
"hasMoreItems" : true,
"numItems" : 12345,
"perms" : {
"property1" : [ "wastebin", "translatepages" ],
"property2" : [ "publish", "readitems" ]
},
"stagingStatus" : {
"property1" : {
"packageName" : "...",
"included" : true
},
"property2" : {
"packageName" : "...",
"included" : true
}
},
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Set the current session language
media type | data type | description |
---|---|---|
application/json | SetLanguageRequest (JSON) | request to set the current session language |
media type | data type | description |
---|---|---|
application/json | GenericResponse (JSON) | response |
POST /i18n/set
Content-Type: application/json
Accept: application/json
{
"code" : "..."
}
HTTP/1.1 201 Created
Content-Type: application/json
{
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Translate the given key and optional parameters (variant with key given as query parameter)
name | type | description | multivalued |
---|---|---|---|
k | query | translation key | no |
p | query | optional parameters | yes |
media type | data type | description |
---|---|---|
text/plain;charset=UTF-8 | string | translated string |
GET /i18n/t
Content-Type: */*
Accept: text/plain;charset=UTF-8
...
HTTP/1.1 200 OK
Content-Type: text/plain;charset=UTF-8
...
Translate the given key and optional parameters (variant with key given in the path)
name | type | description | multivalued |
---|---|---|---|
key | path | translation key | no |
p | query | optional parameters | yes |
media type | data type | description |
---|---|---|
text/plain;charset=UTF-8 | string | translated string |
GET /i18n/t/{key}
Content-Type: */*
Accept: text/plain;charset=UTF-8
...
HTTP/1.1 200 OK
Content-Type: text/plain;charset=UTF-8
...