Get Debug Evidence
get_debug_evidenceRetrieve error details, flake verdict, regression boundary, and trace/image links for a failing test so you can debug from evidence instead of guesswork.
Instructions
Start every failing-test investigation here. One call returns the whole cheap tier of the evidence ladder: the full error message, the computed flake verdict with its per-attempt failure signatures, the regression boundary (the last run this test passed and the first it failed), and download links for the trace, error-context and the expected/actual/diff images on a visual failure. Read all of it before forming a hypothesis. The verdict says whether the failure repeats, never why, so it rules fixes out rather than pointing at a cause; the boundary turns "why does this fail" into "what changed between these two runs", which is a far smaller question. Artifact links are minutes-scale: download what you need immediately, and call this again to mint fresh ones rather than treating an expired link as a missing artifact. Debugging several failures from one run? Pass them all in testcase_ids with testrun_id: one call, with the shared rules and environment sent once.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"projectId": "<projectId>"
},
"name": "get_debug_evidence"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| format | No | Response shape. "md" is markdown, and markedly cheaper for the same content. | |
| maxLength | No | Cap the markdown length. Applies to format="md" only; anything cut is announced in the output. JSON is never truncated, because a cut payload would not parse and would read as a complete one. | |
| projectId | Yes | Project ID (e.g. project_<id>) | |
| testrun_id | No | Run scope. Omit to use the most recently started run carrying this case. | |
| testcase_id | No | The case's pw_test_id — exact, so prefer it when known. | |
| testcase_ids | No | Several pw_test_ids from one run, instead of testcase_id. Needs testrun_id. Always JSON, under `tests`. | |
| testcase_name | No | Full test title. Give this or testcase_id. | |
| suite_file_path | No | Spec file path — only needed when the title is shared across files. | |
| include_instructions | No | Default false: the response carries short debugging rules. Set true for the full procedure and the trace runbook. |