SurSolver

MTCaptcha solver API

Generate an MTCaptcha verified token for widgets that pass background verification. Visible text challenges are not currently supported by this token task.

Updated

$0.70 / 1K tasksCharged when a task is accepted

On this page

MTCaptcha task at a glance

MtCaptchaTokenProxyLess and MtCaptchaToken return the verifiedToken that an MTCaptcha widget issues when its verification passes.

Field Required Notes
type yes MtCaptchaTokenProxyLess, or MtCaptchaToken with your proxy
websiteURL yes The exact page that renders the widget
websiteKey yes The public site key, MTPublic-<id>
userAgent yes Your browser's User-Agent; keep it when you submit the result
proxy MtCaptchaToken only Your proxy for the solving session
testKey no MTPrivQA-<id>-<secret>, QA mode on a site you control

pageAction and isInvisible are not accepted, so they cannot switch on a widget mode the page does not have. The MTCaptcha API reference shows the accepted request.

Find the MTCaptcha site key

Pages load mtcaptcha.min.js from service.mtcaptcha.com and usually define window.mtcaptchaConfig. Read sitekey from that object, or find sk in the widget's getchallenge.json request. The value starts with MTPublic-.

MTCaptcha widget and its network requests

What the task can and cannot pass

The token task covers background verification and the vendor's test mode. When the widget shows a visible text CAPTCHA, the task fails instead of returning a token that would not verify. Image to Text reads text from an image you send, but it does not complete this widget's verification.

Submit the verified token

Put solution.token in the hidden input named mtcaptcha-verifiedtoken, or hand it to the verified callback the page defines, then post the form. The site's server does the final verification, so submit promptly and never reuse a token.

A failed or timed-out task returns its original charge once. Check the task's final state before posting the form.

Where the key lives in getchallenge.json, why the outcome depends on the exit IP, and a replay script are covered in the MTCaptcha token guide.

Choose the token or image flow

What the widget needs Use Result
Background verification or QA mode on your own site MtCaptchaTokenProxyLess or MtCaptchaToken A verified token for the widget
Characters read from a visible CAPTCHA image ImageToTextTask, with the matching numeric module Text only; you still submit it through the widget's original session

The image task does not produce an MTCaptcha verified token. A visible text challenge is unsupported by the token task and must not be reported as a successful background pass.

Request and ready result

Send the following to POST /createTask. Use the real MTPublic- key and a supported User-Agent:

snippet.json
{
  "clientKey": "sur_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
  "task": {
    "type": "MtCaptchaTokenProxyLess",
    "websiteURL": "https://example.com/signup",
    "websiteKey": "MTPublic-YOURKEY",
    "userAgent": "YOUR_SUPPORTED_USER_AGENT"
  }
}

Omit testKey for normal sites. Use an MTPrivQA-... key only for a QA integration you control. Poll POST /getTaskResult with clientKey and the returned taskId; its ready shape is:

snippet.json
{
  "errorId": 0,
  "status": "ready",
  "solution": {
    "token": "<verified-widget-token>"
  }
}

Examples in your language

The official client wraps createTask and polling in one solve call; each language tab is its Quick start with this captcha's request, and prints the verified token. Post it in the mtcaptcha-verifiedtoken field together with the form's other fields, and check the application response:

quickstart.ts
npm install sursolver
import { SurSolver, TaskType } from 'sursolver';

const API_KEY = 'YOUR_API_KEY';
const USER_AGENT =
  'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/155.0.0.0 Safari/537.36';

const client = new SurSolver(API_KEY);

const { solution } = await client.solve({
  type: TaskType.MtCaptchaTokenProxyLess,
  websiteURL: 'https://example.com/login',
  websiteKey: 'MTPublic-YOURKEY',
  userAgent: USER_AGENT,
});
console.log(solution.token);

If the page has a verified callback instead of a plain form field, pass this same token to the callback registered by that page. Preserve its normal submit path and current CSRF/session values rather than inventing a global callback name.

Troubleshooting

Symptom Check Correction
Task fails when a text image is shown This is outside the token integration Use the original widget flow; OCR is a separate image task
Request rejects the key A private QA key was used as websiteKey Send MTPublic-...; keep optional QA configuration separate
Request rejects pageAction or isInvisible Those fields do not configure this solver Remove them
Ready token fails on submission Wrong page key, expired token, session or User-Agent mismatch Solve and submit promptly in the intended application context

FAQ

Does this task solve visible MTCaptcha text images?

No. The token integration handles background verification and the vendor test mode. A visible text challenge ends the task as failed. Reading a text image with Image to Text is a separate API task.

What input does MTCaptcha need?

Send websiteURL, websiteKey in MTPublic-<id> form and the browser userAgent. pageAction and isInvisible are not accepted.

Does MTCaptcha require a proxy?

MtCaptchaTokenProxyLess uses SurSolver infrastructure. MtCaptchaToken requires your own proxy. Use the same userAgent and session context when submitting the result.

Where does the verified token go?

Put solution.token into the form field mtcaptcha-verifiedtoken, or pass it through the callback the target page uses, before submitting the form.

What is testKey for?

It enables MTCaptcha QA mode on a site you control. It is optional and must have the MTPrivQA-<id>-<secret> form. A normal solve should omit it.