The full upstream README, mirrored here for reference. Install config, tool schemas, adoption signals, and an original overview live on the MCP Await listing page.
Condition watcher MCP server + CLI for AI CLI assistants (Claude Code, Codex, Cursor, etc.).
Instead of polling with sleep loops and curl --retry that waste API round-trips, call a wait tool once — it blocks until the condition is met and returns the result.

| Tool | Key Params | How it watches |
|---|---|---|
wait_for_port | host, port | TCP dial loop, 500ms interval |
wait_for_file | path, event (create/modify/delete) | inotify via notify crate, no polling |
wait_for_url | url, expected_status (default 200) | curl loop, 2s interval (requires curl) |
wait_for_pid | pid | /proc/{pid} check, 500ms interval |
wait_for_docker | container | docker wait (requires docker) |
wait_for_gh_run | run_id, repo (optional) | gh run watch (requires gh) |
wait_for_command | command, interval_seconds (default 5) | Re-run via sh -c until exit 0 |
cancel_watch | watch_id | Cancels a non-blocking watch |
All tools accept timeout_seconds (default: 300) and blocking (default: true).
The binary doubles as a standalone CLI tool:
| Code | Meaning |
|---|---|
| 0 | Condition met (success) |
| 1 | Timeout |
| 2 | Error |
All commands output JSON:
Add to ~/.claude.json:
The binary runs as a stdio MCP server when invoked without a subcommand (or with mcp-await serve).
The tool call holds until the condition is met, times out, or is cancelled. This is the simplest mode — the AI assistant waits for the result.
Set blocking: false to get an immediate response with a watch_id and resource URI. The server monitors in the background and pushes a notification when done.
Flow:
wait_for_port with blocking: falsenotifications/resources/updated when the condition is metwatch://port-1 for the full resultCancel any non-blocking watch with cancel_watch:
Non-blocking watches are exposed as MCP resources at watch://{watch_id}.
list_resources — returns all active and completed watchesread_resource("watch://port-1") — returns JSON with the watch status and resultAgents sometimes fall back to shell workarounds instead of using mcp-await. Add a snippet to your project's agent instructions file to reinforce the behavior:
| Agent | Instructions file |
|---|---|
| Claude Code | CLAUDE.md |
| Codex | AGENTS.md |
| Gemini CLI | GEMINI.md |
| Cursor | .cursor/rules/ |
| Windsurf | .windsurfrules |