Skip to content

refactor(core): drop url and format from webfetch output - #64534

Merged
rekram1-node merged 1 commit into
devfrom
webfetch-output
Nov 17, 2026
Merged

rekram1-node merged 1 commit into
devfrom
webfetch-output

Conversation

@rekram1-node

@rekram1-node rekram1-node commented Nov 17, 2026 •

Copy link
Copy Markdown
Collaborator

Issue for this PR

No issue.

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

webfetch's structured output repeated two input values back to the caller. A Code Mode program or plugin hook already has them, so they're dropped:

-{ url, contentType, format, output }
+{ contentType, output }

What the model reads is unchanged: on a direct call it only ever sees the page text, and contentType stays in metadata for the UI. This matches the earlier cleanups of the skill and websearch results.

How did you verify your code works?

bun test test/tool-webfetch.test.ts (91 pass) and bun run typecheck:tsc in packages/core.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

Added by the opencode bot (AI-generated).

Public API: removes url and format from the webfetch tool's structured output seen by Code Mode and plugin hooks (not backwards compatible for code that reads them; they need the call's input instead)

@opencodejr opencodejr 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.

Looks good. The tests pass and the type check is clean. Nothing in the repo reads the removed fields: the TUI, session UI and ACP all take the URL from the tool's input, and contentType stays in metadata.

Public API: the webfetch tool's structured output, as seen by Code Mode programs and plugin hooks, goes from { url, contentType, format, output } to { contentType, output }. This is not backwards compatible for any program or plugin that reads output.url or output.format; they need to read the call's input instead. What the model reads and the metadata are unchanged.

@rekram1-node
rekram1-node merged commit d9d0a46 into dev Nov 17, 2026
13 checks passed
@rekram1-node
rekram1-node deleted the webfetch-output branch November 17, 2026 22:56
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.

1 participant