Skip to content
EN

约定 ​

所有求解接口共用同一套 JSON 外壳。厂商差异只出现在 POST /v1/solve/:type 的请求参数和成功时的 data。

Base URL ​

text
https://api.hitcaptcha.com

下文路径均相对该根地址。本地自建可用 {BASE} 自行替换。

接口一览 ​

方法路径鉴权说明
GET/health否探活
GET/v1/solvers是可用厂商列表
POST/v1/solve/:type是求解

type 目前为 akamai / kasada / datadome / reese84(小写)。未知或不支持的 type 返回 NOT_FOUND。

鉴权方式见 鉴权。

Content-Type ​

请求体必须是 JSON 对象,大小上限 2MB:

http
Content-Type: application/json

数组、空 body、非对象会 INVALID_INPUT。

成功 ​

json
{
  "ok": true,
  "type": "kasada",
  "data": {},
  "cost_ms": 123,
  "charged_points": 2,
  "balance_points": 998
}
字段类型说明
okboolean恒为 true
typestring路径里的厂商
dataobject厂商结果,见各厂商页
cost_msnumber服务端耗时(毫秒)
charged_pointsnumber本次扣点(若有计费)
balance_pointsnumber扣费后余额(若有计费)

失败 ​

HTTP 状态码随错误变化;body 形状固定:

json
{
  "ok": false,
  "type": "kasada",
  "error": { "code": "TIMEOUT", "message": "kasada timeout after 90000ms" },
  "cost_ms": 90001
}
字段类型说明
okboolean恒为 false
typestring | null能解析到 type 时带回,否则 null
error.codestring见 错误码
error.messagestring可读原因
cost_msnumber | null已开始计时则有值

未预期异常不会把内部 stack 返回给调用方,统一成 INTERNAL。