What is the developer interface?
Library API, CLI, REST service, MCP server, UI; output formats; language bindings.
Verdict
Crawl4AI covers the most surfaces from one install: a library, the crwl CLI, a FastAPI server and MCP. Firecrawl is the most complete hosted-style REST API. The rest split into services, libraries and visual tools.
Self-hosted services. Firecrawl exposes v1 and v2 REST endpoints (/scrape, /crawl, /map, /extract and more) with SDKs in nine languages, and its default compose file runs with authentication off. Browserless accepts stock Puppeteer or Playwright over WebSocket plus seven REST recipes, under SSPL-1.0 or a commercial licence. Crawl4AI’s server adds NDJSON streaming and MCP over WebSocket and SSE. Our editors found that OmniParse’s Python SDK posts to routes its own server lacks.
Python and JavaScript libraries. Scrapling pairs a Python API and spiders with an extract CLI and scrapling-mcp. Trafilatura has a CLI with --crawl, --sitemap and XML-TEI output. ScrapeGraphAI runs graph classes with no server, CLI or MCP. Parsera offers run/arun, and its CLI always builds GPT-4o-mini, so it needs OPENAI_API_KEY. llm-scraper is an ESM class typed by Zod. AutoScraper saves rules as JSON. Botright is async-only and returns Playwright objects. Selenium-Driverless copies Selenium’s method names over CDP and adds a sync wrapper. Turndown is a TurndownService with addRule, keep, remove and use, running in Node and browsers.
Visual tools and apps. Crawlab is a web UI and Gin REST API with JWT login. Spiders report records through its SDK’s save_item, but the gRPC key falls back to a constant and the file-sync routes are anonymous. Spider-Flow is a browser flowchart editor with /rest/run. It has no authentication at all, and its SQL node runs queries for anyone who reaches port 8088. ScraperAI’s Click wizard highlights proposed XPaths in Chrome and saves a reusable JSON config. CyberScraper 2077 is a Streamlit chat app only, exporting CSV, Excel or Google Sheets.
Pick: Firecrawl or Crawl4AI’s server when several services must call one scraping endpoint. Pick: Scrapling or Crawl4AI to give an agent fetch tools over MCP. Pick: Crawlab for an operations UI over spiders you already have, or ScraperAI’s wizard for an analyst building one catalog scraper.
Per-project answers
firecrawl/firecrawl
answeredREST API: The primary interface is a REST API served by Express, with two major versions:
- v1 (
routes/v1.ts): POST endpoints for/scrape,/crawl,/batch/scrape,/search,/map,/extract, plus WebSocket at/crawl/:jobIdfor streaming crawl status. - v2 (
routes/v2.ts): Adds POST/parse,/parse-upload,/agent,/browser,/feedback,/slack,/monitor,/research-proxy,/scrape-browser, and OAuth token introspection. Batch/scrape and crawl via NuQ queues. Both versions use middleware chains for auth, rate-limiting, credit checks, blocklist filtering, idempotency, and country validation.
Language SDKs: Multiple officially maintained SDKs under the monorepo's apps/ directory: python-sdk (FirecrawlApp with sync/async, Watcher, typed errors), js-sdk, go-sdk, rust-sdk, dot-net-sdk, ruby-sdk, php-sdk, java-sdk, elixir-sdk. All cover the core endpoints.
CLI: No standalone CLI is packaged — the SDKs serve as programmatic clients.
MCP Server: An MCP (Model Context Protocol) server is hosted at mcp.firecrawl.dev/v2/mcp with OAuth and API-key auth (services/mcp/action-logs.ts:8-9). Action logs record MCP tool usage with retention, pagination, and team-scoped queries.
UI: An ingestion dashboard UI exists at apps/ui/ingestion-ui/ built with Vue.js/Vite and Tailwind CSS.
Output Formats: The core Document type contains: markdown, rawHtml, rawBase64, html, screenshot, actions, branding, json, extract, summary, answer, highlights, links, images, audio, video, product, menu, changeTracking. All controlled by the formats array parameter.
D4Vinci/Scrapling
answeredScrapling provides multiple interfaces:
Python library API — Primary interface. Import fetchers (Fetcher, AsyncFetcher, StealthyFetcher, DynamicFetcher) for stateless one-off use, or session classes (FetcherSession, StealthySession, DynamicSession) with with/async with. All return a Response object (subclass of Selector parser) for CSS/XPath/text extraction. Standalone parser: from scrapling.parser import Selector.
Spider framework — Scrapy-like class-based API with async parse() methods yielding items/requests. Built-in export: result.items.to_json(), to_jsonl(), to_csv(), to_xml(). Streaming via async for item in spider.stream().
CLI (scrapling/cli.py) — scrapling shell (IPython-based interactive shell with Scrapling integration and curl-to-Scrapling conversion), scrapling extract <method> <url> <output_file> (format auto-detected from extension: .html/.md/.txt), scrapling install (browser deps).
MCP Server (scrapling/core/ai.py) — Invoked via scrapling-mcp. ~12 tools over stdio or streamable-http with optional bearer auth. Session management with create/fetch/close/list lifecycle. Screenshot tool returns images.
Agent Skill — agent-skill/Scrapling-Skill/ file teaching coding agents the current API so generated code is accurate.
Docker — pyd4vinci/scrapling (DockerHub) and ghcr.io/d4vinci/scrapling:latest (GHCR) with all browsers pre-installed.
Scrapy integration (scrapling/integrations/scrapy.py) — scrapling_response decorator lets existing Scrapy callbacks parse with Scrapling's parser.
Output formats — Items export to JSON/JSONL/CSV/XML. Page content exports to HTML/Markdown/plain text via file extension or extraction_type.
unclecode/crawl4ai
answeredLibrary API. AsyncWebCrawler (crawl4ai/async_webcrawler.py) is the main class, with arun() for single URLs and arun_many() for batches. Both accept CrawlerRunConfig and return CrawlResult objects containing html, markdown (raw/fit/citations), extracted_content, screenshot, pdf, metadata, and more. CLI. crawl4ai/cli.py provides a command-line interface; crawl4ai/cloud/cli.py handles cloud deployments. REST API. The Docker server (deploy/docker/server.py) exposes POST endpoints: /crawl (JSON), /crawl/stream (NDJSON), /md (Markdown), /llm (QA), /screenshot, /pdf, /html, /execute_js, /config/dump, /ask (BM25 context retrieval), and /schema. Streaming protocol. /crawl/stream returns a StreamingResponse with application/x-ndjson content type. Each result is a JSON line via stream_results() (deploy/docker/api.py:616), which serializes each CrawlResult as it arrives from the async generator, includes a heartbeat mechanism, and finishes with {"status":"completed"}. Deep-crawl streaming (crawl4ai/async_webcrawler.py:1047-1057) wraps the BFS async generator in the same NDJSON format. MCP server. deploy/docker/mcp_bridge.py attaches at /mcp/ws (WebSocket) and /mcp/sse (SSE) transports. The WebSocket handler (_ws, line 198) uses anyio.create_memory_object_stream to bridge the MCP server's read/write streams, receives JSON-RPC messages from the client, and proxies tool calls to the FastAPI endpoints via httpx loopback with a service token. The SSE transport (_MCPSseApp, line 247) uses SseServerTransport.connect_sse from the MCP SDK. Monitor WebSocket. /monitor/ws (deploy/docker/monitor_routes.py:354) pushes JSON every 2 seconds with health stats, active requests, browser pool, timeline data, and janitor logs. The dashboard JS (static/monitor/index.html) implements auto-reconnect with exponential backoff and falls back to HTTP polling. Output formats. Results return as Python objects (library) or JSON (API): CrawlResult.model_dump() includes all fields. PDF bytes are base64-encoded over the wire. The schema endpoint GET /schema exposes BrowserConfig/CrawlerRunConfig for automated client generation.
WebSocket/SSE Streaming Details
The server has three distinct streaming protocols:
1. Crawl streaming (NDJSON). Triggered by setting stream=true in CrawlerRunConfig or hitting /crawl/stream. handle_stream_crawl_request() (deploy/docker/api.py:889) creates the crawler, configures stream=True on the CrawlerRunConfig, and returns a (crawler, async_generator, hooks_info) tuple. stream_process() (deploy/docker/server.py:1020) wraps the generator in FastAPI's StreamingResponse(media_type="application/x-ndjson"). The stream_results() function (api.py:616) iterates the generator, serializes each CrawlResult via model_dump(), encodes base64 if PDF bytes are present, adds server_memory_mb, and yields one JSON line per result followed by . For deep crawling, arun() returns an async generator directly (async_webcrawler.py:1047-1057) — the BFS strategy's _arun_stream() yields results as pages are crawled level-by-level.
2. MCP WebSocket (/mcp/ws). Defined in mcp_bridge.py:197. The handler creates two anyio.create_memory_object_stream(100) pairs (client→server and server→client). Messages are validated against JSONRPCMessage schema via pydantic's TypeAdapter. Three concurrent tasks run in an anyio.TaskGroup: ws_to_srv() reads JSON from the WebSocket and sends to the MCP server; mcp.run() processes the MCP protocol; srv_to_ws() reads MCP responses and sends JSON back to the WebSocket. Authentication is handled by AuthGateMiddleware at the ASGI level; WebSocket clients pass ?token= in the query string.
3. MCP SSE (/mcp/sse). Uses the MCP SDK's SseServerTransport (mcp_bridge.py:241). A raw ASGI callable class _MCPSseApp avoids Starlette middleware interference with route wrappers. Messages POST to /mcp/messages/{session_id}. The same tool/resource handlers back both transports.
4. Monitor WebSocket (/monitor/ws). Pushes a flat JSON object every 2 seconds (monitor_routes.py:370-397) aggregating health summary, request counts, browser list, timeline data, janitor log, and error log. The JS dashboard falls back to HTTP polling if WebSocket fails.
Agent Composition & Multi-Step Extraction Pipelines
The codebase has several composition patterns:
C4A-Script DSL. crawl4ai/script/c4ai_script.py defines a domain-specific language for browser automation. Scripts compile to JavaScript — the Compiler class (line 324) parses via Lark grammar, collects PROC...ENDPROC procedure definitions (line 355), inlines CALL references (line 362), substitutes $variable references (line 372), and emits JavaScript for each command (line 387). Commands include GO, CLICK, WAIT, TYPE, EVAL, SCROLL, DRAG, IF/REPEAT flow control, and SETVAR state. This compiles to js_code that runs in the Playwright browser — no core crawler modification needed. Example: a "login" procedure defined once, then called after navigation.
Deep crawl strategy chain. DeepCrawlDecorator (crawl4ai/deep_crawling/base_strategy.py:10) wraps AsyncWebCrawler.arun(): when CrawlerRunConfig.deep_crawl_strategy is set, the decorator intercepts the call, passes it to the strategy's arun(), which calls _arun_stream() or _arun_batch(). The strategies (BFSDeepCrawlStrategy, DFSDeepCrawlStrategy, BFFDeepCrawlStrategy) each implement link discovery with a composable FilterChain and optional URLScorer. This forms a pipeline: fetch → extract links → filter → score → queue → recurse.
Extraction strategy pipeline. Multiple extraction strategies can be composed with ContentScrapingStrategy — for example, PDF content uses PDFCrawlerStrategy (crawler) → PDFContentScrapingStrategy (scraper that downloads + parses + extracts images/links). The LLM extraction internally chains: HTML → sanitize_html → merge_chunks (splits by token budget) → ThreadPoolExecutor with LLM calls → split_and_parse_json_objects → merge results. Hooks (deploy/docker/hook_registry.py) provide another composition dimension: declarative actions like block_resources, scroll_to_bottom, or set_cookie can be chained before/after crawl phases.
PDF Support Status (Source-Level)
PDF support is fully implemented at the source level, not just README claims. Key classes:
PDFCrawlerStrategy(crawl4ai/processors/pdf/__init__.py:49): AnAsyncCrawlerStrategythat returns a placeholder response (placeholder_html=True) — it does nothing itself, signaling to the pipeline thatPDFContentScrapingStrategywill handle actual work.PDFContentScrapingStrategy(line 79): AContentScrapingStrategythat downloads PDFs over HTTP(S) usingrequestswith a hand-written redirect follower (_fetch_with_redirect_checks, line 259) that validates every hop against an injected URL/peer-IP validator for SSRF protection. It caps download size (max_pdf_bytes, default 100 MiB), page count (max_pdf_pages, default 2000), and redirect depth (max_redirects, default 5). The file is written to a temp directory, then processed. Output is aScrapingResultwithcleaned_html(wrapping per-page<div class="pdf-page">sections), plusmedia[images]andlinks[urls]each tagged with page numbers.NaivePDFProcessorStrategy(crawl4ai/processors/pdf/processor.py:57): The processing engine usingpypdf. It extracts metadata (title, author, producer, creation/modification dates, encryption status, file size — lines 435-457), per-page text (with positional layout info viavisitor_textcallback), images (handling FlateDecode/PNG-predictor, DCTDecode/JPEG, CCITTFaxDecode/TIFF, JPXDecode/JPEG2000 — lines 254-421), and hyperlinks. Images can be saved locally or returned as base64 data URLs. Text is cleaned into both Markdown and HTML per page (viaclean_pdf_text/clean_pdf_text_to_htmlinutils.py). Aprocess_batch()method (line 144) usesThreadPoolExecutorfor parallel page processing.Integration. The Docker server imports these in
handle_crawl_request()(api.py:703) andhandle_stream_crawl_request()(api.py:931) — when the user'sCrawlerRunConfig.scraping_strategyis an instance ofPDFContentScrapingStrategy, it instantiatesPDFCrawlerStrategydirectly (not from the pool, since it has no browser) and wires the URL validator. The egress policy is injected at server boot (server.py:163-190) viaset_url_validatorandset_peer_ip_validator, so PDF fetches enforce the same SSRF protection as browser-based fetches. Hooks are not supported with PDFs (api.py:707-708: "PDFCrawlerStrategy has no browser page, so hooks can't attach to it").
ScrapeGraphAI/Scrapegraph-ai
answeredLibrary API (primary). The main developer interface is importing graph classes from scrapegraphai.graphs and running them: SmartScraperGraph(prompt, source, config).run(). The 25+ graph variants handle different use cases — single-page (SmartScraperGraph), multi-page (SmartScraperMultiGraph), search-engine (SearchGraph), depth-recursive (DepthSearchGraph), CSV/JSON/XML (CSVScraperGraph, JSONScraperGraph, XMLScraperGraph), screenshot (ScreenshotScraperGraph), image-to-text (OmniScraperGraph), speech output (SpeechGraph), and code-generation (ScriptCreatorGraph). Config is a plain dict with llm, headless, verbose, etc.
Graph builder. The builders/graph_builder.py provides GraphBuilder for constructing custom pipelines from YAML configs without writing Python code.
Burr integration. The integrations/burr_bridge.py allows executing graphs via the Burr orchestration framework when burr_kwargs is passed in config, providing state-persistence and replay capabilities.
CLI. There is no dedicated CLI entry point in pyproject.toml or setup files. The library is used programmatically. However, the integrations include a scrapegraph_py_compat module that proxies SmartScraperGraph to the cloud ScrapeGraphAI service when llm_model == "scrapegraphai/smart-scraper".
Output formats. Results are Python dicts (JSON). The utils/data_export.py supports CSV/JSON export. utils/save_audio_from_bytes.py handles audio output for speech graphs. utils/save_code_to_file.py saves generated scraping scripts.
Language bindings. Python only. The pyproject.toml requires Python ≥3.12. No REST service, MCP server, or UI is included in the open-source repository. The scrapegraph-py SDK dependency (≥2.0.0) connects to https://scrapegraphai.com cloud API when configured, but the open-source code runs locally via LangChain and Playwright.
Error reporting. The execution info dict returned by BaseGraph includes per-node token counts, execution time, and cumulative USD cost, accessible via graph.get_execution_info().
browserless/browserless
answeredThe developer interface is a self-hosted Docker service with multiple access patterns. WebSocket protocol — clients connect with standard Puppeteer (puppeteer-core) at ws://host/ or Playwright at ws://host/{browser}/playwright, and the server proxies traffic to a real browser process (src/shared/chromium.ws.ts:18-35; src/routes/chromium/ws/playwright.ts). REST APIs — seven POST endpoints (/content, /scrape, /screenshot, /pdf, /function, /download, /performance) plus management GET endpoints (/sessions, /config, /pressure, /metrics, /active, /kill), all JSON-validated via AJV on schema derived from TypeScript interfaces (src/server.ts:340-384). Output formats: HTML, JSON, PDF binary, PNG/JPEG binary, or any content type returned from custom Puppeteer functions. OpenAPI docs at /docs and the Debug Viewer at /debugger for inspecting live sessions (src/config.ts:263-264). Authentication is token-based (TOKEN env var), optionally strict-mode requiring it on every route (src/config.ts:250-251). CLI entry at bin/browserless.js (packaged as browserless binary). SDK extension via @browserless.io/browserless allows overriding config, hooks, limiter, metrics, and routes; the Browserless class accepts injected modules in its constructor (src/browserless.ts:83-138). CORS is configurable for cross-origin requests (src/config.ts:268-283, 895-911). The MCP Server mentioned in the README is not part of the open-source code — it is a cloud-only integration.
crawlab-team/crawlab
answeredCrawlab offers several interfaces. CLI: crawlab server (or crawlab s) starts the node service — master or worker determined by config (core/cmd/server.go:8-24). The root command has a -c flag for a custom config file (core/cmd/root.go:27). REST API: A Gin web server on port 8000 (core/apps/api_v2.go:46-73) exposes CRUD endpoints for spiders, tasks, schedules, projects, nodes, data collections, users, results, settings, and stats — all defined in core/controllers/router_v2.go:54-373. Login/auth via /login and /logout with JWT middleware (core/middlewares/auth.go). Web UI: A Vue.js frontend (frontend/src/main.ts) imports the crawlab-ui library (version 0.6.3) providing the full UI with Element Plus components, served by nginx on port 8080 (nginx/crawlab.conf:1-18). Export: Results can be exported as CSV or JSON (core/controllers/export_v2.go:12-27). gRPC: Internal protocol between master and worker nodes for task fetching, log streaming, and data transfer. Data sources: Results can be stored in MongoDB (default), MySQL, PostgreSQL, and others via the DatabaseV2 model (core/models/models/v2/database_v2.go:7-48) which supports Mongo, Postgres, Snowflake, Cassandra, Hive, and Redis connection parameters. Language bindings: None — spiders are arbitrary executables in any language, run as OS subprocesses.
edition is Pro, and the core/ds drivers are not imported anywhere at this SHA.mixmark-io/turndown
answeredTurndown exposes a library API only — there is no CLI binary (no bin entry in package.json), no REST service, no MCP server, and no user-facing UI beyond an HTML demo page (index.html). The public interface is the TurndownService class, instantiated via new TurndownService(options) or the factory shorthand TurndownService(options) (src/turndown.js:8-10). The primary method is turndown(input) which accepts either an HTML string or a DOM node and returns a Markdown string (src/turndown.js:47-58). Customization happens through addRule(key, rule) for adding conversion rules, keep(filter) to preserve elements as HTML, remove(filter) to strip elements, use(plugin) for plugin-based extensions, and escape(string) for escaping Markdown syntax (src/turndown.js:68-129). Options are set at construction time and include heading style, HR marker, list bullet, code block style, fence character, emphasis/strong delimiters, link style, and reference style (src/turndown.js:11-22). The library ships as multiple build formats (CJS, ES module, UMD, IIFE) for broad compatibility, and a browser-specific variant replaces the domino DOM parser with the native browser DOM (package.json:6-14). The only output format is Markdown text. Language bindings are JavaScript-only — there are no Python, Rust, or other language ports in this repository.
ssssssss-team/spider-flow
answeredThe primary interface is a browser-based visual flow editor using mxGraph (a JavaScript diagramming library) for drag-and-drop DAG construction. The editor (editor.html) provides a toolbar for save, test, debug (step-through with WebSocket), undo/redo, and XML editing. Each shape node gets a context panel where users configure request URLs, headers, extraction rules (CodeMirror-based expression editors with auto-complete), and output mappings. The REST API is exposed through several Spring controllers: SpiderRestController (/rest/run/{id} for synchronous execution returning JSON outputs; /rest/runAsync/{id} for async with a task ID; /rest/stop/{taskId}; /rest/status/{taskId}). SpiderFlowController (/spider/) manages CRUD for flow definitions (list, save, get, remove, copy, start/stop cron, log download/view, list shapes/grammars/plugin configs). TaskController (/task/) manages execution history and task stopping. DataSourceController (/datasource/) manages JDBC data source connections. A WebSocket endpoint (/ws) enables real-time flow testing and step-by-step debugging (WebSocketEditorServer.java). The output formats are: (1) JSON returned from the REST sync endpoint as SpiderOutput[] (name/value pairs per node), (2) database tables via the OutputExecutor's JDBC output, (3) CSV files written to disk. Configuration is via application.properties (workspace path, thread limits, Bloom filter settings, mail, DB credentials). The frontend (separate repo spider-flow-vue) uses LayUI. The base URL is from the Gitee-hosted repository. Language bindings: Java only; no Python, Node.js, or SDK bindings exist.
alirezamika/autoscraper
answeredAutoScraper exposes a pure Python library API only. The single entry point is the AutoScraper class imported from autoscraper.auto_scraper (auto_scraper.py:21). Key methods: build() learns rules from a URL/HTML and wanted_list; get_result_similar() applies rules broadly to extract siblings; get_result_exact() applies index-position-based rules for precise ordering; get_result() returns both; save()/load() persist/restore rules as JSON (auto_scraper.py:53-92); remove_rules()/keep_rules()/set_rule_aliases() manage the rule set (auto_scraper.py:673-721). There is no CLI tool, no REST service, no MCP server, and no graphical UI. Output formats are plain Python lists (or dicts when grouped=True or group_by_alias=True). There is only one language binding (Python). The generate_python_code() method at auto_scraper.py:723-725 is deprecated and prints a message directing users to save() and load() instead.
adithya-s-k/omniparse
answeredOmniParse exposes four interfaces. (1) REST API — a FastAPI server (server.py) with four routers: /parse_document (PDF, PPT, DOCX via marker-pdf), /parse_image (image parsing and vision-task processing via Florence-2), /parse_media (audio/video transcription via Whisper), and /parse_website (URL parsing via Selenium). All endpoints return a responseDocument JSON (omniparse/models/__init__.py:15) containing text (markdown string), images (list of base64-encoded images), metadata (dict), and chunks (list of text chunks). (2) Python SDK client — python-sdk/omniparse_client/omniparse.py provides both a synchronous OmniParse class and an AsyncOmniParse class with methods like parse_document(), parse_pdf(), parse_image(), parse_website(), and process_image(). The async client uses httpx and aiofiles. The SDK outputs a ParsedDocument (utils.py:77) with optional file-saving to disk. (3) Gradio UI — omniparse/demo.py defines a multi-tab Gradio interface (Documents, Images/Parse/Process, Media, Web) that sends requests to the local FastAPI server and renders markdown, extracted images, and JSON output. (4) CLI — the server is launched via python server.py --host 0.0.0.0 --port 8000 --documents --media --web, with flags to selectively load models. There is no MCP server, no JavaScript bindings (the demo shows "Coming soon" for Python and JS code snippets), and no native TypeScript client. Output is always a responseDocument JSON with markdown text, optional images as base64, and metadata.
mishushakov/llm-scraper
answeredThe developer interface is a single TypeScript library published as the llm-scraper npm package (package.json:2). There is no CLI, no REST service, no MCP server, and no UI — only the programmatic API. The export is a default class LLMScraper (src/index.ts:24-56) with three methods:
run(page, output, options?)→{ data, url }— synchronous extraction.options.formatselects the preprocessing mode:'html'(default, cleaned),'raw_html','markdown','text'(Readability.js),'image'(base64 screenshot), or'custom'(user function).optionsalso supports any Vercel AI SDKCallSettings— temperature, maxTokens, etc.stream(page, output, options?)→{ stream, url }— same asrunbut returns apartialOutputStreamthe caller iterates withfor awaitfor incremental results.generate(page, output, options?)→{ code, url }— asks the LLM to write a JavaScript IIFE that extracts data according to the schema; the user then runs it withpage.evaluate(code).
Output formats are structured JSON via LLM (typed by the schema). Schema definitions support both Zod (z.object(...)) and raw JSON Schema (Vercel AI SDK's jsonSchema() helper). The library is TypeScript-only — no other language bindings. All examples use a run() → inspect result pattern, and the tool-use example (toolUse.ts:15-48) shows embedding the scraper inside a Vercel AI SDK tool() for agentic workflows — it calls scraper.run() inside the tool's execute handler.
adbar/trafilatura
answeredLibrary API, CLI — no REST service, MCP server, or web UI.
Python API (exposed in __init__.py:15-32):
fetch_url(url)→ downloads a page and returns a decoded string.extract(html, ...)→ the main extraction function, returns a string in the chosen format.extract_with_metadata(...)→ returns aDocumentobject containing both text and metadata.bare_extraction(...)→ returns aDocumentwith the lxml body tree (unsafe for serialization).fetch_response(url)→ returns the rawResponseobject.- All functions accept 20+ keyword arguments for fine-grained control (output format, language filtering, deduplication, precision/recall, formatting, images, links, tables, comments, pruning XPath, custom config).
CLI (cli.py:49-168): Invoked as trafilatura (registered in pyproject.toml:83). Input options: --input-file, --input-dir, --URL, stdin. Navigation options: --feed, --sitemap, --crawl, --explore, --probe. Extraction options: --fast, --precision, --recall, --with-metadata, --target-language, --deduplicate. Parallel processing via --parallel.
Output formats (settings.py:29): txt (plain text with optional YAML metadata header), markdown, csv, json, html, xml, xmltei (TEI-conformant XML).
Configuration: A settings.cfg file (settings.py:41-49) controls defaults for download timeout, file sizes, sleep time, user agents, SSRF protection, date search, and extraction thresholds. Users can supply overrides via --config-file or a ConfigParser object in the API.
There is no REST web service, no MCP server integration, no graphical user interface. Language bindings are Python-only.
itsOwen/CyberScraper-2077
answeredThe primary interface is a Streamlit web application launched via streamlit run main.py. The main.py file (line 420) constructs a chat-based UI with a sidebar for model selection (GPT, Gemini, LiteLLM, Ollama), service-status indicators, and chat-history management grouped by date. Users enter prompts that can be URLs to scrape or conversational queries about already-fetched content — extraction results are displayed as pandas DataFrames with download buttons for CSV/Excel and a 'Upload to Google Sheets' option. The Python library API centers on WebExtractor in src/web_extractor.py (line 71), which accepts a model name and optional ScraperConfig/TorConfig, then exposes process_query() for single-call scrape-and-extract. Lower-level: PlaywrightScraper (line 76 of playwright_scraper.py) for browser automation, TorScraper for onion sites, Models.get_model() in src/models.py for LLM instantiation. The StreamlitWebScraperChat class in app/streamlit_web_scraper_chat.py wraps WebExtractor and bridges Streamlit's synchronous event loop with the async pipeline via asyncio.run() (line 23). Output formats include JSON (markdown code blocks), CSV (in-UI DataFrame + download), Excel (via xlsxwriter bytes buffer), SQL (INSERT statements), and HTML tables — selected by user keywords in the query. There is no CLI interface (no argparse/click entry point), no REST service, no MCP server, and no HTTP API — the only invocation is streamlit run main.py. Language bindings: Python only. The Dockerfile (line 1 of Dockerfile) provides containerized deployment exposing ports 8501 (Streamlit UI), 9050 (Tor SOCKS5), and 9051 (Tor control), with an entrypoint that starts Tor and then launches the Streamlit app.
raznem/parsera
answeredThe primary interface is the Python library API via the Parsera class (parsera/parsera.py:13-115). Instantiate with optional model (LangChain chat model), extractor, initial_script (Playwright callback), stealth (bool), and custom_cookies. Call .run(url, elements, prompt, ...) for synchronous usage (wraps asyncio.run()) or .arun(...) for async. The result is a list[dict] (for tabular extractors) or dict (for Item/List extractors). A CLI is provided via python -m parsera.main (main.py:56-181), accepting a URL, --scheme (JSON string of field definitions), --file (JSON file with same), --scrolls (int), and --output (file path, default "output.json"). The CLI uses GPT4oMiniModel by default and requires OPENAI_API_KEY or PARSERA_API_KEY in the environment. A Docker entrypoint is configured (Dockerfile:42) that runs the CLI with environment variables for URL, FILE, and OUTPUT. There is no REST API service served by the project (the APIExtractor is a client to a hosted API at api.parsera.org, not a server). There is no MCP server, no web UI, and no graphical interface. Output formats are limited to Python dicts (in-code) and JSON files (CLI). Language bindings are Python-only. The project exposes no language-agnostic protocol.
GPT4oMiniModel (parsera/main.py L121-L135), so it needs OPENAI_API_KEY; a PARSERA_API_KEY alone does not make the CLI work.vinyzu-archive/Botright
answeredBotright has a single interface: an asynchronous Python library. There is no CLI, REST service, MCP server, or graphical UI.
Library API — The developer imports botright and uses the async context manager pattern:
botright_client = await botright.Botright(headless=False, block_images=True, cache_responses=False, ...)
browser = await botright_client.new_browser(proxy="user:pass@ip:port")
page = await browser.new_page()
await page.goto("https://example.com")
await page.solve_hcaptcha() # custom method
await botright_client.close()
The Botright class (botright/botright.py:27) accepts config flags (headless, block_images, cache_responses, user_action_layer, scroll_into_view, spoof_canvas, mask_fingerprint, use_undetected_playwright). new_browser() (botright/botright.py:134) takes an optional proxy string plus any Playwright launch arguments, and returns a BrowserContext (browser.py:118).
Playwright-compatible wrappers — Every standard Playwright class is wrapped with Botright's overrides: Page, BrowserContext, Locator, ElementHandle, Frame, FrameLocator, Mouse, Keyboard, Request, Response, Route (re-exported from botright/playwright_mock/__init__.py:1-12). Users can write existing Playwright code by only changing the initialization.
Extra Page methods — solve_hcaptcha(), get_hcaptcha(), solve_recaptcha(), solve_geetest() are injected directly onto the Page class (page.py:212-260).
Output formats — None built in. Content is extracted via standard Playwright methods (HTML string via page.content(), text via locator access, screenshots via page.screenshot()).
Language bindings — Python 3.8+ only. Installed via pip install botright then playwright install chromium. Dependencies include Playwright, hcaptcha_challenger, chrome-fingerprints, and recognizer (for reCaptcha).
ttlns/Selenium-Driverless
answeredThe developer interface is exclusively a Python library — there is no CLI, no REST API, no MCP server, and no graphical UI. Two entry points serve usage preferences. Async API: from selenium_driverless import webdriver — a conventional asyncio-based async with pattern (src/selenium_driverless/webdriver.py:63-65). Sync API: from selenium_driverless.sync import webdriver (src/selenium_driverless/sync/webdriver.py:8-40) — the synchronous version runs an internal event loop and wraps every coroutine via loop.run_until_complete, so methods like driver.get() and driver.find_element() can be called without await. The API mirrors Selenium's naming conventions: chrome.get(), chrome.find_element(By, value), chrome.page_source, chrome.current_url, etc. Context management — the library adds new_context() (incognito contexts with isolated cookies/storage) and switch_to for multi-tab workflows. Network interception — the NetworkInterceptor context manager (src/selenium_driverless/scripts/network_interceptor.py:629-800) provides on_request, on_response, and on_auth callbacks with methods to continue_request, fulfill, fail_request, and bypass_browser (re-fetch from Python). It also supports async for iteration over intercepted requests. Output formats — content is returned as Python dicts or WebElement objects. No JSON Lines, no file dumps, no streaming output. Page source is raw HTML (string). Screenshots are PNG (bytes). PDFs are base64 strings. Snapshots are MHTML (string). Language bindings — Python only.
scraperai/scraperai
answeredThe project provides two main developer interfaces and a serializable config format.
Python Library API — the primary interface. Users import Scraper, ParserAI, SeleniumCrawler, and model classes (scraperai/__init__.py:1-4). The typical flow: create a SeleniumCrawler, instantiate ParserAI(openai_api_key=...), call detect_page_type(), detect_pagination(), detect_catalog_item(), extract_fields(), assemble a ScraperConfig, and pass it with the crawler to Scraper(config, crawler). The scraper exposes a generator-based scrape() method. This is shown in detail in examples/ycombinator_full.ipynb.
CLI — built with Click (scraperai/cli/app.py), entry point scraperai (via console_scripts in setup.py:28-30). Run scraperai --url <url>. It drives the same library classes through a step-by-step interactive wizard (Controller in scraperai/cli/controller.py:21-334): checks for cached configs, auto-detects page type/pagination/catalog items/fields, lets the user edit each detection, then scrapes and exports. The View class (scraperai/cli/view.py:11-204) handles all terminal I/O with Click prompts and pandas-based markdown tables for field display.
ScraperConfig serialization (scraperai/models.py:74-83) — the full scraping configuration (URL, page type, pagination settings, catalog item XPaths, field definitions, limits) is a Pydantic model that dumps to JSON. Configs are saved as .scraperai.json files in the user's app data directory (scraperai/cli/utils.py:9) and are loaded on subsequent runs to skip re-detection (controller.py:42-51).
No REST service, no MCP server, no web UI. The README roadmap lists "Release SaaS web app" as a future goal. No REST API — the library is consumed in-process only. Language bindings: Python only (package on PyPI). Output formats are JSON, XLSX, and CSV.