Skip to content

Translate Phrase

POST
/api/creative/conlang/languages/{language_id}/translate

Translate a phrase using the lexicon.

language_id
required
Language Id
string
TranslationRequest

Request to translate a phrase.

object
phrase
required
Phrase
string
>= 1 characters
direction
Direction
string
default: to_conlang

Successful Response

TranslationResponse

Response from the translation helper.

object
sourcePhrase
required
Sourcephrase
string
translatedPhrase
required
Translatedphrase
string
words
required
Words
Array<object>
TranslationWord

A single word in a translation result.

object
source
required
Source
string
target
Any of:
string
found
required
Found
boolean
missingCount
required
Missingcount
integer

Validation Error

HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object