Draw Around Method

Draw Around image

The method can be used to bypass tasks where you need to draw a line around a specific object shown on an image.

Supported image formats: JPEG, PNG, GIF
Max file size: 600 kB
Max image size: 1000px on any side

DrawAroundTask task type specification

Property Type Required Description
type String Yes DrawAroundTask
body String Yes Image encoded into Base64 format. Data-URI format (containing data:content/type prefix) is also supported
comment String Yes* A comment will be shown to workers to help them to solve the captcha properly.
The comment property is required if the imgInstructions property is missing.
imgInstructions String Yes* An optional image with instruction that will be shown to workers. Image should be encoded into Base64 format. Max file size: 100 kB.
The imgInstructions property is required if the comment property is missing.

Request example

Method: createTask
API endpoint: https://api.2captcha.com/createTask

{
    "clientKey": "YOUR_API_KEY",
    "task": {
        "type":"DrawAroundTask",
        "body":"/9j/4AAQSkZJ...OGSRF//Z",
        "comment":"draw around an apple"
    },
    "languagePool":"en"
}

Response example

Method: getTaskResult
API endpoint: https://api.2captcha.com/getTaskResult

{
    "errorId": 0,
    "status": "ready",
    "solution": {
        "canvas": [
            [
                {
                    "x": 141,
                    "y": 93
                },
                {
                    "x": 145,
                    "y": 93
                }
            ],
            [
                {
                    "x": 350,
                    "y": 263
                },
                {
                    "x": 350,
                    "y": 263
                }
            ],
            [
                {
                    "x": 350,
                    "y": 263
                }
            ]
        ]
    },
    "cost": "0.0012",
    "ip": "1.2.3.4",
    "createTime": 1692863536,
    "endTime": 1692863556,
    "solveCount": 0
}