# DeepCrawl AI — Universal Website to Markdown Crawler Pro (`meanusarcanus/deep-markdown-crawler-api`) Actor

Crawl entire websites, sitemaps, and documentation hubs into clean, LLM-ready Markdown with zero ads, cookie banners, navbars, or clutter. Built for RAG pipelines & AI agents!

- **URL**: https://apify.com/meanusarcanus/deep-markdown-crawler-api.md
- **Developed by:** [Meanus Arcanus](https://apify.com/meanusarcanus) (community)
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.49 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## 🤖 DeepCrawl AI — Universal Website to Markdown Crawler Pro (Model Context Protocol Server)

[![MCP Protocol](https://img.shields.io/badge/MCP-Model_Context_Protocol-blue.svg)](https://modelcontextprotocol.io/)
[![Python 3.8+](https://img.shields.io/badge/Python-3.8+-blue.svg)](https://www.python.org/)
[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)
[![Glama](https://img.shields.io/badge/Glama-MCP_Server-purple.svg)](https://glama.ai/mcp/servers)

A high-performance **Model Context Protocol (MCP) Server** and deep domain crawler that turns any website, documentation hub, or sitemap into clean, LLM-ready Markdown for **Claude Desktop, Cursor IDE, LangChain, RAG pipelines, and Autonomous AI Agents**.

<p align="center">
  <img src="https://raw.githubusercontent.com/meanusarcanus/deep-markdown-crawler-api/master/assets/logo.jpg" alt="DeepCrawl AI Logo" width="180" style="border-radius: 20px;" />
</p>

***

### ⚡ Overview

**DeepCrawl AI** is a lightweight, high-speed alternative to Firecrawl and Crawl4AI. It recursively crawls documentation portals (e.g. Stripe, FastAPI, Supabase) and blogs, strips all web noise (ads, cookie banners, tracking scripts, navigation menus), and formats the core content into token-budgeted GitHub-Flavored Markdown.

- 🛡️ **Zero Noise HTML Cleaner**: Strips header/footer boilerplates, cookie banners, popups, and sidebar ads.
- 🌲 **BFS Deep Domain Crawler**: Recursively discovers internal links with strict domain boundary locking.
- 🗺️ **Fast Sitemap & URL Mapper**: Maps all available URLs across an entire domain in seconds.
- 🔌 **Zero-Config MCP Integration**: Plug-and-play with Claude Desktop, Cursor, and Antigravity agents.

***

### 🛠️ MCP Tools & Capabilities

The server exposes the following Model Context Protocol (MCP) tools:

| Tool Name | Parameters | Description |
| :--- | :--- | :--- |
| **`scrape_url_markdown`** | `url` *(string, required)* | Scrapes a single webpage, removes ads/cookie popups, and returns clean GitHub Flavored Markdown with token metrics. |
| **`crawl_domain_markdown`** | `start_url` *(string, required)*, `max_pages` *(int)*, `max_depth` *(int)* | Recursively crawls an entire documentation site or blog up to a depth limit, returning a unified Markdown bundle for RAG. |
| **`map_domain_urls`** | `start_url` *(string, required)*, `max_links` *(int)* | Fast discovery of all internal URLs and sitemap routes across a domain without downloading full page bodies. |

***

### 🔌 Quickstart: Connect to Claude Desktop & Cursor

#### 1. Claude Desktop Configuration

Add this server to your `claude_desktop_config.json`:

- **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
- **Windows**: `%APPDATA%\Claude\claude_desktop_config.json`
- **Linux**: `~/.config/Claude/claude_desktop_config.json`

```json
{
  "mcpServers": {
    "deep-markdown-crawler": {
      "command": "python3",
      "args": [
        "/path/to/deep-markdown-crawler-api/mcp_server.py"
      ]
    }
  }
}
```

#### 2. Cursor IDE Configuration (`.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "deep-markdown-crawler": {
      "command": "python3",
      "args": ["/path/to/deep-markdown-crawler-api/mcp_server.py"]
    }
  }
}
```

***

### 📦 Python SDK & CLI Usage

```bash
pip install deep-markdown-crawler
```

```python
from deep_markdown_crawler import scrape_url_to_markdown, crawl_domain_to_markdown

## 1. Scrape Single URL
doc = scrape_url_to_markdown("https://fastapi.tiangolo.com/tutorial/")
print(f"Title: {doc['title']} | Tokens: ~{doc['token_count']}")
print(doc['markdown'][:500])

## 2. Deep Crawl Entire Domain
crawl = crawl_domain_to_markdown(
    start_url="https://fastapi.tiangolo.com/tutorial/",
    max_pages=5,
    max_depth=2
)
print(f"Crawled {crawl['total_pages_crawled']} pages ({crawl['total_tokens_estimated']} tokens).")
```

***

### 🌐 Serverless REST API Endpoints

| Method | Endpoint | Description |
| :--- | :--- | :--- |
| `POST` | `/api/v1/scrape` | Single URL to clean GitHub-Flavored Markdown. |
| `POST` | `/api/v1/crawl` | Recursive domain crawler for multi-page documentation hubs. |
| `POST` | `/api/v1/map` | Fast domain URL & sitemap mapper. |
| `GET` | `/api/v1/health` | Service health status and supported features. |

***

### 📄 License

MIT License. Created by Meanus Arcanus.

# Actor input Schema

## `start_urls` (type: `array`):

List of URLs or doc portal paths to crawl and convert into clean Markdown.

## `max_pages_per_domain` (type: `integer`):

Maximum number of pages to crawl per domain (1 to 50).

## `max_depth` (type: `integer`):

Link traversal depth (1 to 3).

## Actor input object example

```json
{
  "start_urls": [
    "https://fastapi.tiangolo.com/tutorial/"
  ],
  "max_pages_per_domain": 10,
  "max_depth": 2
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "start_urls": [
        "https://fastapi.tiangolo.com/tutorial/"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("meanusarcanus/deep-markdown-crawler-api").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "start_urls": ["https://fastapi.tiangolo.com/tutorial/"] }

# Run the Actor and wait for it to finish
run = client.actor("meanusarcanus/deep-markdown-crawler-api").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "start_urls": [
    "https://fastapi.tiangolo.com/tutorial/"
  ]
}' |
apify call meanusarcanus/deep-markdown-crawler-api --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,meanusarcanus/deep-markdown-crawler-api"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/HxaJRz1tPBa2HC5ZX/builds/M40RXHGdQdQ8eN4B0/openapi.json
