Press / to search

All documentation
docs Teach the agent Step reference

Runs onWrit CloudDesktopSelf-hosted

Waiting step

Wait for download

The wait_for_download step waits for the browser to finish a download and captures the file as a run artifact. It can optionally click the element that triggers the download itself.

In a workflow, this is a step object with "type": "wait_for_download". Steps run in order, and each step can read the outputs of the steps before it. See the full workflows reference for the 30+ step types.

Writ runs on your own accounts, with your own credentials and data, on sites you are authorized to use.

Fields

FieldTypeDescription
trigger_selector selector Optional element to click inside the wait to start the download.
output_key string Name for the captured file so later steps or workflows can reuse it as {{file:…}}.

Example

A single wait_for_download step as it appears in a workflow's steps array:

{
  "type": "wait_for_download",
  "config": { "trigger_selector": "a.export-csv", "output_key": "report" }
}

How it behaves

  • The captured file is stored with the run and can feed a later upload step.
  • If no download starts within the timeout, the step fails with a clear message.

Where it runs

The wait_for_download step executes wherever the run executes. On your local or BYO agent there is no compute charge and the agent can reach intranet-only systems; on Writ cloud the run is metered by running time (~$0.12 per browser-hour, from your plan’s included usage wallet.

What next

  • Workflows - the full step vocabulary and the workflow object.
  • Recorder - capture steps by clicking through a site.
  • Managed endpoints - turn the workflow into a REST endpoint, or an MCP tool.