feat: add --cookie-file support for JSON cookie files

- --cookie-file reads Chrome extension format ([{name, value, domain, ...}])
- Works with EditThisCookie, Cookie-Editor, and similar browser extensions
- Merges with --cookie when both provided
- MCP scrape tool now accepts cookies parameter
- Closes #7

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Valerio 2026-03-31 10:54:53 +02:00
parent 44f23332cc
commit da1d76c97a
4 changed files with 71 additions and 10 deletions

View file

@ -18,6 +18,8 @@ pub struct ScrapeParams {
pub only_main_content: Option<bool>,
/// Browser profile: "chrome" (default), "firefox", or "random"
pub browser: Option<String>,
/// Cookies to send with the request (e.g. ["name=value", "session=abc123"])
pub cookies: Option<Vec<String>>,
}
#[derive(Debug, Deserialize, JsonSchema)]