--- method: POST path: /api/scanner/cancel/:jobId auth: jwt+admin area: scanner --- # Cancel Scan Requests cancellation of a pending or running scan job. Cancellation is cooperative — the file currently being processed finishes, the walk stops at its next context check, and the archive pass is skipped. ## Example response ```json example-response { "message": "scan cancellation requested", "job_id": "job-uuid", "status": "cancelled" } ``` ## Path parameters | Param | Type | Required | Notes | | ----- | ---- | -------- | ----- | | jobId | string | Yes | Scan job id | ## Errors | Status | Body | When | | ------ | ---- | ---- | | 404 | `{"error": "job not found"}` | no such job | | 409 | `{"error": "..."}` | job cannot be cancelled |