v2

latestOpenAPI 3.0.1private2026-07-2667209320.4 KB
Perch

Stop a hosted scan

Stop a Scan

Stops a running hosted security scan and cleans up the resources used for the scan.

This endpoint will immediately stop any running scan for the specified application and clean up the associated hosted resources.

Prerequisites

  • A scan must be currently running for this application

Request Body

ParameterDefaultDescription
id""
name""
command{}

Response

ParameterDefaultDescription
id""
name""
status"UNKNOWN"
{
	"id": "",
	"name": "",
	"status": "UNKNOWN"
}

Status Response

The response will include a status of HOSTED_SCANNER_DISCONNECTED to indicate the scan has been successfully stopped.

Errors

  • 404 Not Found: Application not found, no active scan, or user doesn't have access

👥 Teams Supported If the application belongs to a StackHawk Team, only members of the Team can call this endpoint. 🧾 Audited This is recorded as SCAN_ERRORED User Activity.

Requires write:scan permission.

post/api/v1/app/{appId}/perch/stop

Path parameters

appIdstring uuid required

UUID identifier for this StackHawk Application.

Request body

idstring
namestring

Response

OK

idstring
namestring
status'OFFLINE' | 'ONLINE' | 'RUNNING' | 'HEARTBEAT' | 'HOSTED_SCANNER_CONNECTED' | 'HOSTED_SCANNER_PROVISIONING' | 'HOSTED_SCANNER_DISCONNECTED' | 'HOSTED_SCANNER_ERRORED' | 'SCREENR_STARTING' | 'SCREENR_BROWSER_READY' | 'SCREENR_MCP_READY' | 'SCREENR_READY' | 'SCREENR_ANALYZING' | 'SCREENR_SESSION_COMPLETE' | 'SCREENR_CONNECTED' | 'CONFIG_VALIDATOR_CONNECTED' | 'CONFIG_VALIDATION_RUNNING' | 'CONFIG_VALIDATION_COMPLETE' | 'CONFIG_VALIDATION_FAILED' | 'AUTH_VALIDATOR_CONNECTED' | 'AUTH_VALIDATION_RUNNING' | 'AUTH_VALIDATION_COMPLETE' | 'AUTH_VALIDATION_FAILED' | 'SCREENR_SESSION_ABANDONED' | 'SCREENR_SESSION_COMPLETED' | 'VALIDATOR_CONNECTED' | 'SCREENR_ASSET_NOT_FOUND' | 'HOSTED_VALIDATOR_PROVISIONING' | 'SCREENR_AUTH_LOGGED_IN' | 'SCREENR_AUTH_LOGIN_TIMEOUT' | 'SCREENR_AUTH_CONFIG_COMPLETE' | 'SCREENR_AUTH_CONFIG_FAILED' | 'SCREENR_AUTH_READY'