Welcome to basicpy2captcha python module👋
A basic python 2captcha.com module
Install
pip install basicpy2captcha
Usage
import base64
import basicpy2captcha
py2c = captcha.py2c("YOUR_2CAPTCHA_API_KEY")
#Text Image:
with open("captcha.png", "rb") as f:
img_b64 = base64.b64encode(f.read())
solved = py2c.solveCaptcha(img_b64)
print(solved)
#ReCaptcha:
key = py2c.get_sitekey(driver) #driver - selenium webbrowser object
token = solveReCaptcha(key,driver.current_url)
if token:
driver.execute_script(
"document.getElementById('g-recaptcha-response').innerHTML='{}';".format(token)
)
#getBalance:
balance = py2c.getBalance()
print(balance)
#report Correct resolve:
py2c.reportCorrect()
#report Incorrect resolve:
py2c.reportIncorrect()
Show your support
Give a ⭐️ if this project helped you!
Release files for basicpy2captcha 1.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| basicpy2captcha-1.0.2.tar.gz | 1.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| basicpy2captcha-1.0.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 4.3 kB
Release files / basicpy2captcha-1.0.2.tar.gz
| Download URL | basicpy2captcha-1.0.2.tar.gz |
|---|---|
| Size | 1.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fe65bd3237b62a998605ec7d67ced16a3d4af053da5cf808a97cbf99aabdab20
|
|
BLAKE2b-256 checksum How to use checksums |
9a40d2619c81b30ab6cc0412caccaf80ec977bcb7e93d7e07af73fa5845fd739
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.1
|
Release files / basicpy2captcha-1.0.2-py3-none-any.whl
| Download URL | basicpy2captcha-1.0.2-py3-none-any.whl |
|---|---|
| Size | 2.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
95ed2578ff6f21d38e070cd8f8293e9b7d6070731c2ae43b990f818676e3f4ce
|
|
BLAKE2b-256 checksum How to use checksums |
c96e6a7cf29754a3575598e4f72f4cc8af20fcf941b95444ab5974041f95f7ad
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.1
|