crw-mcp 0.15.2 → 0.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/init.js +1 -1
- package/package.json +6 -6
- package/skills/SKILL.md +52 -14
package/bin/init.js
CHANGED
|
@@ -124,7 +124,7 @@ Without flags, auto-detects installed agents and installs to all of them.
|
|
|
124
124
|
} else {
|
|
125
125
|
console.log("\nCloud mode (fastcrw.com):");
|
|
126
126
|
console.log(" 500 free one-time credits, managed infra — https://fastcrw.com");
|
|
127
|
-
console.log(" export CRW_API_KEY=
|
|
127
|
+
console.log(" export CRW_API_KEY=crw_live_xxx");
|
|
128
128
|
console.log(" export CRW_API_URL=https://api.fastcrw.com");
|
|
129
129
|
console.log(" Terms of Service: https://fastcrw.com/terms");
|
|
130
130
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "crw-mcp",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "MCP server for CRW web scraper — scrape, crawl, and
|
|
3
|
+
"version": "0.17.0",
|
|
4
|
+
"description": "MCP server for CRW web scraper — scrape, crawl, map, search, and PDF-parse tools for AI agents",
|
|
5
5
|
"license": "AGPL-3.0",
|
|
6
6
|
"homepage": "https://github.com/us/crw",
|
|
7
7
|
"repository": {
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
"skills/SKILL.md"
|
|
31
31
|
],
|
|
32
32
|
"optionalDependencies": {
|
|
33
|
-
"crw-mcp-darwin-x64": "0.
|
|
34
|
-
"crw-mcp-darwin-arm64": "0.
|
|
35
|
-
"crw-mcp-linux-x64": "0.
|
|
36
|
-
"crw-mcp-linux-arm64": "0.
|
|
33
|
+
"crw-mcp-darwin-x64": "0.17.0",
|
|
34
|
+
"crw-mcp-darwin-arm64": "0.17.0",
|
|
35
|
+
"crw-mcp-linux-x64": "0.17.0",
|
|
36
|
+
"crw-mcp-linux-arm64": "0.17.0"
|
|
37
37
|
}
|
|
38
38
|
}
|
package/skills/SKILL.md
CHANGED
|
@@ -32,23 +32,26 @@ This installs the CRW skill and MCP server to all detected AI agents (Claude Cod
|
|
|
32
32
|
## Authentication
|
|
33
33
|
|
|
34
34
|
- **Embedded mode** (default): No key needed — the MCP server runs a self-contained scraper in ~6 MB RAM. No server required.
|
|
35
|
-
- **Cloud mode** (fastcrw.com): Set `CRW_API_KEY=crw_live_...` and `CRW_API_URL=https://fastcrw.com
|
|
35
|
+
- **Cloud mode** (fastcrw.com): Set `CRW_API_KEY=crw_live_...` and `CRW_API_URL=https://api.fastcrw.com`. Get a free key at https://fastcrw.com with 500 one-time lifetime credits (never resets, not monthly).
|
|
36
36
|
|
|
37
37
|
## MCP Tools
|
|
38
38
|
|
|
39
|
+
> **Output bounds:** By default, content is truncated to ~15 000 chars (`crw_scrape`, `crw_check_crawl_status`, `crw_parse_file`) and `crw_map` returns ≤ 100 URLs. Truncated results carry a `truncated: true` marker (`crw_map` also adds `totalDiscovered`). Pass `maxLength: 0` or `limit: 0` to opt out of bounding.
|
|
40
|
+
|
|
39
41
|
### crw_scrape
|
|
40
42
|
|
|
41
43
|
Scrape a single URL and return clean content.
|
|
42
44
|
|
|
43
45
|
Parameters:
|
|
44
46
|
- `url` (required) — The URL to scrape
|
|
45
|
-
- `formats` — Output formats: `markdown` (default), `html`, `
|
|
47
|
+
- `formats` — Output formats: `markdown` (default), `html`, `links`
|
|
46
48
|
- `onlyMainContent` — Strip navs/footers/sidebars. Default: `true`
|
|
49
|
+
- `includeTags` — Only include content matching these CSS selectors (e.g. `["article", "main"]`)
|
|
50
|
+
- `excludeTags` — Exclude content matching these CSS selectors (e.g. `["nav", "footer"]`)
|
|
47
51
|
- `renderJs` — Force JavaScript rendering. Default: auto-detect (null)
|
|
48
|
-
- `
|
|
49
|
-
- `
|
|
50
|
-
- `
|
|
51
|
-
- `excludeTags` — Remove these HTML tags (e.g. `["nav", "footer"]`)
|
|
52
|
+
- `waitFor` — Milliseconds to wait after page load before capturing
|
|
53
|
+
- `renderer` — Renderer override (e.g. `"playwright"`)
|
|
54
|
+
- `maxLength` — Truncate output to this many chars. `0` = unbounded. Default: ~15 000
|
|
52
55
|
|
|
53
56
|
### crw_crawl
|
|
54
57
|
|
|
@@ -56,8 +59,12 @@ Start an async BFS crawl from a URL. Returns a job ID — poll with `crw_check_c
|
|
|
56
59
|
|
|
57
60
|
Parameters:
|
|
58
61
|
- `url` (required) — Starting URL
|
|
59
|
-
- `maxDepth` — Maximum link depth. Default: `2
|
|
60
|
-
- `
|
|
62
|
+
- `maxDepth` — Maximum link depth. Default: `2`
|
|
63
|
+
- `maxPages` — Maximum pages to crawl
|
|
64
|
+
- `jsonSchema` — JSON schema for structured extraction per page
|
|
65
|
+
- `renderJs` — Force JavaScript rendering
|
|
66
|
+
- `waitFor` — Milliseconds to wait after page load before capturing
|
|
67
|
+
- `renderer` — Renderer override
|
|
61
68
|
|
|
62
69
|
Returns: `{ "id": "job-uuid" }` — use this ID with crw_check_crawl_status.
|
|
63
70
|
|
|
@@ -67,18 +74,23 @@ Poll an async crawl job for results.
|
|
|
67
74
|
|
|
68
75
|
Parameters:
|
|
69
76
|
- `id` (required) — The crawl job ID from `crw_crawl`
|
|
77
|
+
- `maxLength` — Truncate each page's content fields to this many chars. `0` = unbounded. Default: ~15 000
|
|
78
|
+
|
|
79
|
+
Returns: `{ "status": "scraping|completed|failed", "data": [...] }`
|
|
70
80
|
|
|
71
|
-
|
|
81
|
+
> **Browser Automation:** Full interactive browser control (JavaScript rendering, click, fill, etc.) requires the separate **crw-browse** MCP server binary (`command: crw-browse`). It exposes its own tools (`goto`, `tree`, and others) and is not part of this MCP server. Do not call `crw_browse` here — it is not a tool in crw-mcp and will return a JSON-RPC -32602 "Unknown tool" error.
|
|
72
82
|
|
|
73
83
|
### crw_search
|
|
74
84
|
|
|
75
|
-
Search the web and return relevant results with titles, URLs, and descriptions.
|
|
85
|
+
Search the web and return relevant results with titles, URLs, and descriptions. Always available in proxy/cloud mode; in embedded mode only when a SearXNG backend is configured.
|
|
76
86
|
|
|
77
87
|
Parameters:
|
|
78
88
|
- `query` (required) — The search query
|
|
79
89
|
- `limit` — Maximum number of results to return. Default: `5`
|
|
80
90
|
- `lang` — Language code for results (e.g. `"en"`, `"tr"`)
|
|
81
|
-
- `
|
|
91
|
+
- `tbs` — Time filter: `qdr:h|qdr:d|qdr:w|qdr:m|qdr:y` (past hour/day/week/month/year)
|
|
92
|
+
- `sources` — If set, group results by source: `web`, `news`, `images`
|
|
93
|
+
- `categories` — Bias toward a category (e.g. `"pdf"`, `"github"`, `"research"`, or a native SearXNG category)
|
|
82
94
|
- `scrapeOptions` — Options for scraping each result page (e.g. `{"formats": ["markdown"]}`)
|
|
83
95
|
|
|
84
96
|
### crw_map
|
|
@@ -89,8 +101,22 @@ Parameters:
|
|
|
89
101
|
- `url` (required) — The URL to map
|
|
90
102
|
- `maxDepth` — Discovery depth. Default: `2`
|
|
91
103
|
- `useSitemap` — Check sitemap.xml. Default: `true`
|
|
104
|
+
- `crawlFallback` — Supplement sitemap discovery with a short BFS crawl. Default: `true` (`false` = sitemap-only)
|
|
105
|
+
- `limit` — Maximum URLs to return. `0` = unbounded. Default: `100`
|
|
106
|
+
|
|
107
|
+
Returns: `{ "links": ["url1", "url2", ...] }`
|
|
92
108
|
|
|
93
|
-
|
|
109
|
+
### crw_parse_file
|
|
110
|
+
|
|
111
|
+
Parse a local file (PDF) into markdown or structured output without fetching from the web.
|
|
112
|
+
|
|
113
|
+
Parameters:
|
|
114
|
+
- `contentBase64` (required) — Base64-encoded file contents
|
|
115
|
+
- `filename` — Original filename (optional, e.g. `"report.pdf"`)
|
|
116
|
+
- `formats` — Output formats: `markdown` (default), `plainText`, `links`, `json`, `summary` (json/summary need a server LLM)
|
|
117
|
+
- `jsonSchema` — JSON schema for LLM extraction (when `formats` includes `json`)
|
|
118
|
+
- `parsers` — Document parsers to apply. Default: `["pdf"]`
|
|
119
|
+
- `maxLength` — Truncate output to this many chars. `0` = unbounded. Default: ~15 000
|
|
94
120
|
|
|
95
121
|
## Common Patterns
|
|
96
122
|
|
|
@@ -103,7 +129,7 @@ crw_scrape(url="https://example.com", formats=["markdown"])
|
|
|
103
129
|
First discover URLs, then crawl:
|
|
104
130
|
```
|
|
105
131
|
crw_map(url="https://docs.example.com") → get URL list
|
|
106
|
-
crw_crawl(url="https://docs.example.com",
|
|
132
|
+
crw_crawl(url="https://docs.example.com", maxPages=50) → extract all content
|
|
107
133
|
crw_check_crawl_status(id="...") → poll until completed
|
|
108
134
|
```
|
|
109
135
|
|
|
@@ -112,6 +138,18 @@ crw_check_crawl_status(id="...") → poll until completed
|
|
|
112
138
|
crw_search(query="your search query", limit=5)
|
|
113
139
|
```
|
|
114
140
|
|
|
141
|
+
**Search from the CLI (one-shot LLM-ready output):**
|
|
142
|
+
|
|
143
|
+
When the `crw` binary is available, prefer the native field projection
|
|
144
|
+
over piping through `jq` — it's one call instead of two:
|
|
145
|
+
|
|
146
|
+
```bash
|
|
147
|
+
crw search "renewable energy 2024" --json --fields title,url,snippet --limit 3
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
Available fields: `title`, `url`, `description`, `snippet`, `position`,
|
|
151
|
+
`score`, `category`. `--json` is shorthand for `--format json`.
|
|
152
|
+
|
|
115
153
|
## Common Edge Cases
|
|
116
154
|
|
|
117
155
|
- **JavaScript-heavy sites**: Set `renderJs: true` if the page is blank or returns a loading skeleton
|
|
@@ -121,7 +159,7 @@ crw_search(query="your search query", limit=5)
|
|
|
121
159
|
|
|
122
160
|
## Links
|
|
123
161
|
|
|
124
|
-
- Cloud API: https://fastcrw.com — 500 free credits
|
|
162
|
+
- Cloud API: https://fastcrw.com — 500 one-time lifetime free credits (never resets, not monthly)
|
|
125
163
|
- Docs: https://docs.fastcrw.com
|
|
126
164
|
- GitHub: https://github.com/us/crw
|
|
127
165
|
- Firecrawl-compatible: same REST endpoints at `/v1/scrape`, `/v1/crawl`, `/v1/map`, `/v1/search`
|