Skip to main content
Skip to content
ScrapingBuddyDevelopers
On this page Overview

CAPTCHA API/API reference

Bounding Box CAPTCHA

Send one image and get object boundaries as xMin, xMax, yMin, and yMax.

Use this for challenges that ask the user to draw a box around an object or region.

01 / Prepare

Prepare the input

Send the original image and name the object or region that should be outlined. Ask for a tight boundary if you need a precise crop. Enable canNoAnswer only when the requested object may genuinely be absent.

Each task reserves $0.015 from your wallet. Successful tasks cost 1.5 times the provider cost; unused reserved credit is returned. Failed tasks are not charged. Billing details

  • Boxes are measured from the top-left corner of the uploaded image.
  • Ask for tight boxes when the downstream workflow needs precise cropping.
  • Use canNoAnswer when the object may not be present in every challenge.

For the complete examples, prepare challenge.png. You can change these filenames in the code.

File encoding & limits

02 / Request

Request parameters

POST/api/v1/captcha/tasks

Send the JSON object directly, without a task wrapper. Set kind to bounding-box. All fields below belong to the JSON body.

Required headers
Authorizationstringrequired
Bearer followed by your ScrapingBuddy API key. Keep it on your server.
Content-Typestringrequired
application/json.
Idempotency-KeyUUID v4required
Retain one generated UUID per new task. Do not submit the same task concurrently.
Authentication guide
kindstringrequired
Always bounding-box.
imagestringrequired
JPEG, PNG, or GIF as Base64 or a data URL. Maximum 600 KB; keep both dimensions at or below 1000 px.
commentstringrequired
Describe the object or region to box, in up to 1000 characters.
canNoAnswerbooleanoptional
Allow a no-match answer if the object is absent. Default: false.

Decoded file limits use 1 KB = 1,000 bytes. The complete JSON payload must fit within 5,000,000 bytes after Base64 encoding.

03 / Result

Understand the result

Creation returns HTTP 201. Fetching the task returns HTTP 200. Both wrap the task in task; always check its status before reading the solution.

Each box has left (xMin), right (xMax), top (yMin) and bottom (yMax) edges measured in original-image pixels. The values are edges, not width and height. Derive dimensions by subtracting the minimum from the maximum.

solution.bounding_boxes{xMin, xMax, yMin, yMax}[]
Rectangle edges in original-image pixels, measured from the top-left. Width = xMax - xMin; height = yMax - yMin.
solutionobject
With canNoAnswer enabled, handle an empty or no-match answer before accessing rectangle values.
Shared task fields
idUUID
Save this ID to fetch the task or contact support.
statusstring
submitting or processing: wait. ready: use solution. failed: stop and read the error.
solutionobject | null
Null until a result is available. The shape depends on the CAPTCHA type.
errorCode / errorDescriptionstring | null
Task failure details. A failed task can still arrive with HTTP 200 or 201.
coststring | null
Provider-reported USD cost; not the customer debit.
chargedecimal string
Actual customer charge in USD: provider cost multiplied by 1.5. Zero before settlement or for legacy tasks.
billingStatusstring
reserved, charged, released, awaiting_credit, review, or legacy. A review requires support; awaiting_credit needs a top-up.
solveCountnumber | null
Provider-reported solving attempts when available.
createdAt / updatedAt / completedAttimestamp | null
Task timestamps; completedAt is null until the task has finished.
comment / requestMetastring / object
Saved instructions and input metadata. Raw files are not returned.

04 / Integrate

Complete examples

These Node.js and Python scripts prepare the input, create one task and poll until it is ready or failed. They stop waiting after approximately 3 minutes. A client timeout does not cancel the task.

  1. Set SCRAPINGBUDDY_API_KEY in your server environment.
  2. Place the input files beside your script, or update the filenames.
  3. For Node.js, use version 20+ and save as solve.mjs. For Python, install requests and save as solve.py.
  4. Run the script and retain the printed request and task IDs.

cURL shows task creation only. Use the GET example to retrieve its result.

When something goes wrong

Check whether you received an HTTP error or a task with status: failed. Fix validation errors before retrying. For HTTP 429, pause for Retry-After; all requests share the account limit of 60 per minute.

If creation times out, do not automatically submit another task. Keep your request ID and check the existing task or Usage first.

CAPTCHA API v1
CAPTCHA referenceCoordinatesGridDrag & DropBounding BoxNormalTextRotateAudio

Explore the documentation

CAPTCHA APIIntroduction

Choose a CAPTCHA solution, create a task and retrieve its answer.

Integration guidesYour first task

Make one request, wait for the answer, and read your first result. Start with a text question so you do not need to prepare a file.

Integration guidesAuthentication

Connect your backend securely with a ScrapingBuddy API key.

Integration guidesPrepare image & audio inputs

Encode the original file correctly and stay within the limits for your solution.

Integration guidesPolling & safe retries

Follow a task to completion without creating duplicate work.

Integration guidesErrors & troubleshooting

Find out whether a request was rejected, a task failed, or you simply need to wait.

Integration guidesList tasks & usage

Retrieve your recent tasks and account-level usage summary.

CAPTCHA referenceCoordinates CAPTCHA

Send one image and get back the x/y click points requested by your instruction. Use this for image challenges where the answer is one or more points, such as “click the apple” or “

CAPTCHA referenceGrid CAPTCHA

Send separate tile images or one complete grid and get back the selected tile numbers. Use this for challenges that ask the user to select matching squares from a tiled image.

CAPTCHA referenceDrag & Drop CAPTCHA

Send a background image plus puzzle pieces and get destination coordinates for each piece. Use this for visual puzzles where one or more draggable pieces must be placed into matchi

CAPTCHA referenceBounding Box CAPTCHA

Send one image and get object boundaries as xMin, xMax, yMin, and yMax. Use this for challenges that ask the user to draw a box around an object or region.

CAPTCHA referenceNormal CAPTCHA

Send a CAPTCHA image and get back the text that should be typed. Use this for distorted image text challenges where the expected answer is a string.

CAPTCHA referenceText CAPTCHA

Send a plain text question and get back the answer text. Use this for human-readable questions, riddles, or text-only challenges that do not require an image upload.

CAPTCHA referenceRotate CAPTCHA

Send an image and get back the angle needed to rotate it into the correct position. Use this for challenges where an image must be turned until it is upright or aligned.

CAPTCHA referenceAudio CAPTCHA

Send an MP3 audio CAPTCHA and get back the transcribed text. Use this for audio challenges where the answer is the words or numbers spoken in the file.