# Text CAPTCHA

Examples of Text CAPTCHA
Examples of Text CAPTCHA


# Submit the challenge to NopeCHA

POST https://api.nopecha.com/
Parameter Type Required Value
key String Required NopeCHA subscription key.
type String Required textcaptcha
image_data Array of String Conditional Required if image_urls is missing. Base64-encoded images. Array size must be 1.
image_urls Array of String Conditional Required if image_data is missing. Valid image URLs. Array size must be 1.
{
    'key': 'MY_NOPECHA_KEY',
    'type': 'textcaptcha',
    'image_urls': ['https://nopecha.com/image/demo/textcaptcha/0iuj.png']
}
Retrieve solution with the data value
{
    'data': 'dCB4PSI5NC4zODU3I'
}

# Get the solution from NopeCHA

GET https://api.nopecha.com/
Parameter Type Required Value
key String Required NopeCHA subscription key.
id String Required The value of data from POST response.
{
    'key': 'MY_NOPECHA_KEY',
    'id': 'dCB4PSI5NC4zODU3I'
}
AI has solved the challenge
AI has not yet solved the challenge
{
    'data': ['0iuj']
}
{
    'error': 14,
    'message': 'Incomplete job'
}

# 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
text = nopecha.Recognition.solve(
    type='textcaptcha',
    image_urls=['https://nopecha.com/image/demo/textcaptcha/00Ge55.png'],
)

# Print the text to type
print(text)
// 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 text = await nopecha.solveRecognition({
        type: 'textcaptcha',
        image_urls: ['https://nopecha.com/image/demo/textcaptcha/00Ge55.png'],
    });

    // Print the text to type
    console.log(text);
})();