> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tracectrl.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Trigger Scan

> Start a scan job and poll for completion

Triggers a scan from the UI. The endpoint returns immediately; clients should poll [`/scan/status/{scan_id}`](https://docs.tracectrl.ai/api-reference/scan-status) for completion.

Only one scan can run at a time. A second concurrent trigger returns `409 A scan is already running`. Stale job records (>30 min old) are pruned on each trigger.

### Request body — `ScanTriggerPayload`

**workspace\_path** `string` *required*

Absolute path to the OpenClaw workspace (must contain `openclaw.json`).

**profile** `string` (default: L1)

Benchmark profile.

### Errors

* `400` — Path is not a valid OpenClaw workspace
* `409` — A scan is already running

### Response

**scan\_id** `string`

Job ID for status polling (12-char hex)

**status** `string`

Always `running` on a successful trigger

**started\_at** `string`

ISO-8601 timestamp


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.