Wait for Run Activity
deerflow_wait_activityBlock until a DeerFlow run yields new activity, completes, or times out, replacing many status polls with one call that returns as soon as activity appears.
Instructions
Block server-side until the run produces new activity, reaches a terminal status, or the timeout elapses — one call replaces many status polls. The server joins the run's live event stream (falling back to polling when the stream is unavailable), so it returns the moment new activity appears rather than on a fixed tick. Returns reason ('terminal' | 'activity' | 'timeout'), waited_seconds, timeout_seconds, the new activity since since_seq (one-line summaries), the plan-mode todo checklist, quiet/stall detection, and a next_step hint. Pass the returned last_event_seq as since_seq on the next call to continue from where you left off. While waiting it emits MCP progress notifications (elapsed/timeout) when the client supplies a progress token. Cancelling the request from the client aborts the wait and returns stop_reason 'cancelled_by_client'. Requires session or internal-token auth.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| run_id | Yes | The run id. | |
| since_seq | No | Only report events with seq greater than this (use last_event_seq from a previous response; 0 or omitted = latest events). | |
| thread_id | Yes | The thread id. | |
| timeout_seconds | No | Maximum seconds to wait before returning (default 30, capped server-side). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hint | No | ||
| error | No | ||
| quiet | Yes | ||
| todos | Yes | ||
| reason | Yes | ||
| run_id | Yes | ||
| status | Yes | ||
| stalled | Yes | ||
| activity | Yes | ||
| terminal | Yes | ||
| next_step | No | ||
| thread_id | Yes | ||
| created_at | No | ||
| updated_at | No | ||
| stop_reason | No | ||
| total_tokens | No | ||
| message_count | No | ||
| last_event_seq | No | ||
| llm_call_count | No | ||
| waited_seconds | Yes | ||
| elapsed_seconds | Yes | ||
| timeout_seconds | Yes | ||
| last_activity_at | No | ||
| seconds_since_update | No | ||
| seconds_since_activity | No |