@bsbofmusic/agent-reach-mcp 0.4.0 → 0.4.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/index.js +21 -26
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -540,8 +540,11 @@ async function main() {
|
|
|
540
540
|
isError: true,
|
|
541
541
|
};
|
|
542
542
|
}
|
|
543
|
-
|
|
544
|
-
|
|
543
|
+
// Agent-Reach doesn't have a 'read' command - it uses upstream tools
|
|
544
|
+
// We'll use Jina Reader via curl
|
|
545
|
+
const jinaUrl = `https://r.jina.ai/${url}`;
|
|
546
|
+
const { out, code } = await run("curl", ["-s", jinaUrl], {
|
|
547
|
+
timeoutMs: 60 * 1000,
|
|
545
548
|
});
|
|
546
549
|
return { content: text(out), isError: code !== 0 };
|
|
547
550
|
}
|
|
@@ -549,48 +552,40 @@ async function main() {
|
|
|
549
552
|
if (name === "reach_search_twitter") {
|
|
550
553
|
const query = String(input.query ?? "");
|
|
551
554
|
const limit = Number(input.limit ?? 10);
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
String(limit),
|
|
557
|
-
]);
|
|
555
|
+
// Twitter search via bird CLI - need to install via reach_install first
|
|
556
|
+
const { out, code } = await run("bird", ["search", query, "-n", String(limit)], {
|
|
557
|
+
timeoutMs: 60 * 1000,
|
|
558
|
+
});
|
|
558
559
|
return { content: text(out), isError: code !== 0 };
|
|
559
560
|
}
|
|
560
561
|
|
|
561
562
|
if (name === "reach_search_xhs") {
|
|
562
563
|
const query = String(input.query ?? "");
|
|
563
564
|
const limit = Number(input.limit ?? 10);
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
String(limit),
|
|
569
|
-
]);
|
|
565
|
+
// XiaoHongShu search via mcporter - need docker xiaohongshu-mcp running
|
|
566
|
+
const { out, code } = await run("mcporter", ["call", "xiaohongshu.search_feeds", `{"keyword": "${query}", "limit": ${limit}}`], {
|
|
567
|
+
timeoutMs: 60 * 1000,
|
|
568
|
+
});
|
|
570
569
|
return { content: text(out), isError: code !== 0 };
|
|
571
570
|
}
|
|
572
571
|
|
|
573
572
|
if (name === "reach_search_web") {
|
|
574
573
|
const query = String(input.query ?? "");
|
|
575
574
|
const limit = Number(input.limit ?? 10);
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
String(limit),
|
|
581
|
-
]);
|
|
575
|
+
// Web search via Exa MCP - need mcporter configured with Exa
|
|
576
|
+
const { out, code } = await run("mcporter", ["call", "exa.search", `{"query": "${query}", "limit": ${limit}}`], {
|
|
577
|
+
timeoutMs: 60 * 1000,
|
|
578
|
+
});
|
|
582
579
|
return { content: text(out), isError: code !== 0 };
|
|
583
580
|
}
|
|
584
581
|
|
|
585
582
|
if (name === "reach_search_github") {
|
|
586
583
|
const query = String(input.query ?? "");
|
|
587
584
|
const limit = Number(input.limit ?? 10);
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
String(limit),
|
|
593
|
-
]);
|
|
585
|
+
// GitHub search via gh CLI
|
|
586
|
+
const { out, code } = await run("gh", ["search", "repos", query, "--limit", String(limit), "--json", "name,description,url,stargazerCount"], {
|
|
587
|
+
timeoutMs: 60 * 1000,
|
|
588
|
+
});
|
|
594
589
|
return { content: text(out), isError: code !== 0 };
|
|
595
590
|
}
|
|
596
591
|
|