From c164370298ba957921f1578670661b8cb4d0bfc0 Mon Sep 17 00:00:00 2001 From: Arvid Andersson Date: Mon, 28 Apr 2025 18:27:10 +0200 Subject: [PATCH] Webhook param for batch scrape (#1505) The API endpoint supports the webhook param, align the client to support this. --- apps/python-sdk/firecrawl/firecrawl.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/apps/python-sdk/firecrawl/firecrawl.py b/apps/python-sdk/firecrawl/firecrawl.py index 10bbf099..de429c33 100644 --- a/apps/python-sdk/firecrawl/firecrawl.py +++ b/apps/python-sdk/firecrawl/firecrawl.py @@ -210,6 +210,7 @@ class ScrapeParams(ScrapeOptions): jsonOptions: Optional[JsonConfig] = None actions: Optional[List[Union[WaitAction, ScreenshotAction, ClickAction, WriteAction, PressAction, ScrollAction, ScrapeAction, ExecuteJavascriptAction]]] = None agent: Optional[AgentOptions] = None + webhook: Optional[WebhookConfig] = None class ScrapeResponse(FirecrawlDocument[T], Generic[T]): """Response from scraping operations.""" @@ -2432,15 +2433,15 @@ class FirecrawlApp: "batch_scrape_urls": {"formats", "headers", "include_tags", "exclude_tags", "only_main_content", "wait_for", "timeout", "location", "mobile", "skip_tls_verification", "remove_base64_images", "block_ads", "proxy", "extract", "json_options", - "actions", "agent"}, + "actions", "agent", "webhook"}, "async_batch_scrape_urls": {"formats", "headers", "include_tags", "exclude_tags", "only_main_content", "wait_for", "timeout", "location", "mobile", "skip_tls_verification", "remove_base64_images", "block_ads", "proxy", "extract", "json_options", - "actions", "agent"}, + "actions", "agent", "webhook"}, "batch_scrape_urls_and_watch": {"formats", "headers", "include_tags", "exclude_tags", "only_main_content", "wait_for", "timeout", "location", "mobile", "skip_tls_verification", "remove_base64_images", "block_ads", "proxy", "extract", "json_options", - "actions", "agent"} + "actions", "agent", "webhook"} } # Get allowed parameters for this method