Skip to main content

capsolver python libary

Project description

Capsolver

Capsolver official python library

Supported CAPTCHA types:

  • HCaptcha
  • FunCaptcha
  • Geetest
  • ReCaptchaV2
  • ReCaptchav3
  • MtCaptcha
  • Datadom
  • Cloudflare
  • Kasada
  • Akamai BMP

Installation

You don't need this source code unless you want to modify the package. If you just want to use the package, just run:

pip3 install --upgrade capsolver

Install from source with:

python setup.py install

Usage

export CAPSOLVER_API_KEY='...'

Or set capsolver.api_key to its value:

from pathlib import Path
import os
import base64
import capsolver

# tokenTask
print("api host",capsolver.api_base)
print("api key",capsolver.api_key)
# capsolver.api_key = "..."
solution = capsolver.solve({
        "type":"ReCaptchaV2TaskProxyLess",
        "websiteKey":"6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-",
        "websiteURL":"https://www.google.com/recaptcha/api2/demo",
    })

print(solution)

# RecognitionTask
img_path = os.path.join(Path(__file__).resolve().parent,"queue-it.jpg")
with open(img_path,'rb') as f:
    solution = capsolver.solve({
        "type":"ImageToTextTask",
        "module":"queueit",
        "body":base64.b64encode(f.read()).decode("utf8")
    })
    print(solution)

# get current balance
balance = capsolver.balance()
# print the current balance
print(balance)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

capsolver-1.0.5.tar.gz (8.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

capsolver-1.0.5-py3-none-any.whl (9.4 kB view details)

Uploaded Python 3

File details

Details for the file capsolver-1.0.5.tar.gz.

File metadata

  • Download URL: capsolver-1.0.5.tar.gz
  • Upload date:
  • Size: 8.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.9

File hashes

Hashes for capsolver-1.0.5.tar.gz
Algorithm Hash digest
SHA256 a65d28b2d0ec1ca7ef4aa44b34f65cfcac61701dedbe4190583bfb06a40eb071
MD5 2e0c182769c152b17dea660a705c0d5d
BLAKE2b-256 f21fc077f78978a65fe533e480f03973aa2022602d35410988f020fb51e1a909

See more details on using hashes here.

File details

Details for the file capsolver-1.0.5-py3-none-any.whl.

File metadata

  • Download URL: capsolver-1.0.5-py3-none-any.whl
  • Upload date:
  • Size: 9.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.9

File hashes

Hashes for capsolver-1.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 8600dbf5e08ba79b928a63e5b6310c105714ed8a1d247441122687e12be112d7
MD5 96de5d6b9e4fc1f90280dce69ca8806e
BLAKE2b-256 e070326c13a1f7b8ce616db7bf88557c06996bf638890467405d71191107f891

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page