ScraperData

Async tasks

Pingback

When a queued search ends, we call your URL to tell you. The call carries the task id, not the answer.

The call

We send GET to your pingback_url with two query parameters added, for example https://example.com/hook?id=TASK_ID&status=done.

FieldTypeDescription
idstringThe task id. Read the answer with GET /v1/tasks/{id}.
statusstringdone or failed.

To choose where they go, put $id and $status in your URL, for example https://example.com/tasks/$id?state=$status.

Answering it

  • Answer with any 2xx status within 10 seconds. Do the slow work after answering.
  • We try 3 times, 1 and 5 minutes apart, and do not follow redirects.
  • The call comes with the ScraperData-Pingback/1.0 user agent.

If a pingback never arrives

The answer is still there: read the task by its id. The task also shows how the pingback went, in pingback.status and pingback.last_status_code.

Safety

We only call public addresses: the host of your URL may not point to a private network, a local address or cloud metadata. The call holds no data and no key, so anyone who guesses your URL learns nothing; the answer is only given to your API key.