Workflow steps

tools.fetch

type: "tools.fetch"

Opens a web page in a real browser and returns its readable content. You can also capture an image, set its viewport and wait for visual rendering.

1 crediturl requiredcached for an hour
Using Python?

Switch any code block to Python: the choice applies to every page. Python SDK guide and resource reference.

urlstringrequired

The page. Private addresses are refused.

timeoutinteger20 000

Milliseconds, between 5 000 and 60 000.

typestringpage

Use screenshot for image-only capture; use page for readable content.

screenshotbooleanfalse

Also attach a full-page image to a page result, in the same credit.

viewport{ width, height }1280 × 720

For an image-only type: "screenshot" step, an explicit viewport returns viewport-only pixels; 320–2560 wide and 480–1600 high.

deviceScaleFactor1 | 2 | 31

Raster scale; 1× keeps output pixels equal to the viewport.

waitinteger1000

Extra visual settling time, 0–10000 ms.

{ id: "read", type: "tools.fetch", config: { url: "{{steps.find.output.results.0.url}}" } }
{"id": "read", "type": "tools.fetch", "config": {"url": "{{steps.find.output.results.0.url}}"}}

Output

{{steps.read.output.markdown}}      // the readable content — the field you usually want
{{steps.read.output.title}}
{{steps.read.output.timedOut}}
"{{steps.read.output.markdown}}"   # the readable content — the field you usually want
"{{steps.read.output.title}}"
"{{steps.read.output.timedOut}}"

markdown is what a model should read. elements.body is the HTML, several times larger for the same meaning.

The address is checked

Scheme, and that the host resolves to a public address; a redirect does not escape it. On an inbound trigger, where the URL may come from outside, that check is the thing standing between a workflow and whatever somebody typed.

timedOut is not a failure

What had loaded is returned, with the flag set. A chain that needs the whole page should test it rather than assume.