Skip to content

A playwright and patchright with asyncio and Quart reCaptcha solver.

License

Notifications You must be signed in to change notification settings

captchasio/recaptcha-solver-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Google ReCaptcha Solver

A playwright and patchright with asyncio and Quart reCaptcha solver.

📜 ChangeLog · ⚠️ Report Bug · 💡 Request Feature


🎁 Donation

  • USDT (TRC20): TUAvVcsrxeA6mBnP36kg3QkXiKNggTsD6n
  • BTC: bc1qvr0nxg4f9a73grnajh86thlwnrnpt9puq8e0rf
  • LTC: ltc1qrqjzxujf0rmhcmxc2xzeuc0qk3qve4fgx54tr4

❓ Looking for a Cheap or Custom CAPTCHA Solution?


❗ Disclaimers

  • I am not responsible for anything that may happen, such as API Blocking, IP ban, etc.
  • This was a quick project that was made for fun and personal use if you want to see further updates, star the repo & create an "issue" here

⚙️ Installation Instructions

  1. Ensure Python 3.8+ is installed on your system.

  2. Create a Python virtual environment:

    python -m venv venv
  3. Activate the virtual environment:

    • On Windows:
      venv\Scripts\activate
    • On macOS/Linux:
      source venv/bin/activate
  4. Install required dependencies:

    pip install -r requirements.txt
  5. Select the browser to install: You can choose between Chromium, Chrome, Edge or Camoufox:

    • To install Chromium:
      python -m patchright install chromium
    • To install Chrome:
      • On macOS/Windows: Click here
      • On Linux (Debian/Ubuntu-based):
        apt update
        wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
        apt install -y ./google-chrome-stable_current_amd64.deb
        apt -f install -y  # Fix dependencies if needed
        rm ./google-chrome-stable_current_amd64.deb
    • To install Edge:
      python -m patchright install msedge
    • To install Camoufox:
      python -m camoufox fetch
  6. Start testing:


🔧 Command line arguments

Parameter Default Type Description
--headless False boolean Runs the browser in headless mode. Requires the --useragent argument to be set.
--useragent None string Specifies a custom User-Agent string for the browser. (No need to set if camoufox used)
--debug False boolean Enables or disables debug mode for additional logging and troubleshooting.
--browser_type chromium string Specify the browser type for the solver. Supported options: chromium, chrome, msedge, camoufox
--thread 1 integer Sets the number of browser threads to use in multi-threaded mode.
--host 127.0.0.1 string Specifies the IP address the API solver runs on.
--port 5000 integer Sets the port the API solver listens on.
--proxy False boolean Select a random proxy from proxies.txt for solving captchas

🐳 Docker Image

Running the Container

To start the container, use:

  • Change the TZ environment variable and ports to the correct one for yourself:
docker run -d -p 3389:3389 -p 5000:5000 -e TZ=Asia/Baku --name repcaptcha_solver captchasio/repcaptcha_solver:latest

Connecting to the Container

  1. Use an RDP client (like Windows Remote Desktop, Remmina, or FreeRDP)
  2. Connect to localhost:3389
  3. Login with the default user:
    • Username: root
    • Password: root
  4. After this, you can start the solver by navigating to the recaptcha-solver-server folder.

📡 API Documentation

Solve reCAPTCHA

  GET /recaptcha?url=https://example.com&sitekey=0x4AAAAAAA

Request Parameters:

Parameter Type Description Required
url string The target URL containing the CAPTCHA. (e.g., https://example.com) Yes
sitekey string The site key for the CAPTCHA to be solved. (e.g., 0x4AAAAAAA) Yes
action string Action to trigger during CAPTCHA solving, e.g., verify No
min_score string The captcha score. Example value: "3.0" No
invisible string This parameter determins if the CAPTCHA is invisible or not. No
enterprise string To flag if the CAPTCHA is reCaptca Enterprise or not. No
data_s string Custom data that can be used for additional CAPTCHA parameters. No

Response:

If the request is successfully received, the server will respond with a task_id for the CAPTCHA solving task:

{
  "task_id": "d2cbb257-9c37-4f9c-9bc7-1eaee72d96a8"
}

Get Result

  GET /result?id=f0dbe75b-fa76-41ad-89aa-4d3a392040af

Request Parameters:

Parameter Type Description Required
id string The unique task ID returned from the /recaptcha request. Yes

Response:

If the CAPTCHA is solved successfully, the server will respond with the following information:

{
  "elapsed_time": 7.625,
  "value": "0.KBtT-r"
}

Inspired by Theyka

About

A playwright and patchright with asyncio and Quart reCaptcha solver.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published

Languages