Prosopo Procaptcha

CapMonster Cloud 默认通过内置代理工作——这些代理已包含在费用内。仅当网站不接受令牌或对内置服务的访问受限时,才需要指定您自己的代理。 如果代理按 IP 授权,请将地址 65.21.190.34 加入白名单。
基于令牌的自动解决验证码方法 Prosopo Procaptcha。
请求参数
type<string>requiredProsopoTask
websiteURL<string>required验证码页面的完整 URL。
websiteKey<string>required在页面中找到的 siteKey 参数值。
大致格式如下:5EZU3LG31uzq1Mwi8inwqxmfvFDpj7VzwDnZwj4Q3syyxBwV
userAgent<string>optional浏览器 User-Agent。请使用 CapMonster Cloud 当前支持的值:userAgentPlaceholder
可通过以下地址获取最新值:https://capmonster.cloud/api/useragent/actual。
proxyType<string>optionalhttp - 普通的 http/https 代理;
https - 仅在 "http" 不起作用时尝试(某些自定义代理服务器要求);
socks4 - socks4 代理;
socks5 - socks5 代理。
proxyAddress<string>optional代理 IP 地址 IPv4/IPv6。不允许:
- 使用透明代理(其中客户端 IP 可见);
- 使用来自本地网络的代理。
proxyPort<integer>optional代理端口。
proxyLogin<string>optional代理登录。
proxyPassword<string>optional代理密码。
创建任务方法
- ProsopoTask(无代理)
- ProsopoTask(使用代理时)
https://api.capmonster.cloud/createTask
请求示例
{
"clientKey": "API_KEY",
"task": {
"type": "ProsopoTask",
"websiteURL": "https://www.example.com",
"websiteKey": "your-website-key"
}
}
响应示例
{
"errorId":0,
"taskId":407533077
}
https://api.capmonster.cloud/createTask
请求示例
{
"clientKey": "API_KEY",
"task": {
"type": "ProsopoTask",
"websiteURL": "https://www.example.com",
"websiteKey": "your-website-key",
"proxyType": "your-proxy-type",
"proxyAddress": "your-proxy-address",
"proxyPort": 1234,
"proxyLogin": "your-proxy-login",
"proxyPassword": "your-proxy-password"
}
}
响应示例
{
"errorId":0,
"taskId":407533077
}
获取任务结果方法
使用方法 getTaskResult 来获取 Prosopo 的解决方案。
https://api.capmonster.cloud/getTaskResult
请求示例
{
"clientKey":"API_KEY",
"taskId": 407533077
}
响应示例
{
"errorId":0,
"status":"ready",
"solution":
{
"token": "0x00016c68747470733a2f2f70726f6e6f6465332e70726f736f706f2e696fc0354550516f4d5a454463354c704e376774784d4d7a5950547a4136..."
}
}
如何获取 websiteKey
-
打开触发 Prosopo 验证码的网站。
-
转到开发者工具(DevTools)→ Network,重新加载页面,并找到加载
image的请求(例如 API 请求https://example.prosopo.io/v1/prosopo/provider/client/captcha/image)。 -
在 Request Headers 中找到
Prosopo-Site-Key参数,复制其值并在创建请求时使用。

使用 SDK 库
- JavaScript / TypeScript
- Python
- C#
显示代码(浏览器)
// https://github.com/CapMonsterCloud/capmonster-nodejs-captcha-solver
import {
CapMonsterCloudClientFactory,
ClientOptions,
ProsopoRequest
} from "@zennolab_com/capmonstercloud-client";
document.addEventListener("DOMContentLoaded", async () => {
const API_KEY = "YOUR_API_KEY"; // 请指定您的 CapMonster Cloud API 密钥
const client = CapMonsterCloudClientFactory.Create(
new ClientOptions({ clientKey: API_KEY })
);
// 不使用代理的基础示例
// CapMonster Cloud 会自动使用自己的代理
let prosopoRequest = new ProsopoRequest({
websiteURL: "https://yourwebsite.com/page-with-procaptcha",
websiteKey: "your-website-key",
});
// 使用您自己的代理的示例
// 如果您想使用自己的代理,请取消注释此代码块
/*
const proxy = {
proxyType: "http",
proxyAddress: "123.45.67.89",
proxyPort: 8080,
proxyLogin: "username",
proxyPassword: "password",
};
prosopoRequest = new ProsopoRequest({
websiteURL: "https://yourwebsite.com/page-with-procaptcha",
websiteKey: "your-website-key",
proxy,
userAgent: "userAgentPlaceholder",
});
*/
// 如有需要,可以检查余额
const balance = await client.getBalance();
console.log("Balance:", balance);
const result = await client.Solve(prosopoRequest);
console.log("Solution:", result.solution);
});
显示代码(Node.js)
// https://github.com/CapMonsterCloud/capmonster-nodejs-captcha-solver
const {
CapMonsterCloudClientFactory,
ClientOptions,
ProsopoRequest,
} = require("@zennolab_com/capmonstercloud-client");
const API_KEY = "YOUR_API_KEY"; // 请指定您的 CapMonster Cloud API 密钥
async function solveProCaptcha() {
const client = CapMonsterCloudClientFactory.Create(
new ClientOptions({ clientKey: API_KEY }),
);
// 不使用代理的基础示例
// CapMonster Cloud 会自动使用自己的代理
let prosopoRequest = new ProsopoRequest({
websiteURL: "https://yourwebsite.com/page-with-procaptcha",
websiteKey: "your-website-key",
});
// 使用您自己的代理的示例
// 如果您想使用自己的代理,请取消注释此代码块
/*
const proxy = {
proxyType: "http",
proxyAddress: "123.45.67.89",
proxyPort: 8080,
proxyLogin: "username",
proxyPassword: "password",
};
prosopoRequest = new ProsopoRequest({
websiteURL: "https://yourwebsite.com/page-with-procaptcha",
websiteKey: "your-website-key",
proxy,
userAgent: "userAgentPlaceholder",
});
*/
// 如有需要,可以检查余额
const balance = await client.getBalance();
console.log("Balance:", balance);
const result = await client.Solve(prosopoRequest);
console.log("Solution:", result.solution);
}
solveProCaptcha().catch(console.error);
显示代码
# https://github.com/CapMonsterCloud/capmonster-python-captcha-solver
import asyncio
from capmonstercloudclient import CapMonsterClient, ClientOptions
from capmonstercloudclient.requests import ProsopoTaskRequest
# 如果您计划使用自己的代理,请导入 ProxyInfo
from capmonstercloudclient.requests.proxy_info import ProxyInfo
API_KEY = "YOUR_API_KEY" # 请指定您的 CapMonster Cloud API 密钥
async def solve_procaptcha():
client = CapMonsterClient(
options=ClientOptions(api_key=API_KEY)
)
# 不使用代理的基础示例
# CapMonster Cloud 会自动使用自己的代理
prosopo_request = ProsopoTaskRequest(
websiteUrl="https://yourwebsite.com/page-with-procaptcha",
websiteKey="your-website-key",
)
# 使用您自己的代理的示例
# 如果您想使用自己的代理,请取消注释此代码块
"""
proxy = ProxyInfo(
proxyType="http",
proxyAddress="123.45.67.89",
proxyPort=8080,
proxyLogin="username",
proxyPassword="password",
)
prosopo_request = ProsopoTaskRequest(
websiteUrl="https://yourwebsite.com/page-with-procaptcha",
websiteKey="your-website-key",
proxy=proxy,
userAgent="userAgentPlaceholder",
)
"""
# 如有需要,可以检查余额
balance = await client.get_balance()
print("Balance:", balance)
result = await client.solve_captcha(prosopo_request)
print("Solution:", result)
asyncio.run(solve_procaptcha())
显示代码
// https://github.com/CapMonsterCloud/capmonster-dotnet-captcha-solver
using System;
using System.Threading.Tasks;
using Zennolab.CapMonsterCloud;
using Zennolab.CapMonsterCloud.Requests;
class Program
{
static async Task Main(string[] args)
{
// 请指定您的 CapMonster Cloud API 密钥
var clientOptions = new ClientOptions
{
ClientKey = "YOUR_API_KEY"
};
var cmCloudClient = CapMonsterCloudClientFactory.Create(clientOptions);
// 不使用代理的基础示例
// CapMonster Cloud 会自动使用自己的代理
var prosopoRequest = new ProsopoTaskRequest
{
WebsiteUrl = "https://yourwebsite.com/page-with-procaptcha",
WebsiteKey = "your-website-key"
};
// 使用您自己的代理的示例
// 如果您想使用自己的代理,请取消注释此代码块
/*
prosopoRequest = new ProsopoTaskRequest
{
WebsiteUrl = "https://yourwebsite.com/page-with-procaptcha",
WebsiteKey = "your-website-key",
Proxy = new ProxyContainer(
"123.45.67.89",
8080,
ProxyType.Http,
"username",
"password"
)
};
*/
// 如有需要,可以检查余额
var balance = await cmCloudClient.GetBalanceAsync();
Console.WriteLine("Balance: " + balance);
var prosopoResult = await cmCloudClient.SolveAsync(prosopoRequest);
Console.WriteLine("Solution: " + prosopoResult.Solution.Value);
}
}
