POST
/
v2
/
writer-detector
/
{scanId}
/
check
curl --request POST \
  --url https://api.copyleaks.com/v2/writer-detector/my-scan-123/check \
  --header 'Authorization: Bearer YOUR_LOGIN_TOKEN' \
  --header 'Content-Type: application/json' \
  --data '{
    "text": "Copyleaks is a comprehensive plagiarism detection platform...",
    "sandbox": false,
    "explain": true,
    "sensitivity": 2
  }'
{
  "modelVersion": "v5",
  "results": [
    {
      "classification": 2,
      "probability": 1,
      "matches": [
        {
          "text": {
            "chars": { "starts": [0], "lengths": [1509] },
            "words": { "starts": [0], "lengths": [221] }
          }
        }
      ]
    }
  ],
  "summary": { "human": 0, "ai": 1 },
  "scannedDocument": {
    "scanId": "my-scan-123",
    "totalWords": 221,
    "actualCredits": 1,
    "expectedCredits": 1,
    "creationTime": "2023-01-10T10:07:58.9459512Z"
  }
}
curl --request POST \
  --url https://api.copyleaks.com/v2/writer-detector/my-scan-123/check \
  --header 'Authorization: Bearer YOUR_LOGIN_TOKEN' \
  --header 'Content-Type: application/json' \
  --data '{
    "text": "Copyleaks is a comprehensive plagiarism detection platform...",
    "sandbox": false,
    "explain": true,
    "sensitivity": 2
  }'
{
  "modelVersion": "v5",
  "results": [
    {
      "classification": 2,
      "probability": 1,
      "matches": [
        {
          "text": {
            "chars": { "starts": [0], "lengths": [1509] },
            "words": { "starts": [0], "lengths": [221] }
          }
        }
      ]
    }
  ],
  "summary": { "human": 0, "ai": 1 },
  "scannedDocument": {
    "scanId": "my-scan-123",
    "totalWords": 221,
    "actualCredits": 1,
    "expectedCredits": 1,
    "creationTime": "2023-01-10T10:07:58.9459512Z"
  }
}
Use Copyleaks AI Content Detection to differentiate between human-written and AI-written text. This endpoint will receive submitted text to be checked. At the end of the processing stage, the result will be shown as classifications. Text classification is divided into sections. Each section may have a different classification.
Authentication Required. You need to login with a user and API key in order to access this method. Add this HTTP header to your request:Authorization: Bearer <Your-Login-Token>

Request

Path Parameters

scanId
string
required
A unique scan id provided by you. We recommend you use the same id in your database to represent the scan in the Copyleaks database. Learn more about the criteria for creating a Scan ID.>= 3 characters <= 36 characters

Headers

Content-Type: application/json
Authorization: Bearer YOUR_LOGIN_TOKEN

Request Body

text
string
required
A text string. >= 255 characters <= 100000 characters
sandbox
boolean
default:"false"
Use sandbox mode to test your integration with the Copyleaks API for free.
language
string
The language code of your content in ISO-639-1 format. See the full list of supported languages. If the language field is not supplied, our system will automatically detect the language of the content. Example: "en"
explain
boolean
default:"false"
Enable AI Logic feature for AI detection. For further information, please check the AI Logic for a detailed breakdown of its structure and usage, and for full AI Detection response please check the AI Detection Response.
sensitivity
integer
default:"2"
Control the behavior of the AI detection.
  • Detecting content copied directly from an LLM, like ChatGPT or Gemini, without edits.
  • Detecting content from an LLM with minor changes, like tense adjustments or added words.
  • Detecting content from an LLM that has been heavily modified using tools or manual edits.
>= 1 <= 3

Responses

200 OK - The command was executed.
{
  "modelVersion": "v5",
  "results": [
    {
      "classification": 2,
      "probability": 1,
      "matches": [
        {
          "text": {
            "chars": { "starts": [0], "lengths": [1509] },
            "words": { "starts": [0], "lengths": [221] }
          }
        }
      ]
    }
  ],
  "summary": { "human": 0, "ai": 1 }
}

Next Steps

Detect AI-Generated Text

Learn how to use the AI Detection API to check if content was written by a human or generated by an AI.

AI Logic

Understand how AI logic can help you interpret the results of AI text detection.

AI Detection Webhook

Learn about the webhook that delivers AI detection results.