Skip to main content
Questions or issues? Contact us at api-support@manus.ai. After creating a task with task.create, the agent runs asynchronously. Use task.listMessages to poll for events and track progress, or set up Webhooks to receive push notifications when task status changes.

Task status

Look for status_update events in the response. The agent_status field tells you what to do next:

Handling waiting status

When agent_status is waiting, the status_detail tells you what the agent needs:
There are two ways to respond, depending on waiting_for_event_type:
  • messageAskUser or cascadeAskUser — The agent is asking a question. Reply with task.sendMessage. Do not use task.confirmAction.
  • Action confirmations — Use task.confirmAction for supported action types, including those without confirm_input_schema. When present, the schema describes the expected input; otherwise use the documented input for that action below. Schema presence is not the routing criterion.
For an unrecognized waiting type, inspect the task and current endpoint documentation before responding; do not automatically treat it as an action to approve. When the agent supplies choices, the corresponding assistant_message includes a question_expectation object:
options contains display text, not option IDs or an enforced answer schema. Render single- or multiple-choice controls according to selection_mode, while allowing a free-text answer instead. Send a non-empty answer as ordinary message.content through task.sendMessage. For multiple choices, combine the selected text into one readable message, for example:
There is no required delimiter, option-ID array, or structured submission format. Do not submit an empty answer when nothing is selected; ask the user for text instead. response_method is currently fixed to send_message, never task.confirmAction. If a client encounters an unknown method, stop automatic dispatch and check the current API documentation rather than falling back to action confirmation. In task.listMessages, question_expectation is omitted for questions with no choices; use the question’s text and waiting event type to request a free-text answer. When present, options is non-empty. Webhooks can also describe a free-text question with options: []. The nested question_expectation.event_id exists only in webhooks and identifies the underlying question event. It is different from the webhook envelope’s event_id, which identifies the webhook notification. In task.listMessages, use the enclosing message’s id; there is no nested event_id. Neither question ID is required by task.sendMessage, and it is not a send-message idempotency key.

Using task.confirmAction

The input format varies by waiting_for_event_type. The table below lists currently supported event types — new types may be added in the future. When present, use confirm_input_schema for the definitive schema; its absence does not turn an action confirmation into an agent question.
For event types that support accept, passing accept: false will not produce any event — the task remains in waiting status. Exception: webdevRequestSecrets where accept: false explicitly rejects the request.

Using My Browser

You can let the agent use your local browser. When the agent needs a browser during execution, it will trigger a needConnectMyBrowser waiting event. Use browser.onlineList to get available clients, then select one via task.confirmAction:
If browser.onlineList returns an empty list, no browser clients are online. Install and enable the Manus Browser Extension first.

Complete flow

Structured Output: If you need the result in a specific JSON format, pass structured_output_schema when creating the task. See the Structured Output guide.