Skip to content

docs(agents): add docs and changeset for web_fetch - #2522

Merged
ben-reitz merged 2 commits into
web-fetch/thinkfrom
web-fetch/docs
Oct 8, 2026
Merged

ben-reitz merged 2 commits into
web-fetch/thinkfrom
web-fetch/docs

Conversation

@ben-reitz

@ben-reitz ben-reitz commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Docs and changesets for the web_fetch stack (#2525 → #2521).

docs/agents/
├── fetch-the-web.md      # new: setup, options, what the model sees, URL policy, errors, model-free use
├── index.md              # + Fetch the Web
├── search-the-web.md     # + "to read a result, see Fetch the Web"
└── browse-the-web.md     # + when to pick web_fetch over browser_execute
.changeset/
├── webfetch-tool.md      # agents: minor
└── think-web-fetch.md    # @cloudflare/think: patch (shared policy, peer floor)

The guide follows search-the-web.md: an AI SDK example first, then a table of host options and defaults (pageChars 20,000 · maxBytes 5 MB · timeoutMs 30 s · maxRedirects 5), what the model reads (<untrusted_web_content> wrapper, the chars/offset header), the URL policy (what's rejected, and the honest note that names aren't resolved), the error table with retry guidance, and fetchWeb + windowWebFetchPage for reading a page without a model.

Changesets are single-line with doc links, and live here because the stack merges together.

Evidence

  • Before: docs/agents/index.md lists Search the Web and Browse the Web only.
    After: Fetch the Web sits between them; every option, error code, and export named in the guide exists in feat(agents): add web_fetch tool #2520 (checked against index.ts and WebFetchErrorCode). oxfmt --check docs .changeset clean; typecheck → 132 projects.

Merge Danger

Door: two-way

Blast Radius: none

Markdown and two changesets. The changesets cut the agents minor and @cloudflare/think patch on merge, so this should land with, not before, the rest of the stack.

@ben-reitz
ben-reitz added this pull request to stack #2523 October 8, 2026 10:12
@changeset-bot

changeset-bot Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 2303d9f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@cloudflare/think Patch
agents Patch
@cloudflare/agent-think Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@agent-think

agent-think Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

✅ agents import sizes: no significant changes (31c7348c → 04330a59, workflow run)

@pkg-pr-new

pkg-pr-new Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

agents

npm i https://pkg.pr.new/agents@2522

@cloudflare/ai-chat

npm i https://pkg.pr.new/@cloudflare/ai-chat@2522

@cloudflare/codemode

npm i https://pkg.pr.new/@cloudflare/codemode@2522

hono-agents

npm i https://pkg.pr.new/hono-agents@2522

@cloudflare/shell

npm i https://pkg.pr.new/@cloudflare/shell@2522

@cloudflare/think

npm i https://pkg.pr.new/@cloudflare/think@2522

@cloudflare/voice

npm i https://pkg.pr.new/@cloudflare/voice@2522

@cloudflare/worker-bundler

npm i https://pkg.pr.new/@cloudflare/worker-bundler@2522

commit: 89a23fd

@ben-reitz
ben-reitz removed this pull request from stack #2523 October 8, 2026 11:55
@ben-reitz
ben-reitz added this pull request to stack #2528 October 8, 2026 11:55
@ben-reitz
ben-reitz force-pushed the web-fetch/docs branch 3 times, most recently from bcc4cee to bd11253 Compare October 8, 2026 13:17
@ben-reitz
ben-reitz force-pushed the web-fetch/docs branch 2 times, most recently from 00c9e84 to 284c2a4 Compare October 8, 2026 13:33
@ben-reitz
ben-reitz marked this pull request as ready for review October 8, 2026 13:45
@ben-reitz ben-reitz changed the title docs(agents): add Fetch the Web guide for web_fetch docs(agents): add docs and changeset for web_fetch Oct 8, 2026
devin-ai-integration[bot]

This comment was marked as resolved.

Adds docs/agents/fetch-the-web.md (options, what the model sees, URL policy, error codes, Think and model-free usage), links it from the docs index and Search the Web, and adds the agents and @cloudflare/think changesets for the web_fetch stack.
Comment thread .changeset/webfetch-tool.md Outdated
Comment thread .changeset/think-web-fetch.md
Comment thread .changeset/webfetch-tool.md
@ben-reitz
ben-reitz force-pushed the web-fetch/docs branch 2 times, most recently from 04330a5 to 2303d9f Compare October 8, 2026 14:37
@ben-reitz
ben-reitz merged commit bcf5d20 into main Oct 8, 2026
4 of 5 checks passed
@ben-reitz
ben-reitz deleted the web-fetch/docs branch October 8, 2026 14:39

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

Devin Review

@@ -0,0 +1,5 @@
---
"agents": patch

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔍 Web fetch release classification differs

The agents/webfetch changeset requests a patch, but the PR description expects a minor release. A separate pending minor changeset can mask the difference when released together; confirm the intended version bump.

Devin Review


Was this helpful? React with 👍 or 👎 to provide feedback.

@github-actions github-actions Bot mentioned this pull request Oct 8, 2026
brandhaug added a commit to brandhaug/b2b-saas-starter that referenced this pull request Oct 12, 2026
## pnpm-workspace.yaml (default)

## Dependency Updates

| Package | From | To | Type |
| --- | --- | --- | --- |
| `agents` | 0.27.0 | 0.28.0 | minor |

## Release Notes

<details>
<summary><b>agents</b> (0.27.0 → 0.28.0)</summary>

This release adds two new tools, `browser` via
`agents/browser/{pi,ai-sdk,tanstack-ai}` allowing an agent to create and
manipulate a persistent browser session and `web_fetch` via
`agents/webfetch/{pi,ai-sdk,tanstack-ai}` that can retrieve most
document formats converted into markdown.

### Minor Changes

- [#2484](cloudflare/agents#2484)
[`dedbee4`](cloudflare/agents@dedbee4)
Thanks [@<!---->ben-reitz](https://github.com/ben-reitz)! - Add
`browserTool()` to `agents/browser/pi`. See [Persistent
browser](https://github.com/cloudflare/agents/blob/main/docs/agents/browse-the-web.md#persistent-browser).

- [#2473](cloudflare/agents#2473)
[`6614955`](cloudflare/agents@6614955)
Thanks [@<!---->mattzcarey](https://github.com/mattzcarey)! - Make
`agents/lifecycle` stable along with the `Scheduler`
(`agents/schedules`), `State` (`agents/state`), `WebSockets`
(`agents/websockets`) and `MCPClientManager` (`agents/mcp/client`)
capabilities. See
[Lifecycle](https://github.com/cloudflare/agents/blob/main/docs/agents/lifecycle.md).

### Patch Changes

- [#2540](cloudflare/agents#2540)
[`b65956e`](cloudflare/agents@b65956e)
Thanks [@<!---->mattzcarey](https://github.com/mattzcarey)! -
`ThinkHarness` now keeps its sessions and operations in the shared
`agents/harness/store`. Migrations are performed on first run. See
[ThinkHarness:
Recovery](https://github.com/cloudflare/agents/blob/main/docs/agents/harnesses/think.md#recovery).

- [#2522](cloudflare/agents#2522)
[`bcf5d20`](cloudflare/agents@bcf5d20)
Thanks [@<!---->ben-reitz](https://github.com/ben-reitz)! - Add
`agents/webfetch`, a `web_fetch` tool that reads a URL as Markdown,
JSON, or text (HTML, PDF, and Offi

…[full
notes](https://github.com/cloudflare/agents/releases/tag/agents%400.28.0)

</details>

---
*This PR was auto-generated by
[catalog-update-action](https://github.com/brandhaug/catalog-update-action).*

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants