DetectLanguage · Example Payload

Detect Single

Example of detecting the language of a single text string using the POST /detect endpoint.

Language DetectionNatural Language ProcessingText AnalysisMachine LearningMultilingual

Detect Single is an example object payload from DetectLanguage, with 4 top-level fields. It illustrates the shape of data this provider's APIs accept or return.

Top-level fields

titledescriptionrequestresponse

Example Payload

Raw ↑
{
  "title": "Single Language Detection",
  "description": "Example of detecting the language of a single text string using the POST /detect endpoint.",
  "request": {
    "method": "POST",
    "url": "https://ws.detectlanguage.com/v3/detect",
    "headers": {
      "Authorization": "Bearer YOUR_API_KEY",
      "Content-Type": "application/json"
    },
    "body": {
      "q": "Hello world"
    }
  },
  "response": {
    "status": 200,
    "body": [
      {
        "language": "en",
        "score": 0.9098
      }
    ]
  }
}