@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.
Files changed (2) hide show
  1. package/index.js +21 -26
  2. 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
- const { out, code } = await runAgentReach(runtimeRoot, ["read", url], {
544
- timeoutMs: 10 * 60 * 1000,
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
- const { out, code } = await runAgentReach(runtimeRoot, [
553
- "search-twitter",
554
- query,
555
- "-n",
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
- const { out, code } = await runAgentReach(runtimeRoot, [
565
- "search-xhs",
566
- query,
567
- "-n",
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
- const { out, code } = await runAgentReach(runtimeRoot, [
577
- "search-web",
578
- query,
579
- "-n",
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
- const { out, code } = await runAgentReach(runtimeRoot, [
589
- "search-github",
590
- query,
591
- "--limit",
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
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bsbofmusic/agent-reach-mcp",
3
- "version": "0.4.0",
3
+ "version": "0.4.1",
4
4
  "description": "MCP stdio server that auto-installs/updates Agent-Reach and exposes reach_* tools.",
5
5
  "license": "MIT",
6
6
  "type": "module",