test_workflow
Autonomously TEST a GUI workflow and report whether it works.
OpenFactory's AI drives the tester VM (sees the screen, clicks/types) toward your goal, recording each step to the app-test harness with video. This spends platform AI and is metered against your plan's AI allowance; it is refused once that allowance is used. To use your own model instead, drive the VM yourself with desktop_screenshot / desktop_interact.
ASYNC BY DEFAULT: this returns right away with a run_id while the AI keeps driving the VM in the background, so your MCP client's call never blocks/times out. Poll get_app_test_run(run_id) — when status flips to passed/failed/error the run.verdict_notes holds the verdict and run.video has the recording. Pass wait=true to block for the verdict inline instead (short workflows only).
Run ensure_tester_vm first, and make sure the app is reachable from the VM.
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": {
"app_name": "<app_name>",
"scenario": "<scenario>",
"instructions": "<instructions>"
},
"name": "test_workflow"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| wait | No | If true, block until the agent finishes and return the verdict inline (may hit your MCP client's call timeout for long runs). Default false: return immediately with a run_id; poll get_app_test_run(run_id) for the verdict + video. | |
| api_key | No | Your OpenFactory MCP API key (optional) | |
| app_url | No | URL to open first (as seen from the VM) | |
| vm_name | No | Tester VM to test in (of-tester-*/of-desktop-*). Omit (recommended) to auto-lease one from the app's tester pool — it queues if every VM is busy and is released automatically when the run finishes, so two tests never share a VM. | |
| app_name | Yes | Stable app key for history grouping, e.g. 'knostra' | |
| scenario | Yes | Stable scenario key, e.g. 'booking-smoke' | |
| max_steps | No | Max agent steps (1-20) | |
| instructions | Yes | The workflow + what 'works' means, e.g. 'Open /booking, fill the demo form, submit, and verify a confirmation appears.' | |
| session_token | No | Session token from a previous tool response |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||