To create a TextCaptcha task, send a POST request to http://api.botlab.me/create with the API key specified in the X-API-Key header. Pass the data in JSON format in the request body.
Request
Request Body (JSON):
{
"type": "TextCaptcha",
"task": "TASK_BASE_64"
}
Response
After successfully creating the task, you will receive a unique task identifier
{
"status": 1,
"response": "9051d4b4-0000-44d3-a4c2-db0215227862"
}
• status - request execution status (1 - success, 0 - error). • response - task identifier / error code
To get the results of TextCaptcha task processing, send a POST request to http://api.botlab.me/result with the API key specified in the X-API-Key header. In the request body, pass the task identifier from the previous request.
Request
Request Body (JSON): • id - identifier of the created task
{
"id": "9051d4b4-0000-44d3-a4c2-db0215227862"
}
Response
Receive the TextCaptcha task processing results as the recognized text.
{
"status": 1,
"response": "12"
}
• status - request execution status (1 - success, 0 - error). • response - the recognized text / error code.
If you receive the value CAPCHA_NOT_READY in the response, it means the results are not ready yet. In this case, it is recommended to wait up to 5 seconds and repeat the request to get the results. Repeat the request until you receive a successful result (status equals 1) or another status indicating an error.
After registering your application, you will receive your softId. To create a task, send a POST request to http://api.botlab.me/create
{
"type": "TextCaptcha",
"task": "TASK_BASE_64",
"app_id": "application identifier"
}