Skip to content

A puppeteer-extra plugin to solve Amazon captchas using Tessaract.JS.

License

Notifications You must be signed in to change notification settings

mihneamanolache/puppeteer-extra-amazon-captcha

Repository files navigation

ProxyShare.io - 4G Mobile Proxies

Puppeteer Extra Amazon Captcha Plugin

A simple puppeteer-extra plugin, made possible with Tessaract.js.

preview

Note: This plugin is still under development and has not been tested in production.

Installation

npm i @mihnea.dev/puppeteer-extra-amazon-captcha

Usage

import AmazonCaptchaPlugin from "@mihnea.dev/puppeteer-extra-amazon-captcha";
import puppeteer from 'puppeteer-extra';
try {
    const amazonCaptchaPlugin = AmazonCaptchaPlugin.default();
    puppeteer.use(amazonCaptchaPlugin);
    const browser = await puppeteer.launch({
        headless: false,
        ignoreHTTPSErrors: true,
    });
    const page = await browser.newPage();
    await page.goto("https://www.amazon.com/errors/validateCaptcha");
    /** Important: Delay code execution until URL no longer includes "error" */
    await page.waitForFunction(() => !window.location.href.includes("error"));
    await page.close();
    await browser.close();
} catch (e) {
    console.log("Error launching puppeteer: " + e.message)
}

License

Copyright © 2023, Mihnea Manolache. Released under the MIT License.

About

A puppeteer-extra plugin to solve Amazon captchas using Tessaract.JS.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published