crw-mcp 0.41.0 → 0.42.1
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/install.js +19 -1
- package/package.json +5 -5
- package/skills/SKILL.md +1 -1
package/bin/install.js
CHANGED
|
@@ -15,7 +15,11 @@ const {
|
|
|
15
15
|
home,
|
|
16
16
|
} = require("./agents.js");
|
|
17
17
|
|
|
18
|
-
|
|
18
|
+
// `--api-key=value` and `--api-key value` mean the same thing.
|
|
19
|
+
const args = process.argv.slice(2).flatMap((a) => {
|
|
20
|
+
const m = /^(--api-key|--api-url)=(.*)$/.exec(a);
|
|
21
|
+
return m ? [m[1], m[2]] : [a];
|
|
22
|
+
});
|
|
19
23
|
|
|
20
24
|
function argValue(flag) {
|
|
21
25
|
const i = args.indexOf(flag);
|
|
@@ -45,6 +49,20 @@ registers the "crw" MCP server. Run \`crw-mcp init\` for the skill only.
|
|
|
45
49
|
process.exit(0);
|
|
46
50
|
}
|
|
47
51
|
|
|
52
|
+
// Anything unrecognised stops here: ignoring it would turn a typo, or a flag
|
|
53
|
+
// this command does not have (such as --dry-run), into a real install.
|
|
54
|
+
const VALUE_FLAGS = ["--api-key", "--api-url"];
|
|
55
|
+
const KNOWN_FLAGS = ["--all", "--from-config", ...AGENTS.map((a) => a.flag)];
|
|
56
|
+
for (let i = 0; i < args.length; i++) {
|
|
57
|
+
if (VALUE_FLAGS.includes(args[i])) {
|
|
58
|
+
i++;
|
|
59
|
+
} else if (!KNOWN_FLAGS.includes(args[i])) {
|
|
60
|
+
console.error(`crw-mcp install: unknown argument "${args[i]}". Nothing was installed.`);
|
|
61
|
+
console.error("Run `npx crw-mcp@latest install --help` to see the options.");
|
|
62
|
+
process.exit(2);
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
48
66
|
const fromConfig = args.includes("--from-config");
|
|
49
67
|
const apiKey = fromConfig ? null : getApiKey(args);
|
|
50
68
|
const apiUrl = argValue("--api-url") || (apiKey ? "https://api.fastcrw.com" : null);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "crw-mcp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.42.1",
|
|
4
4
|
"description": "MCP server for CRW web scraper — scrape, crawl, map, extract, search, and PDF-parse tools for AI agents",
|
|
5
5
|
"license": "AGPL-3.0",
|
|
6
6
|
"author": "fastCRW <hello@fastcrw.com>",
|
|
@@ -38,9 +38,9 @@
|
|
|
38
38
|
"skills/SKILL.md"
|
|
39
39
|
],
|
|
40
40
|
"optionalDependencies": {
|
|
41
|
-
"crw-mcp-darwin-x64": "0.
|
|
42
|
-
"crw-mcp-darwin-arm64": "0.
|
|
43
|
-
"crw-mcp-linux-x64": "0.
|
|
44
|
-
"crw-mcp-linux-arm64": "0.
|
|
41
|
+
"crw-mcp-darwin-x64": "0.42.1",
|
|
42
|
+
"crw-mcp-darwin-arm64": "0.42.1",
|
|
43
|
+
"crw-mcp-linux-x64": "0.42.1",
|
|
44
|
+
"crw-mcp-linux-arm64": "0.42.1"
|
|
45
45
|
}
|
|
46
46
|
}
|
package/skills/SKILL.md
CHANGED
|
@@ -45,7 +45,7 @@ Scrape a single URL and return clean content.
|
|
|
45
45
|
|
|
46
46
|
Parameters:
|
|
47
47
|
- `url` (required) — The URL to scrape
|
|
48
|
-
- `formats` — Output formats: `markdown` (default), `html`, `links`, `images`
|
|
48
|
+
- `formats` — Output formats: `markdown` (default), `html`, `plainText`, `links`, `images`
|
|
49
49
|
- `onlyMainContent` — Strip navs/footers/sidebars. Default: `true`
|
|
50
50
|
- `includeTags` — Only include content matching these CSS selectors (e.g. `["article", "main"]`)
|
|
51
51
|
- `excludeTags` — Exclude content matching these CSS selectors (e.g. `["nav", "footer"]`)
|