How to check when a scan is complete
After starting a scan on a target, check when it is complete by polling the target scan to verify its status.
Step 1: Check the status of a target scan
You will need the scan and target identifiers to check the status of a target scan. You obtain them, for example, after starting a scan on a target.
In this request, the scan identifier is 2TeAXi3hCYYV
and the target identifier is 3mX3wqKYBRQc
.
Request
curl 'https://api.probely.com/targets/3mX3wqKYBRQc/scans/2TeABi2hCYYV' \
-X GET \
-H 'Authorization: JWT <YOUR_PROBELY_TOKEN>' \
-H 'Content-Type: application/json'
The response will return the target scan, and if the status
is completed
, the target scan is finished.
You can also look into other details, such as:
- When the scan started and was completed.
- The number of low, medium, and high vulnerabilities identified.
- And details about the three scan components: fingerprinter, crawler, and scanner.
Response
{
"id": "2TeAXi3hCYYV",
"target": {
"id": "3mX3wqKYBRQc",
"name": "My target",
...
},
...
"status": "completed",
"started": "2024-04-01T08:00:23.347515Z",
"completed": "2024-04-01T08:49:11.447482Z",
...
"lows": 1,
"mediums": 4,
"highs": 24,
...
"crawler": {
"state": "ended",
"status": [
35.0,
35.0
],
"warning": [],
"error": [],
"full_status": {
...
}
},
"fingerprinter": {
"state": "ended",
"count": 2.0,
"warning": [],
"error": []
},
"scanner": {
"state": "ended",
"status": [
70.0,
70.0
],
"warning": [],
"error": [],
"full_status": {
...
}
},
...
}
An alternative to checking the status of a single scan is listing scans, where each scan has its status. Learn more in How to list scans.