EzCaptcha python sdk
Project description
English
EzCaptcha SDK for python
Install
pip install ezcaptcha
Usage
Sample:
from ezcaptcha import EzCaptcha
# Recaptcha
ez = EzCaptcha(client_key="yourapiKey")
solution = ez.solve({
"websiteURL": "https://www.google.com/recaptcha/api2/demo",
"websiteKey": "6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-",
"type": ez.AllTaskType.RecaptchaV2TaskProxyless, # or use str "RecaptchaV2TaskProxyless"
"isInvisible": False
}, print_log=True)
if solution.get("errorId") == 0:
# Get captcha token result
captcha_token = solution.get("token")
print(captcha_token)
else:
print(solution.get("errorDesc"))
# Funcaptcha
solution = ez.solve({
"websiteURL": "https://iframe.arkoselabs.com",
"websiteKey": "B7D8911C-5CC8-A9A3-35B0-554ACEE604DA",
"type": ez.AllTaskType.FuncaptchaTaskProxyless, # or use str "FuncaptchaTaskProxyless"
}, print_log=True)
Specify the language of log output and prompts, support "en" and "zh", default "en"
from ezcaptcha import EzCaptcha
ez = EzCaptcha(client_key="yourapiKey", lang="zh")
...
Enable log printing function
from ezcaptcha import EzCaptcha
ez = EzCaptcha(client_key="yourapiKey")
solution = ez.solve({
"websiteURL": "https://www.google.com/recaptcha/api2/demo",
"websiteKey": "6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-",
"type": "RecaptchaV2TaskProxyless",
"isInvisible": False,
}, print_log=True)
Specific waiting_interval(default 3s) and waiting_timeout(default 120s)
from ezcaptcha import EzCaptcha
ez = EzCaptcha(client_key="yourapiKey")
solution = ez.solve({
"websiteURL": "https://www.google.com/recaptcha/api2/demo",
"websiteKey": "6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-",
"type": "RecaptchaV2TaskProxyless",
"isInvisible": False,
}, waiting_interval=1, waiting_timeout=90, print_log=True)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ezcaptcha-1.4-py3-none-any.whl.
File metadata
- Download URL: ezcaptcha-1.4-py3-none-any.whl
- Upload date:
- Size: 5.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5800dea001900a231d48e5243a3f86368efb53eb60e44ead0e04a2576c4e10ea
|
|
| MD5 |
a673576351ff7ce6610c39971ba9109f
|
|
| BLAKE2b-256 |
7ed85dc8e5e3036d9fc64553ec4f1b3193a7060fbe59454f77fa2a666a46eec3
|