# Recognition Quickstart

# Sending CAPTCHA images or audio and getting back click positions or text.

  • Pros

    Fast and cheap.

    Works on all sites.

  • Cons

    Some coding required.

    Proxies may be needed.

    Browser required (e.g. Selenium, Puppeteer, Playwright).


# Official NopeCHA libraries

Python Client
https://nopecha.com/pypi

Node.js Client
https://nopecha.com/npm


# Example code using client libraries

# Install the client using the following command:
# pip install --upgrade nopecha

import nopecha
nopecha.api_key = 'YOUR_API_KEY'

# Call the Recognition API
clicks = nopecha.Recognition.solve(
    type='recaptcha',
    task='Select all squares with vehicles.',
    image_urls=['https://nopecha.com/image/demo/recaptcha/4x4.png'],
    grid='4x4'
)

# Print the grids to click
print(clicks)
// Install the client using the following command:
// npm i nopecha

const { Configuration, NopeCHAApi } = require('nopecha');

const configuration = new Configuration({
    apiKey: 'YOUR_API_KEY',
});
const nopecha = new NopeCHAApi(configuration);

(async () => {
    // Call the Recognition API
    const clicks = await nopecha.solveRecognition({
        type: 'recaptcha',
        task: 'Select all squares with vehicles.',
        image_urls: ['https://nopecha.com/image/demo/recaptcha/4x4.png'],
        grid: '4x4',
    });

    // Print the grids to click
    console.log(clicks);
})();

# Example code with minimal dependencies

Request
Response
API = 'https://api.nopecha.com/'

job_id = requests.post(API, json={
    'type': 'funcaptcha',
    'image_data': image_data,
    'task': 'Pick the alien',
    'key': key,
}).json()['data']

requests.get(f"{API}?key={KEY}&id={job_id}").json()
{
    "data": [
        False, False, True,  # Click on the 3rd image
        False, False, False
    ]
}
Request
Response
const API = 'https://api.nopecha.com/';

const req = await fetch(API, {
    method: 'POST',
    headers: {'Content-Type': 'application/json'},
    body: JSON.stringify({
        type: 'funcaptcha',
        image_data: image_data,
        task: 'Pick the alien',
        key: KEY,
    }),
}).then(r => r.json());

await fetch(`${API}?key=${KEY}&id=${req.data}`)
    .then(r => r.json());
{
    data: [
        false, false, true,  // Click on the 3rd image
        false, false, false
    ]
}