POST
/
json
/
v1
/
languages
/
detect
curl --request POST \
  --url https://api.jsontrans.com/json/v1/languages/detect \
  --header 'Content-Type: application/json' \
  --header 'jt-api-key: <jt-api-key>' \
  --data '{
  "source_text": "hello!"
}'
{
  "code": 200,
  "msg": "Language detected successfully",
  "data": {
    "detected_lang_code": "en"
  }
}

Headers

jt-api-key
string
required

API authentication key

Body

application/json
Text for language detection
source_text
string
required

Text to be analyzed for language detection

Example:

"hello!"

Response

200
application/json
Successful language detection
code
integer
Example:

200

msg
string
Example:

"Language detected successfully"

data
object