Web Crawl Tool
Multi-page web crawling tool for exploring entire websites and subdomains.
Quick Start
import { WebCrawlTool } from '@bubblelab/bubble-core';
import { CredentialType } from '@bubblelab/shared-schemas';
const result = await new WebCrawlTool({
url: 'example', // The root URL to crawl and extract content from
credentials: {
[CredentialType.FIRECRAWL_API_KEY]: process.env.FIRECRAWL_API_KEY as string,
},
}).action();
Operation Details
execute
- Input Schema
- Output Schema
urlstring required- The root URL to crawl and extract content from
format'markdown'- Output format for crawled content
onlyMainContentboolean- Extract only main content, filtering out navigation/footers
maxPagesnumber- Maximum number of pages to crawl
crawlDepthnumber- Maximum depth to crawl
includePathsstring[]- URL patterns to include in crawl (regex patterns), Example: ["^/blog/.$", "^/docs/.$"]
excludePathsstring[]- URL patterns to exclude from crawl (regex patterns), ["^/admin/.$", "^/private/.$"]
waitFornumber- Time to wait for dynamic content in milliseconds
credentialsRecord<CredentialType,string>- Required credentials including FIRECRAWL_API_KEY
urlstring required- The original URL that was crawled
successboolean required- Whether the crawl operation was successful
errorstring required- Error message if crawl failed
pagesobject[] required- Array of crawled pages with content
totalPagesnumber required- Total number of pages crawled
creditsUsednumber required- Number of credits used
metadataobject- Additional metadata about the crawl operation