Skip to content

fix(annotations): align firecrawl_search readOnlyHint with scrapeOptions.actions - #369

Open
syf2211 wants to merge 1 commit into
firecrawl:mainfrom
syf2211:fix/firecrawl-search-readonly-hint
Open

fix(annotations): align firecrawl_search readOnlyHint with scrapeOptions.actions#369
syf2211 wants to merge 1 commit into
firecrawl:mainfrom
syf2211:fix/firecrawl-search-readonly-hint

Conversation

@syf2211

@syf2211 syf2211 commented Aug 13, 2026

Copy link
Copy Markdown

Summary

Set readOnlyHint: false on the full-surface firecrawl_search tool because it accepts scrapeOptions.actions (click, write, executeJavascript) that can mutate pages visited during search result scraping.

Motivation

Fixes #311

MCP clients that honor readOnlyHint: true may skip confirmation prompts for tools that can drive browser interactions. The full firecrawl_search schema includes scrapeOptions.actions, but the annotation claimed read-only — inconsistent with firecrawl_scrape and other tools that expose the same action surface.

Changes

  • Change readOnlyHint from true to false on the main firecrawl_search registration in src/index.ts
  • Leave the search-profile firecrawl_search variant at readOnlyHint: true (it rejects scrapeOptions via a strict schema)
  • Add regression assertions in tests/mcp-smoke.test.mjs and tests/mcp-search-profile.test.mjs

Tests

npm run build
node --test tests/mcp-smoke.test.mjs -t "local keyless stdio"
node --test tests/mcp-search-profile.test.mjs
  • local keyless stdio omits feedback tools... — passes, asserts full-surface readOnlyHint === false
  • All 22 mcp-search-profile tests — pass, including search-profile readOnlyHint === true

Note: three pre-existing failures in mcp-smoke.test.mjs on this environment (keyless tool filtering / deprecated extract registration) are unrelated to this change.

Notes

  • Reviewed with composer-2.5: APPROVE
  • Optional follow-up: mirror firecrawl_scrape by using readOnlyHint: SAFE_MODE when cloud safe mode strips actions from the schema

Summary by cubic

Aligns the firecrawl_search annotation with its behavior by setting readOnlyHint to false when the tool accepts scrapeOptions.actions. Previously it claimed read-only, which let MCP clients skip confirmation for actions that can mutate visited pages.

  • Change: Update src/index.ts to set readOnlyHint: false for the full-surface firecrawl_search. Keep the search-profile variant at readOnlyHint: true because its schema rejects scrapeOptions.
  • Tests: Add assertions in tests/mcp-smoke.test.mjs (expects false) and tests/mcp-search-profile.test.mjs (expects true) to prevent regressions.
  • Impact: No schema/API changes. MCP clients may now prompt for confirmation when using the full-surface tool. No migration required.

Written for commit 9e53c85. Summary will update on new commits.

Review in cubic

…s allowed

The full-surface firecrawl_search tool accepts scrapeOptions.actions
(click, write, executeJavascript) but advertised readOnlyHint: true,
which lets MCP clients skip confirmation prompts incorrectly.

Keep the search-profile variant at readOnlyHint: true since it rejects
scrapeOptions entirely.

Fixes firecrawl#311

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

No issues found across 3 files

Auto-approved: Tightly scoped annotation fix: readOnlyHint now reflects that firecrawl_search accepts scrapeOptions.actions, with regression tests pinning both variants. No schema or behavior change; simple metadata correction with no human-owned tradeoff.

Re-trigger cubic

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.

firecrawl_search declares readOnlyHint: true but accepts scrapeOptions.actions (click/write/executeJavascript)

1 participant