UNPKG

acp-node

Version:

Official [anticaptcha.pro](https://anticaptcha.pro) captcha solver SDK for nodejs

35 lines (32 loc) 893 B
import { IMAGE_VERSIONS, CAPTCHA_STATUS, RECAPTCHA_VERSIONS } from './enum.cjs'; type CaptchaStatus = (typeof CAPTCHA_STATUS)[keyof typeof CAPTCHA_STATUS]; type APIResponse<T> = { success: boolean; data: T; }; type GetBalanceResponse = { balance: number; }; type CreateTaskResponse = { status: CaptchaStatus; taskId: string; }; type TakeResultResponse = { status: CaptchaStatus; msg?: string; solution: string | null; }; type ImagePayload = { version?: (typeof IMAGE_VERSIONS)[number]; body: string; }; type OtherPayload = { sitekey: string; pageurl: string; }; type RecaptchaPayload = OtherPayload & { version?: (typeof RECAPTCHA_VERSIONS)[number]; enterprise?: boolean; invisible?: boolean; }; export type { APIResponse, CreateTaskResponse, GetBalanceResponse, ImagePayload, OtherPayload, RecaptchaPayload, TakeResultResponse };