Tài liệu API
Yêu cầu dạng JSON, chỉ một địa chỉ (https://gatesolver.com). Gửi API key tạo trong trang tài khoản dưới dạng clientKey. Tạo task (createTask), vài giây sau nhận kết quả (getTaskResult).
- Địa chỉ gốc
- https://gatesolver.com
- Xác thực
- clientKey trong body
- Giới hạn yêu cầu
- 600 lần trong 1 phút cho một key
- Định dạng
- JSON (POST)
Bắt đầu
- Đăng ký và nạp số dư.
- Tạo key trong mục API key của trang tài khoản. Key chỉ hiển thị một lần khi tạo.
- Tạo task bằng createTask rồi dùng taskId nhận được để gọi getTaskResult mỗi vài giây.
- Khi status chuyển thành ready, điền solution vào trang.
Client xây dựng cho định dạng createTask hoạt động ngay khi bạn đổi địa chỉ API. Địa chỉ mới: https://gatesolver.com
createTask
POST https://gatesolver.com/createTask
Tạo task và trả về taskId. Lúc này chưa bị trừ tiền.
| Trường | Định dạng | Bắt buộc | Mô tả |
|---|---|---|---|
| clientKey | string | Có | API key |
| task | object | Có | Nội dung task. type và các trường theo loại (xem bảng task type bên dưới và trang từng loại) |
| callbackUrl | string | Không | Không nhận. Hãy lấy kết quả bằng getTaskResult. |
Yêu cầu
{
"clientKey": "YOUR_API_KEY",
"task": {
"type": "ReCaptchaV2TaskProxyLess",
"websiteURL": "https://www.google.com/recaptcha/api2/demo",
"websiteKey": "6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-"
}
}Phản hồi
{ "errorId": 0, "taskId": "61138bb6-19fb-11ec-a9c8-0242ac110006" }getTaskResult
POST https://gatesolver.com/getTaskResult
Trả về kết quả task. Nên hỏi mỗi 3 giây với loại token, mỗi 1 giây với nhận dạng ảnh. Phí 1 lượt bị trừ khỏi số dư ngay khi có kết quả.
| Trường | Mô tả |
|---|---|
| status | processing (đang chờ), ready (đã có kết quả), failed (thất bại, không trừ tiền) |
| solution | Kết quả. Trường khác nhau tùy loại (gRecaptchaResponse, token, cookie, text...) |
| cost | Số tiền bị trừ cho task này (đô la) |
| createTime / endTime | Thời điểm tạo và hoàn tất (mili giây) |
{
"errorId": 0,
"taskId": "61138bb6-19fb-11ec-a9c8-0242ac110006",
"status": "ready",
"solution": { "gRecaptchaResponse": "03AFcWeA6...", "userAgent": "Mozilla/5.0 ..." },
"cost": "0.000560"
}getBalance
POST https://gatesolver.com/getBalance
Trả về số dư bằng đô la.
{ "clientKey": "YOUR_API_KEY" }
{ "errorId": 0, "balance": 42.5 }Task type
Tên type không phân biệt chữ hoa, chữ thường. Các trường và ví dụ của từng loại có trên trang riêng của loại đó.
| type | Loại | 1,000 lượt |
|---|---|---|
| ReCaptchaV2TaskProxyLess | reCAPTCHA v2 | $0.56 |
| ReCaptchaV2Task | reCAPTCHA v2 | $0.56 |
| ReCaptchaV2EnterpriseTaskProxyLess | reCAPTCHA v2 Enterprise | $0.70 |
| ReCaptchaV2EnterpriseTask | reCAPTCHA v2 Enterprise | $0.70 |
| ReCaptchaV3TaskProxyLess | reCAPTCHA v3 | $0.70 |
| ReCaptchaV3Task | reCAPTCHA v3 | $0.70 |
| ReCaptchaV3EnterpriseTaskProxyLess | reCAPTCHA v3 Enterprise | $2.10 |
| ReCaptchaV3EnterpriseTask | reCAPTCHA v3 Enterprise | $2.10 |
| AntiTurnstileTaskProxyLess | Cloudflare Turnstile | $0.84 |
| TurnstileTaskProxyless | Cloudflare Turnstile | $0.84 |
| AntiCloudflareTask | Cloudflare Challenge | $0.84 |
| AntiAwsWafTaskProxyLess | AWS WAF | $1.40 |
| AntiAwsWafTask | AWS WAF | $1.40 |
| GeeTestTaskProxyLess | GeeTest v3 / v4 | $0.84 |
| GeeTestTask | GeeTest v3 / v4 | $0.84 |
| MtCaptchaTaskProxyLess | MTCaptcha | $2.10 |
| MtCaptchaTask | MTCaptcha | $2.10 |
| DatadomeSliderTask | DataDome Slider | $1.75 |
| ImageToTextTask | Image to Text | $0.28 |
| ReCaptchaV2Classification | reCAPTCHA Image Classification | $0.28 |
| AwsWafClassification | AWS WAF Image Classification | $0.42 |
| VisionEngine | Vision Engine | $1.05 |
Mã lỗi
Khi có lỗi, errorId là 1 và kèm errorCode, errorDescription. Phản hồi lỗi không bị trừ tiền.
| errorCode | Ý nghĩa |
|---|---|
| ERROR_KEY_DENIED_ACCESS | Thiếu hoặc sai clientKey. |
| ERROR_ZERO_BALANCE | Số dư không đủ. Hãy nạp tiền rồi gửi lại yêu cầu. |
| ERROR_TASK_NOT_SUPPORTED | Task type không được hỗ trợ. |
| ERROR_INVALID_TASK_DATA | Thiếu trường bắt buộc. Tên trường bị thiếu có trong errorDescription. |
| ERROR_TASKID_INVALID | taskId không được tạo bằng key này hoặc không tồn tại. |
| ERROR_CAPTCHA_UNSOLVABLE | Không giải được. Bạn chưa bị trừ tiền. Hãy gửi lại yêu cầu. |
| ERROR_SERVICE_UNAVAILABLE | Lỗi mạng. Bạn chưa bị trừ tiền. Hãy gửi lại sau ít phút. |
| ERROR_RATE_LIMIT | Đã vượt quá 600 yêu cầu trong 1 phút. Hãy giãn khoảng cách giữa các yêu cầu. |
| ERROR_ACCOUNT_SUSPENDED | Tài khoản đã bị khóa. |
Tương thích in.php
Với chương trình kiểu in.php, chỉ cần đổi địa chỉ. Các method hỗ trợ: userrecaptcha (reCAPTCHA v2), turnstile, geetest, base64 và post (chữ trong ảnh).
GET https://gatesolver.com/in.php?key=YOUR_API_KEY&method=userrecaptcha&googlekey=6Le...&pageurl=https://example.com
OK|61138bb6-19fb-11ec-a9c8-0242ac110006
GET https://gatesolver.com/res.php?key=YOUR_API_KEY&action=get&id=61138bb6-19fb-11ec-a9c8-0242ac110006
CAPCHA_NOT_READY
OK|03AFcWeA6...
GET https://gatesolver.com/res.php?key=YOUR_API_KEY&action=getbalance
42.50000Thêm json=1 sẽ nhận phản hồi dạng {"status":1,"request":"..."}.
Ví dụ
import requests, time
API, KEY = "https://gatesolver.com", "YOUR_API_KEY"
def solve(task, wait=3, timeout=120):
r = requests.post(f"{API}/createTask", json={"clientKey": KEY, "task": task}, timeout=30).json()
if r.get("errorId"):
raise RuntimeError(r["errorCode"])
end = time.time() + timeout
while time.time() < end:
time.sleep(wait)
res = requests.post(f"{API}/getTaskResult", json={"clientKey": KEY, "taskId": r["taskId"]}, timeout=30).json()
if res.get("errorId"):
raise RuntimeError(res["errorCode"])
if res["status"] == "ready":
return res["solution"]
raise TimeoutError("task timed out")
print(solve({"type": "ReCaptchaV2TaskProxyLess", "websiteURL": "https://example.com", "websiteKey": "6Le..."}))const API = "https://gatesolver.com", KEY = "YOUR_API_KEY";
const post = (p, b) => fetch(API + p, { method: "POST", headers: { "content-type": "application/json" }, body: JSON.stringify(b) }).then((r) => r.json());
export async function solve(task, wait = 3000) {
const r = await post("/createTask", { clientKey: KEY, task });
if (r.errorId) throw new Error(r.errorCode);
for (;;) {
await new Promise((s) => setTimeout(s, wait));
const res = await post("/getTaskResult", { clientKey: KEY, taskId: r.taskId });
if (res.errorId) throw new Error(res.errorCode);
if (res.status === "ready") return res.solution;
}
}body, _ := json.Marshal(map[string]any{"clientKey": "YOUR_API_KEY", "task": map[string]any{
"type": "AntiTurnstileTaskProxyLess", "websiteURL": "https://example.com", "websiteKey": "0x4AAAAAAA..."}})
res, err := http.Post("https://gatesolver.com/createTask", "application/json", bytes.NewReader(body))$ch = curl_init("https://gatesolver.com/createTask");
curl_setopt_array($ch, [CURLOPT_POST => true, CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ["Content-Type: application/json"],
CURLOPT_POSTFIELDS => json_encode(["clientKey" => "YOUR_API_KEY", "task" => [
"type" => "ReCaptchaV3TaskProxyLess", "websiteURL" => "https://example.com", "websiteKey" => "6Lc...", "pageAction" => "login"]])]);
$task = json_decode(curl_exec($ch), true);curl -X POST https://gatesolver.com/createTask -H "Content-Type: application/json" \
-d '{"clientKey":"YOUR_API_KEY","task":{"type":"ImageToTextTask","body":"iVBORw0KGgo..."}}'