# run-workspace-integrity

`station__microgram__run-workspace-integrity` · external (needs EXECUTION_BACKEND_URL configured) · domain `microgram` · pv-relevance `pv-core`

Workspace health classifier: checks orphan_dirs, broken_members, and cache_gb against thresholds. HEALTHY (all zero, cache < 15GB), DEGRADED (1-2 issues), UNHEALTHY (3+). Prevents build-breaking workspace state from accumulating silently.

> **Note:** This tool routes through an external execution backend. If `EXECUTION_BACKEND_URL` is unset on the server, calls return JSON-RPC error `-32603 "Tool execution backend not configured"`. Tools with `backend: native` execute in-process and are always callable.

## Agent metadata

- `idempotent`: unknown
- `read_only`: unknown
- `expected_latency_ms`: unknown (not yet contract-tested)
- `cost_tokens_estimate`: unknown

## Input schema

- `orphan_dirs` *integer* (required) — Input parameter: orphan_dirs
- `cache_gb` *integer* (required) — Input parameter: cache_gb
- `broken_members` *integer* (required) — Input parameter: broken_members

## Example call

```json
POST /api/mcp
Content-Type: application/json

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "station__microgram__run-workspace-integrity",
    "arguments": {
      "orphan_dirs": 0,
      "cache_gb": 0,
      "broken_members": 0
    }
  }
}
```

## Related

- [/tools](/tools) — all 3062 tools
- [/tools/microgram__run-workspace-integrity](/tools/microgram__run-workspace-integrity) — HTML page
- [/tools/microgram__run-workspace-integrity/json](/tools/microgram__run-workspace-integrity/json) — JSON form (agent-friendly)
- [/api/mcp](/api/mcp) — endpoint
- [/AGENTS.md](/AGENTS.md) — agent guide
