hive-intelligence 1.1.2 → 1.1.4

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 (148) hide show
  1. package/LICENSE +12 -10
  2. package/README.md +325 -351
  3. package/agent-skills/.claude-plugin/plugin.json +111 -0
  4. package/agent-skills/.mcp.json +11 -0
  5. package/agent-skills/AGENTS.md +37 -0
  6. package/agent-skills/LICENSE +21 -0
  7. package/agent-skills/README.md +145 -0
  8. package/agent-skills/SKILL.md +80 -0
  9. package/agent-skills/evals/README.md +20 -0
  10. package/agent-skills/evals/trigger-queries.json +464 -0
  11. package/agent-skills/package.json +49 -0
  12. package/agent-skills/packs/hive-build/SKILL.md +328 -0
  13. package/agent-skills/packs/hive-build/evals/evals.json +28 -0
  14. package/agent-skills/packs/hive-build-onboarding/SKILL.md +137 -0
  15. package/agent-skills/packs/hive-build-onboarding/evals/evals.json +27 -0
  16. package/agent-skills/packs/hive-cli/SKILL.md +141 -0
  17. package/agent-skills/packs/hive-cli/evals/evals.json +27 -0
  18. package/agent-skills/packs/hive-defi-research/SKILL.md +42 -0
  19. package/agent-skills/packs/hive-defi-research/evals/evals.json +27 -0
  20. package/agent-skills/packs/hive-defi-research/references/workflow.md +41 -0
  21. package/agent-skills/packs/hive-dex-pool-analysis/SKILL.md +41 -0
  22. package/agent-skills/packs/hive-dex-pool-analysis/evals/evals.json +27 -0
  23. package/agent-skills/packs/hive-dex-pool-analysis/references/workflow.md +42 -0
  24. package/agent-skills/packs/hive-market-research/SKILL.md +45 -0
  25. package/agent-skills/packs/hive-market-research/evals/evals.json +27 -0
  26. package/agent-skills/packs/hive-market-research/references/workflow.md +47 -0
  27. package/agent-skills/packs/hive-mcp/SKILL.md +147 -0
  28. package/agent-skills/packs/hive-mcp/evals/evals.json +38 -0
  29. package/agent-skills/packs/hive-mcp/references/client-install-matrix.md +83 -0
  30. package/agent-skills/packs/hive-mcp/references/clients.md +141 -0
  31. package/agent-skills/packs/hive-network-infrastructure/SKILL.md +44 -0
  32. package/agent-skills/packs/hive-network-infrastructure/evals/evals.json +27 -0
  33. package/agent-skills/packs/hive-network-infrastructure/references/workflow.md +41 -0
  34. package/agent-skills/packs/hive-nft-research/SKILL.md +41 -0
  35. package/agent-skills/packs/hive-nft-research/evals/evals.json +27 -0
  36. package/agent-skills/packs/hive-nft-research/references/workflow.md +42 -0
  37. package/agent-skills/packs/hive-prediction-markets/SKILL.md +44 -0
  38. package/agent-skills/packs/hive-prediction-markets/evals/evals.json +27 -0
  39. package/agent-skills/packs/hive-prediction-markets/references/workflow.md +42 -0
  40. package/agent-skills/packs/hive-query/SKILL.md +99 -0
  41. package/agent-skills/packs/hive-query/evals/evals.json +38 -0
  42. package/agent-skills/packs/hive-query/references/root-mcp-workflow.md +54 -0
  43. package/agent-skills/packs/hive-security-risk/SKILL.md +42 -0
  44. package/agent-skills/packs/hive-security-risk/evals/evals.json +27 -0
  45. package/agent-skills/packs/hive-security-risk/references/workflow.md +46 -0
  46. package/agent-skills/packs/hive-solana-analysis/SKILL.md +42 -0
  47. package/agent-skills/packs/hive-solana-analysis/evals/evals.json +27 -0
  48. package/agent-skills/packs/hive-solana-analysis/references/workflow.md +42 -0
  49. package/agent-skills/packs/hive-stateful-monitoring/SKILL.md +75 -0
  50. package/agent-skills/packs/hive-stateful-monitoring/evals/evals.json +49 -0
  51. package/agent-skills/packs/hive-token-diligence/SKILL.md +44 -0
  52. package/agent-skills/packs/hive-token-diligence/evals/evals.json +27 -0
  53. package/agent-skills/packs/hive-token-diligence/references/workflow.md +45 -0
  54. package/agent-skills/packs/hive-tool-discovery/SKILL.md +49 -0
  55. package/agent-skills/packs/hive-tool-discovery/evals/evals.json +38 -0
  56. package/agent-skills/packs/hive-tool-discovery/references/discovery-surfaces.md +62 -0
  57. package/agent-skills/packs/hive-wallet-investigation/SKILL.md +42 -0
  58. package/agent-skills/packs/hive-wallet-investigation/evals/evals.json +27 -0
  59. package/agent-skills/packs/hive-wallet-investigation/references/workflow.md +45 -0
  60. package/agent-skills/references/agents-routing.md +51 -0
  61. package/agent-skills/scripts/validate-agent-skills-package.mjs +216 -0
  62. package/agent-skills/skills.sh.json +41 -0
  63. package/bin/hive-mcp.js +33 -0
  64. package/build/{alias-INGXWFCG.js → alias-3OPMQF4X.js} +2 -3
  65. package/build/api-client-EPF6FD7A.js +28 -0
  66. package/build/auth-Q5Q24IRI.js +39 -0
  67. package/build/browser-auth-VPF5LZMZ.js +8 -0
  68. package/build/{cache-US4LSZPI.js → cache-T6KC5YEY.js} +2 -3
  69. package/build/{chunk-QMRVH5ZP.js → chunk-3WYWXTNN.js} +9 -2
  70. package/build/chunk-4F5CI6LX.js +340 -0
  71. package/build/chunk-5XXI25JE.js +496 -0
  72. package/build/chunk-7JWXBKEJ.js +252 -0
  73. package/build/chunk-CEWCB5YS.js +71 -0
  74. package/build/{chunk-CGXVV6WR.js → chunk-FH3YGSY5.js} +86 -105
  75. package/build/chunk-FRXMGRZQ.js +102 -0
  76. package/build/chunk-GZPDEXO4.js +126 -0
  77. package/build/chunk-IZPAMRHP.js +43 -0
  78. package/build/chunk-JTUKQWIO.js +79720 -0
  79. package/build/{chunk-CP3FXEQA.js → chunk-NP6NSOG2.js} +4 -6
  80. package/build/{chunk-XQJ6PB2L.js → chunk-POT2MBEK.js} +0 -1
  81. package/build/chunk-VBOKVQ74.js +280 -0
  82. package/build/{chunk-WKVZVQTG.js → chunk-YZ2PXBJK.js} +6 -4
  83. package/build/chunk-ZCU7XQKF.js +14 -0
  84. package/build/chunk-ZTJVOWDQ.js +85 -0
  85. package/build/chunk-ZXB53E7H.js +246 -0
  86. package/build/cli.js +138 -125
  87. package/build/{completion-J6HFY6PS.js → completion-46K674EL.js} +54 -50
  88. package/build/config-XE6Q5P4I.js +57 -0
  89. package/build/{config-dir-IEOID7Q6.js → config-dir-MAWX5AUF.js} +2 -3
  90. package/build/{doctor-7WZMCQC7.js → doctor-HGMQE6IN.js} +37 -13
  91. package/build/{errors-U6UZWVSD.js → errors-J2PH3NLJ.js} +2 -3
  92. package/build/format-5X2HIVDT.js +42 -0
  93. package/build/{init-CAVIFVSH.js → init-JMDNM7ZZ.js} +1 -2
  94. package/build/init-all-5SKNV75X.js +273 -0
  95. package/build/mcpServer-5TKKSKJM.js +21 -0
  96. package/build/monitor-worker.js +1140 -0
  97. package/build/{namespace-7JWWBWBL.js → namespace-FSX2G3NM.js} +2 -3
  98. package/build/{open-FUXYIHFO.js → open-5A6ZQMGC.js} +5 -6
  99. package/build/{output-7PGQWJY2.js → output-V3D4YZ6U.js} +2 -3
  100. package/build/serve-AGCOXXFM.js +49 -0
  101. package/build/server.js +5042 -14125
  102. package/build/setup-RMETGJWK.js +135 -0
  103. package/build/stdio.js +32 -0
  104. package/build/{telemetry-KNWMQURH.js → telemetry-WCME5XEU.js} +4 -4
  105. package/build/{tools-VRRMBCZQ.js → tools-KAB6QBZC.js} +15 -15
  106. package/build/uninstall-FLJMBBSC.js +114 -0
  107. package/build/update-check-LNZQK3XA.js +18 -0
  108. package/build/upgrade-DTUIHVPS.js +171 -0
  109. package/build/version-I6HDAF4L.js +14 -0
  110. package/build/{watch-A75SVIQ6.js → watch-YNN255QX.js} +7 -7
  111. package/package.json +124 -53
  112. package/bin/hive.js +0 -25
  113. package/build/alias-INGXWFCG.js.map +0 -1
  114. package/build/auth-77MKFFBQ.js +0 -233
  115. package/build/auth-77MKFFBQ.js.map +0 -1
  116. package/build/cache-US4LSZPI.js.map +0 -1
  117. package/build/chunk-CGXVV6WR.js.map +0 -1
  118. package/build/chunk-CP3FXEQA.js.map +0 -1
  119. package/build/chunk-DTUDM6HX.js +0 -3108
  120. package/build/chunk-DTUDM6HX.js.map +0 -1
  121. package/build/chunk-LBTLYTZS.js +0 -115
  122. package/build/chunk-LBTLYTZS.js.map +0 -1
  123. package/build/chunk-OK3LSM73.js +0 -22
  124. package/build/chunk-OK3LSM73.js.map +0 -1
  125. package/build/chunk-QMRVH5ZP.js.map +0 -1
  126. package/build/chunk-RRI526CJ.js +0 -212
  127. package/build/chunk-RRI526CJ.js.map +0 -1
  128. package/build/chunk-WKVZVQTG.js.map +0 -1
  129. package/build/chunk-XQJ6PB2L.js.map +0 -1
  130. package/build/cli.js.map +0 -1
  131. package/build/completion-J6HFY6PS.js.map +0 -1
  132. package/build/config-ANFERP7A.js +0 -99
  133. package/build/config-ANFERP7A.js.map +0 -1
  134. package/build/config-dir-IEOID7Q6.js.map +0 -1
  135. package/build/doctor-7WZMCQC7.js.map +0 -1
  136. package/build/errors-U6UZWVSD.js.map +0 -1
  137. package/build/format-CVLLK6GD.js +0 -75
  138. package/build/format-CVLLK6GD.js.map +0 -1
  139. package/build/init-CAVIFVSH.js.map +0 -1
  140. package/build/namespace-7JWWBWBL.js.map +0 -1
  141. package/build/open-FUXYIHFO.js.map +0 -1
  142. package/build/output-7PGQWJY2.js.map +0 -1
  143. package/build/server.js.map +0 -1
  144. package/build/telemetry-KNWMQURH.js.map +0 -1
  145. package/build/tools-VRRMBCZQ.js.map +0 -1
  146. package/build/version-3TZ3U4IR.js +0 -9
  147. package/build/version-3TZ3U4IR.js.map +0 -1
  148. package/build/watch-A75SVIQ6.js.map +0 -1
package/build/cli.js CHANGED
@@ -2,34 +2,33 @@
2
2
  import { createRequire } from 'node:module'; const require = createRequire(import.meta.url);
3
3
  import {
4
4
  executeTool
5
- } from "./chunk-DTUDM6HX.js";
6
- import "./chunk-WKVZVQTG.js";
7
- import "./chunk-LBTLYTZS.js";
5
+ } from "./chunk-IZPAMRHP.js";
8
6
  import {
9
- CLI_VERSION
10
- } from "./chunk-OK3LSM73.js";
7
+ ExitCode
8
+ } from "./chunk-ZTJVOWDQ.js";
11
9
  import {
12
- red,
13
- setOutputOptions
14
- } from "./chunk-CP3FXEQA.js";
10
+ NAMESPACE
11
+ } from "./chunk-FH3YGSY5.js";
12
+ import "./chunk-7JWXBKEJ.js";
13
+ import "./chunk-YZ2PXBJK.js";
15
14
  import {
16
- ensureConfigDir,
17
- getConfigDir,
18
- readJsonFile,
19
- setCliFlags,
20
- writeJsonFile
21
- } from "./chunk-XQJ6PB2L.js";
15
+ checkForUpdates
16
+ } from "./chunk-FRXMGRZQ.js";
22
17
  import {
23
- ExitCode
24
- } from "./chunk-RRI526CJ.js";
18
+ SERVER_VERSION
19
+ } from "./chunk-ZCU7XQKF.js";
25
20
  import {
26
- NAMESPACE
27
- } from "./chunk-CGXVV6WR.js";
21
+ red,
22
+ setOutputOptions
23
+ } from "./chunk-NP6NSOG2.js";
24
+ import {
25
+ setCliFlags
26
+ } from "./chunk-POT2MBEK.js";
28
27
  import {
29
28
  __commonJS,
30
29
  __require,
31
30
  __toESM
32
- } from "./chunk-QMRVH5ZP.js";
31
+ } from "./chunk-3WYWXTNN.js";
33
32
 
34
33
  // node_modules/commander/lib/error.js
35
34
  var require_error = __commonJS({
@@ -3481,75 +3480,6 @@ var {
3481
3480
  Help
3482
3481
  } = import_index.default;
3483
3482
 
3484
- // src/cli/update-check.ts
3485
- import { join } from "path";
3486
- var CACHE_TTL_MS = 864e5;
3487
- function getCachePath() {
3488
- return join(getConfigDir(), "cache", "update-check.json");
3489
- }
3490
- async function checkForUpdates() {
3491
- if (process.env.CI || process.env.HIVE_NO_UPDATE_CHECK || !process.stderr.isTTY) {
3492
- return;
3493
- }
3494
- const cached = readJsonFile(getCachePath());
3495
- if (cached?.checkedAt && cached.cliVersion === CLI_VERSION) {
3496
- const age = Date.now() - new Date(cached.checkedAt).getTime();
3497
- if (age < CACHE_TTL_MS) {
3498
- if (cached.latestVersion && isNewer(cached.latestVersion, CLI_VERSION)) {
3499
- showUpdateMessage(cached.latestVersion);
3500
- }
3501
- return;
3502
- }
3503
- }
3504
- try {
3505
- const controller = new AbortController();
3506
- const timeout = setTimeout(() => controller.abort(), 3e3);
3507
- const res = await fetch("https://registry.npmjs.org/hive-intelligence/latest", {
3508
- signal: controller.signal
3509
- });
3510
- clearTimeout(timeout);
3511
- if (!res.ok) return;
3512
- const data = await res.json();
3513
- ensureConfigDir();
3514
- writeJsonFile(getCachePath(), {
3515
- checkedAt: (/* @__PURE__ */ new Date()).toISOString(),
3516
- latestVersion: data.version ?? null,
3517
- cliVersion: CLI_VERSION
3518
- });
3519
- if (!data.version || !isNewer(data.version, CLI_VERSION)) return;
3520
- showUpdateMessage(data.version);
3521
- } catch {
3522
- }
3523
- }
3524
- function isNewer(latest, current) {
3525
- const parse = (v) => {
3526
- const [main, pre = ""] = v.split("-", 2);
3527
- const parts = main.split(".").map((n) => parseInt(n, 10) || 0);
3528
- return { parts, pre };
3529
- };
3530
- const a = parse(latest);
3531
- const b = parse(current);
3532
- for (let i = 0; i < 3; i++) {
3533
- const ai = a.parts[i] ?? 0;
3534
- const bi = b.parts[i] ?? 0;
3535
- if (ai !== bi) return ai > bi;
3536
- }
3537
- if (a.pre === b.pre) return false;
3538
- if (!a.pre) return true;
3539
- if (!b.pre) return false;
3540
- return a.pre > b.pre;
3541
- }
3542
- function showUpdateMessage(newVersion) {
3543
- process.stderr.write(
3544
- `
3545
- Update available: ${CLI_VERSION} \u2192 ${newVersion}
3546
- npm: npm update -g hive-intelligence
3547
- bun: bun update -g hive-intelligence
3548
-
3549
- `
3550
- );
3551
- }
3552
-
3553
3483
  // src/cli.ts
3554
3484
  process.on("unhandledRejection", (err) => {
3555
3485
  const msg = err instanceof Error ? process.env.DEBUG ? err.stack : err.message : String(err);
@@ -3567,8 +3497,8 @@ process.on("uncaughtException", (err) => {
3567
3497
  process.on("SIGINT", () => process.exit(130));
3568
3498
  process.on("SIGTERM", () => process.exit(143));
3569
3499
  var program2 = new Command();
3570
- program2.name("hive").version(CLI_VERSION).description(
3571
- "Hive Intelligence CLI \u2014 institutional-grade crypto market data, DeFi, wallets, security, DEX, NFTs, and prediction markets for AI agents"
3500
+ program2.name("hive").version(SERVER_VERSION).description(
3501
+ "Hive Intelligence \u2014 managed crypto market data, DeFi, wallets, security, DEX, NFTs, and prediction markets for AI agents and developers"
3572
3502
  ).exitOverride().configureOutput({
3573
3503
  writeErr: (str) => process.stderr.write(str),
3574
3504
  outputError: (str, write) => {
@@ -3592,8 +3522,26 @@ program2.hook("preAction", (thisCommand) => {
3592
3522
  }
3593
3523
  setCliFlags({ apiKey: opts.apiKey, noRetry: opts.retry === false });
3594
3524
  });
3595
- program2.action(() => {
3596
- program2.help();
3525
+ program2.action(async () => {
3526
+ const { startStdio } = await import("./serve-AGCOXXFM.js");
3527
+ await startStdio(program2.opts().envFile);
3528
+ });
3529
+ program2.command("serve").description("Start the MCP server").option("--http", "Start HTTP server instead of stdio").option("--port <number>", "HTTP server port", "8080").action(async (opts) => {
3530
+ if (opts.http) {
3531
+ const port = parseInt(opts.port, 10);
3532
+ if (isNaN(port) || port < 1 || port > 65535) {
3533
+ process.stderr.write(
3534
+ `Error: invalid port "${opts.port}" (must be 1-65535)
3535
+ `
3536
+ );
3537
+ process.exit(ExitCode.INVALID_ARGS);
3538
+ }
3539
+ const { startHttp } = await import("./serve-AGCOXXFM.js");
3540
+ await startHttp(port, program2.opts().envFile);
3541
+ } else {
3542
+ const { startStdio } = await import("./serve-AGCOXXFM.js");
3543
+ await startStdio(program2.opts().envFile);
3544
+ }
3597
3545
  });
3598
3546
  for (const domain of NAMESPACE) {
3599
3547
  const domainCmd = program2.command(domain.name).description(domain.description);
@@ -3664,15 +3612,15 @@ for (const domain of NAMESPACE) {
3664
3612
  }
3665
3613
  var toolsCmd = program2.command("tools").description("Discover and execute tools");
3666
3614
  toolsCmd.command("list").description("List all registered tools").option("--category <name>", "Filter by category").option("--provider <name>", "Filter by provider prefix").option("--limit <n>", "Max tools to show", "50").option("--offset <n>", "Skip first N tools", "0").action(async (opts) => {
3667
- const { listTools } = await import("./tools-VRRMBCZQ.js");
3615
+ const { listTools } = await import("./tools-KAB6QBZC.js");
3668
3616
  await listTools(opts);
3669
3617
  });
3670
3618
  toolsCmd.command("search <query>").description("Search tools by name or description").action(async (query) => {
3671
- const { searchTools } = await import("./tools-VRRMBCZQ.js");
3619
+ const { searchTools } = await import("./tools-KAB6QBZC.js");
3672
3620
  await searchTools(query);
3673
3621
  });
3674
3622
  toolsCmd.command("info <name>").description("Show detailed tool schema and description").action(async (name) => {
3675
- const { toolInfo } = await import("./tools-VRRMBCZQ.js");
3623
+ const { toolInfo } = await import("./tools-KAB6QBZC.js");
3676
3624
  await toolInfo(name);
3677
3625
  });
3678
3626
  toolsCmd.command("call <name>").description("Execute a tool by name").option("--args <json>", "Tool arguments as JSON (or pipe JSON via stdin)").action(async (name, opts) => {
@@ -3701,76 +3649,143 @@ toolsCmd.command("call <name>").description("Execute a tool by name").option("--
3701
3649
  await executeTool(name, args, timeout);
3702
3650
  });
3703
3651
  toolsCmd.command("refresh").description("Force-refresh the tool catalog cache").action(async () => {
3704
- const { refreshTools } = await import("./tools-VRRMBCZQ.js");
3652
+ const { refreshTools } = await import("./tools-KAB6QBZC.js");
3705
3653
  await refreshTools();
3706
3654
  });
3707
3655
  var configCmd = program2.command("config").description("Generate configuration for MCP clients");
3708
3656
  configCmd.command("claude-desktop").description("Print Claude Desktop config JSON").action(async () => {
3709
- const { configClaudeDesktop } = await import("./config-ANFERP7A.js");
3657
+ const { configClaudeDesktop } = await import("./config-XE6Q5P4I.js");
3710
3658
  configClaudeDesktop();
3711
3659
  });
3712
3660
  configCmd.command("cursor").description("Print Cursor config JSON").action(async () => {
3713
- const { configCursor } = await import("./config-ANFERP7A.js");
3661
+ const { configCursor } = await import("./config-XE6Q5P4I.js");
3714
3662
  configCursor();
3715
3663
  });
3716
3664
  configCmd.command("vscode").description("Print VS Code mcp.json config").action(async () => {
3717
- const { configVscode } = await import("./config-ANFERP7A.js");
3665
+ const { configVscode } = await import("./config-XE6Q5P4I.js");
3718
3666
  configVscode();
3719
3667
  });
3720
3668
  configCmd.command("claude-code").description("Print claude mcp add command").action(async () => {
3721
- const { configClaudeCode } = await import("./config-ANFERP7A.js");
3669
+ const { configClaudeCode } = await import("./config-XE6Q5P4I.js");
3722
3670
  configClaudeCode();
3723
3671
  });
3724
3672
  configCmd.command("http [url]").description("Print remote HTTP connection instructions").action(async (url) => {
3725
- const { configHttpUrl } = await import("./config-ANFERP7A.js");
3673
+ const { configHttpUrl } = await import("./config-XE6Q5P4I.js");
3726
3674
  configHttpUrl(
3727
3675
  url || process.env.HIVE_DEFAULT_URL || "https://mcp.hiveintelligence.xyz"
3728
3676
  );
3729
3677
  });
3730
- program2.command("init").description("Interactive setup wizard for Hive API key").option("--minimal", "Write defaults without interactive prompts").option("--dry-run", "Preview changes without writing").action(async (opts) => {
3731
- const { runInit } = await import("./init-CAVIFVSH.js");
3732
- await runInit(opts);
3678
+ program2.command("setup [client]").description(
3679
+ "Interactive setup wizard \u2014 log in and configure your AI client (claude-desktop, claude-code, cursor, vscode)"
3680
+ ).action(async (client) => {
3681
+ const { runSetup } = await import("./setup-RMETGJWK.js");
3682
+ await runSetup(client);
3683
+ });
3684
+ program2.command("init").description(
3685
+ "One-command setup. --all installs across every detected client; --browser runs PKCE browser auth."
3686
+ ).option("--all", "Configure every detected MCP client + install skill packs").option("--browser", "Authenticate via PKCE browser flow").option("--skip-skills", "Don't copy skill packs into client skills dirs").option("--skip-verify", "Skip the post-install connectivity check").option("--dry-run", "Preview changes without writing").option(
3687
+ "--minimal",
3688
+ "Legacy mode: write a .env file only, no client install (kept for backwards compat)"
3689
+ ).option(
3690
+ "--api-url <url>",
3691
+ "Override the Hive API URL (e.g. for staging or self-hosted)"
3692
+ ).action(async (opts) => {
3693
+ if (opts.minimal && !opts.all && !opts.browser) {
3694
+ const { runInit } = await import("./init-JMDNM7ZZ.js");
3695
+ await runInit(opts);
3696
+ return;
3697
+ }
3698
+ const { runInitAll } = await import("./init-all-5SKNV75X.js");
3699
+ const exitCode = await runInitAll({
3700
+ all: Boolean(opts.all),
3701
+ browser: Boolean(opts.browser),
3702
+ skipSkills: Boolean(opts.skipSkills),
3703
+ skipVerify: Boolean(opts.skipVerify),
3704
+ dryRun: Boolean(opts.dryRun),
3705
+ json: Boolean(program2.opts().json),
3706
+ apiUrl: opts.apiUrl
3707
+ });
3708
+ if (exitCode !== 0) process.exit(exitCode);
3709
+ });
3710
+ program2.command("uninstall").description(
3711
+ "Remove Hive's MCP entry from every client config + delete copied skill packs"
3712
+ ).option(
3713
+ "--all",
3714
+ "Clean every known client (default; explicit flag for symmetry with `init --all`)"
3715
+ ).option("--dry-run", "Preview removals without changing anything").action(async (opts) => {
3716
+ const { runUninstall } = await import("./uninstall-FLJMBBSC.js");
3717
+ const exitCode = await runUninstall({
3718
+ all: opts.all !== false,
3719
+ dryRun: Boolean(opts.dryRun),
3720
+ json: Boolean(program2.opts().json)
3721
+ });
3722
+ if (exitCode !== 0) process.exit(exitCode);
3733
3723
  });
3734
3724
  program2.command("doctor").description("Diagnose environment and server connectivity").option("--probe", "Run live API probes (slower)").action(async (opts) => {
3735
- const { runDoctor } = await import("./doctor-7WZMCQC7.js");
3725
+ const { runDoctor } = await import("./doctor-HGMQE6IN.js");
3736
3726
  await runDoctor(opts);
3737
3727
  });
3728
+ program2.command("upgrade").description("Update Hive to the latest published version").action(async () => {
3729
+ const { runUpgrade } = await import("./upgrade-DTUIHVPS.js");
3730
+ await runUpgrade();
3731
+ });
3738
3732
  program2.command("completion <shell>").description("Generate shell completion script (bash, zsh, fish, powershell)").option("--install", "Auto-install to shell rc file").action(async (shell, opts) => {
3739
3733
  if (opts.install) {
3740
- const { installCompletion } = await import("./completion-J6HFY6PS.js");
3734
+ const { installCompletion } = await import("./completion-46K674EL.js");
3741
3735
  await installCompletion(shell);
3742
3736
  } else {
3743
- const { generateCompletion } = await import("./completion-J6HFY6PS.js");
3737
+ const { generateCompletion } = await import("./completion-46K674EL.js");
3744
3738
  await generateCompletion(shell);
3745
3739
  }
3746
3740
  });
3747
3741
  var authCmd = program2.command("auth").description("Manage authentication profiles");
3748
- authCmd.command("login").description("Log in with your Hive API key").option("--profile <name>", "Profile name", "default").action(async (opts) => {
3749
- const { runLogin } = await import("./auth-77MKFFBQ.js");
3742
+ authCmd.command("signup").description("Create a new Hive account and get your API key").option("--profile <name>", "Profile name", "default").action(async (opts) => {
3743
+ const { runSignup } = await import("./auth-Q5Q24IRI.js");
3744
+ await runSignup(opts);
3745
+ });
3746
+ authCmd.command("login").description("Log in via browser (or --manual to paste API key)").option("--profile <name>", "Profile name", "default").option("--manual", "Manually paste API key instead of browser login").action(async (opts) => {
3747
+ const { runLogin } = await import("./auth-Q5Q24IRI.js");
3750
3748
  await runLogin(opts);
3751
3749
  });
3752
3750
  authCmd.command("logout").description("Remove stored credentials").action(async () => {
3753
- const { runLogout } = await import("./auth-77MKFFBQ.js");
3751
+ const { runLogout } = await import("./auth-Q5Q24IRI.js");
3754
3752
  await runLogout();
3755
3753
  });
3756
3754
  authCmd.command("whoami").description("Show current profile").action(async () => {
3757
- const { runWhoami } = await import("./auth-77MKFFBQ.js");
3755
+ const { runWhoami } = await import("./auth-Q5Q24IRI.js");
3758
3756
  await runWhoami();
3759
3757
  });
3760
3758
  authCmd.command("profiles").description("List all profiles").action(async () => {
3761
- const { runProfiles } = await import("./auth-77MKFFBQ.js");
3759
+ const { runProfiles } = await import("./auth-Q5Q24IRI.js");
3762
3760
  await runProfiles();
3763
3761
  });
3764
3762
  authCmd.command("switch <name>").description("Switch active profile").action(async (name) => {
3765
- const { runSwitch } = await import("./auth-77MKFFBQ.js");
3763
+ const { runSwitch } = await import("./auth-Q5Q24IRI.js");
3766
3764
  await runSwitch(name);
3767
3765
  });
3766
+ var keysCmd = program2.command("keys").description("Manage your Hive API keys");
3767
+ keysCmd.command("list").description("List your API keys").action(async () => {
3768
+ const { runKeysList } = await import("./auth-Q5Q24IRI.js");
3769
+ await runKeysList();
3770
+ });
3771
+ keysCmd.command("create").description("Create a new API key").option("--name <name>", "Key name", "CLI Key").action(async (opts) => {
3772
+ const { runKeysCreate } = await import("./auth-Q5Q24IRI.js");
3773
+ await runKeysCreate(opts);
3774
+ });
3775
+ keysCmd.command("revoke <id>").description("Revoke an API key").action(async (id) => {
3776
+ const { runKeysRevoke } = await import("./auth-Q5Q24IRI.js");
3777
+ await runKeysRevoke(id);
3778
+ });
3779
+ program2.command("usage").description("Show your API usage and plan limits").action(async () => {
3780
+ const { runUsage } = await import("./auth-Q5Q24IRI.js");
3781
+ await runUsage();
3782
+ });
3768
3783
  program2.command("status").description("Quick health and version check").action(async () => {
3769
- const { runStatus } = await import("./doctor-7WZMCQC7.js");
3784
+ const { runStatus } = await import("./doctor-HGMQE6IN.js");
3770
3785
  await runStatus();
3771
3786
  });
3772
3787
  program2.command("open [target]").description("Open Hive dashboard, docs, status, or GitHub in browser").action(async (target) => {
3773
- const { runOpen } = await import("./open-FUXYIHFO.js");
3788
+ const { runOpen } = await import("./open-5A6ZQMGC.js");
3774
3789
  runOpen(target);
3775
3790
  });
3776
3791
  program2.command("watch <domain> <command>").description("Poll a tool on interval").option("--interval <seconds>", "Poll interval in seconds", "30").option("--args <json>", "Tool arguments as JSON").action(async (domain, command, opts) => {
@@ -3797,18 +3812,18 @@ program2.command("watch <domain> <command>").description("Poll a tool on interva
3797
3812
  }
3798
3813
  const interval = parseInt(opts.interval, 10);
3799
3814
  const timeout = parseInt(program2.opts().timeout, 10);
3800
- const { runWatch } = await import("./watch-A75SVIQ6.js");
3815
+ const { runWatch } = await import("./watch-YNN255QX.js");
3801
3816
  await runWatch(cmdDef.tool, args, interval, timeout);
3802
3817
  });
3803
3818
  var aliasCmd = program2.command("alias").description("Manage command aliases");
3804
3819
  aliasCmd.command("set <name> <command>").description("Create an alias").action(async (name, command) => {
3805
- const { setAlias } = await import("./alias-INGXWFCG.js");
3820
+ const { setAlias } = await import("./alias-3OPMQF4X.js");
3806
3821
  setAlias(name, command);
3807
3822
  process.stderr.write(`Alias "${name}" set.
3808
3823
  `);
3809
3824
  });
3810
3825
  aliasCmd.command("list").description("Show all aliases").action(async () => {
3811
- const { getAliases } = await import("./alias-INGXWFCG.js");
3826
+ const { getAliases } = await import("./alias-3OPMQF4X.js");
3812
3827
  const aliases = getAliases();
3813
3828
  const entries = Object.entries(aliases);
3814
3829
  if (entries.length === 0) {
@@ -3822,22 +3837,22 @@ aliasCmd.command("list").description("Show all aliases").action(async () => {
3822
3837
  process.stderr.write("\n");
3823
3838
  });
3824
3839
  aliasCmd.command("remove <name>").description("Remove an alias").action(async (name) => {
3825
- const { removeAlias } = await import("./alias-INGXWFCG.js");
3840
+ const { removeAlias } = await import("./alias-3OPMQF4X.js");
3826
3841
  removeAlias(name);
3827
3842
  process.stderr.write(`Alias "${name}" removed.
3828
3843
  `);
3829
3844
  });
3830
3845
  var telemetryCmd = program2.command("telemetry").description("Control anonymous usage telemetry");
3831
3846
  telemetryCmd.command("enable").description("Enable telemetry").action(async () => {
3832
- const { enableTelemetry } = await import("./telemetry-KNWMQURH.js");
3847
+ const { enableTelemetry } = await import("./telemetry-WCME5XEU.js");
3833
3848
  enableTelemetry();
3834
3849
  });
3835
3850
  telemetryCmd.command("disable").description("Disable telemetry").action(async () => {
3836
- const { disableTelemetry } = await import("./telemetry-KNWMQURH.js");
3851
+ const { disableTelemetry } = await import("./telemetry-WCME5XEU.js");
3837
3852
  disableTelemetry();
3838
3853
  });
3839
3854
  telemetryCmd.command("status").description("Show telemetry status").action(async () => {
3840
- const { telemetryStatus } = await import("./telemetry-KNWMQURH.js");
3855
+ const { telemetryStatus } = await import("./telemetry-WCME5XEU.js");
3841
3856
  telemetryStatus();
3842
3857
  });
3843
3858
  program2.addHelpText(
@@ -3848,7 +3863,6 @@ Examples:
3848
3863
  $ hive market price --ids bitcoin --vs usd
3849
3864
  $ hive defi tvl --protocol aave
3850
3865
  $ hive security scan --token 0x...
3851
- $ hive portfolio balance --address 0x...
3852
3866
  $ hive tools search "price" --jq ".[] | .name"
3853
3867
  $ hive status
3854
3868
  $ hive alias set btc 'market price --ids bitcoin --vs usd'
@@ -3858,7 +3872,7 @@ Examples:
3858
3872
  );
3859
3873
  checkForUpdates();
3860
3874
  {
3861
- const { expandAlias } = await import("./alias-INGXWFCG.js");
3875
+ const { expandAlias } = await import("./alias-3OPMQF4X.js");
3862
3876
  const expanded = expandAlias(process.argv);
3863
3877
  if (expanded !== process.argv) {
3864
3878
  process.argv = expanded;
@@ -3875,4 +3889,3 @@ try {
3875
3889
  }
3876
3890
  throw err;
3877
3891
  }
3878
- //# sourceMappingURL=cli.js.map
@@ -1,8 +1,8 @@
1
1
  import { createRequire } from 'node:module'; const require = createRequire(import.meta.url);
2
2
  import {
3
3
  NAMESPACE
4
- } from "./chunk-CGXVV6WR.js";
5
- import "./chunk-QMRVH5ZP.js";
4
+ } from "./chunk-FH3YGSY5.js";
5
+ import "./chunk-3WYWXTNN.js";
6
6
 
7
7
  // src/cli/completion.ts
8
8
  import {
@@ -14,6 +14,8 @@ import {
14
14
  } from "fs";
15
15
  import { join } from "path";
16
16
  import { homedir } from "os";
17
+ var PRIMARY_COMMAND = "hive";
18
+ var COMPLETION_COMMANDS = ["hive", "hive-intelligence", "hive-mcp"];
17
19
  function getTopLevel() {
18
20
  return [
19
21
  "serve",
@@ -61,9 +63,9 @@ function generateBash() {
61
63
  const cases = Object.entries(domainSubs).map(
62
64
  ([domain, subs]) => ` ${domain}) COMPREPLY=($(compgen -W "${subs.join(" ")}" -- "$cur")); return ;;`
63
65
  ).join("\n");
64
- console.log(`# Hive MCP bash completion
65
- # Add to ~/.bashrc: eval "$(hive-mcp completion bash)"
66
- _hive_mcp_completions() {
66
+ console.log(`# Hive CLI bash completion
67
+ # Add to ~/.bashrc: eval "$(hive completion bash)"
68
+ _hive_completions() {
67
69
  local cur="\${COMP_WORDS[COMP_CWORD]}"
68
70
  local prev="\${COMP_WORDS[COMP_CWORD-1]}"
69
71
 
@@ -80,7 +82,7 @@ ${cases}
80
82
 
81
83
  COMPREPLY=($(compgen -W "${topLevel.join(" ")}" -- "$cur"))
82
84
  }
83
- complete -F _hive_mcp_completions hive-mcp`);
85
+ complete -F _hive_completions ${COMPLETION_COMMANDS.join(" ")}`);
84
86
  }
85
87
  function generateZsh() {
86
88
  const domainEntries = NAMESPACE.map(
@@ -96,9 +98,9 @@ ${subs}
96
98
  _describe 'subcommand' subcmds
97
99
  ;;`;
98
100
  }).join("\n");
99
- console.log(`# Hive MCP zsh completion
100
- # Add to ~/.zshrc: eval "$(hive-mcp completion zsh)"
101
- _hive_mcp() {
101
+ console.log(`# Hive CLI zsh completion
102
+ # Add to ~/.zshrc: eval "$(hive completion zsh)"
103
+ _hive() {
102
104
  local -a commands
103
105
  commands=(
104
106
  'serve:Start the MCP server'
@@ -154,54 +156,57 @@ ${subcommandCases}
154
156
  esac
155
157
  fi
156
158
  }
157
- compdef _hive_mcp hive-mcp`);
159
+ compdef _hive ${COMPLETION_COMMANDS.join(" ")}`);
158
160
  }
159
161
  function generateFish() {
160
162
  const topLevel = getTopLevel();
161
163
  const lines = [
162
- "# Hive MCP fish completion",
163
- "# Save to: ~/.config/fish/completions/hive-mcp.fish",
164
+ "# Hive CLI fish completion",
165
+ "# Save to: ~/.config/fish/completions/hive.fish",
164
166
  ""
165
167
  ];
166
- for (const cmd of topLevel) {
167
- const desc = NAMESPACE.find((d) => d.name === cmd)?.description ?? cmd;
168
- lines.push(
169
- `complete -c hive-mcp -n '__fish_use_subcommand' -a '${cmd}' -d '${desc}'`
170
- );
171
- }
172
- const domainSubs = getDomainSubs();
173
- for (const [domain, subs] of Object.entries(domainSubs)) {
174
- for (const sub of subs) {
175
- const desc = NAMESPACE.find((d) => d.name === domain)?.commands.find(
176
- (c) => c.name === sub
177
- )?.description ?? sub;
168
+ for (const commandName of COMPLETION_COMMANDS) {
169
+ for (const cmd of topLevel) {
170
+ const desc = NAMESPACE.find((d) => d.name === cmd)?.description ?? cmd;
178
171
  lines.push(
179
- `complete -c hive-mcp -n '__fish_seen_subcommand_from ${domain}' -a '${sub}' -d '${desc}'`
172
+ `complete -c ${commandName} -n '__fish_use_subcommand' -a '${cmd}' -d '${desc}'`
173
+ );
174
+ }
175
+ const domainSubs = getDomainSubs();
176
+ for (const [domain, subs] of Object.entries(domainSubs)) {
177
+ for (const sub of subs) {
178
+ const desc = NAMESPACE.find((d) => d.name === domain)?.commands.find(
179
+ (c) => c.name === sub
180
+ )?.description ?? sub;
181
+ lines.push(
182
+ `complete -c ${commandName} -n '__fish_seen_subcommand_from ${domain}' -a '${sub}' -d '${desc}'`
183
+ );
184
+ }
185
+ }
186
+ for (const sub of ["list", "search", "info", "call", "refresh"]) {
187
+ lines.push(
188
+ `complete -c ${commandName} -n '__fish_seen_subcommand_from tools' -a '${sub}'`
189
+ );
190
+ }
191
+ for (const sub of ["login", "logout", "whoami", "profiles", "switch"]) {
192
+ lines.push(
193
+ `complete -c ${commandName} -n '__fish_seen_subcommand_from auth' -a '${sub}'`
194
+ );
195
+ }
196
+ for (const sub of ["set", "list", "remove"]) {
197
+ lines.push(
198
+ `complete -c ${commandName} -n '__fish_seen_subcommand_from alias' -a '${sub}'`
180
199
  );
181
200
  }
182
- }
183
- for (const sub of ["list", "search", "info", "call", "refresh"]) {
184
- lines.push(
185
- `complete -c hive-mcp -n '__fish_seen_subcommand_from tools' -a '${sub}'`
186
- );
187
- }
188
- for (const sub of ["login", "logout", "whoami", "profiles", "switch"]) {
189
- lines.push(
190
- `complete -c hive-mcp -n '__fish_seen_subcommand_from auth' -a '${sub}'`
191
- );
192
- }
193
- for (const sub of ["set", "list", "remove"]) {
194
- lines.push(
195
- `complete -c hive-mcp -n '__fish_seen_subcommand_from alias' -a '${sub}'`
196
- );
197
201
  }
198
202
  console.log(lines.join("\n"));
199
203
  }
200
204
  function generatePowerShell() {
201
205
  const topLevel = getTopLevel();
202
- console.log(`# Hive MCP PowerShell completion
203
- # Add to your $PROFILE: . (hive-mcp completion powershell)
204
- Register-ArgumentCompleter -Native -CommandName hive-mcp -ScriptBlock {
206
+ const commandNames = COMPLETION_COMMANDS.map((cmd) => `'${cmd}'`).join(",");
207
+ console.log(`# Hive CLI PowerShell completion
208
+ # Add to your $PROFILE: . (hive completion powershell)
209
+ Register-ArgumentCompleter -Native -CommandName ${commandNames} -ScriptBlock {
205
210
  param($wordToComplete, $commandAst, $cursorPosition)
206
211
  $commands = @(${topLevel.map((c) => `'${c}'`).join(", ")})
207
212
  $commands | Where-Object { $_ -like "$wordToComplete*" } | ForEach-Object {
@@ -213,13 +218,13 @@ async function installCompletion(shell) {
213
218
  switch (shell) {
214
219
  case "bash": {
215
220
  const rcFile = join(homedir(), ".bashrc");
216
- const line = 'eval "$(hive-mcp completion bash)"';
221
+ const line = 'eval "$(hive completion bash)"';
217
222
  if (existsSync(rcFile) && readFileSync(rcFile, "utf-8").includes(line)) {
218
223
  process.stderr.write("Bash completion already installed.\n");
219
224
  return;
220
225
  }
221
226
  appendFileSync(rcFile, `
222
- # Hive MCP CLI completion
227
+ # Hive CLI completion
223
228
  ${line}
224
229
  `);
225
230
  process.stderr.write(
@@ -230,13 +235,13 @@ ${line}
230
235
  }
231
236
  case "zsh": {
232
237
  const rcFile = join(homedir(), ".zshrc");
233
- const line = 'eval "$(hive-mcp completion zsh)"';
238
+ const line = 'eval "$(hive completion zsh)"';
234
239
  if (existsSync(rcFile) && readFileSync(rcFile, "utf-8").includes(line)) {
235
240
  process.stderr.write("Zsh completion already installed.\n");
236
241
  return;
237
242
  }
238
243
  appendFileSync(rcFile, `
239
- # Hive MCP CLI completion
244
+ # Hive CLI completion
240
245
  ${line}
241
246
  `);
242
247
  process.stderr.write(
@@ -248,9 +253,9 @@ ${line}
248
253
  case "fish": {
249
254
  const dir = join(homedir(), ".config", "fish", "completions");
250
255
  if (!existsSync(dir)) mkdirSync(dir, { recursive: true });
251
- const filePath = join(dir, "hive-mcp.fish");
256
+ const filePath = join(dir, "hive.fish");
252
257
  const { execFileSync } = await import("child_process");
253
- const bin = process.argv[1] ?? "hive-mcp";
258
+ const bin = process.argv[1] ?? PRIMARY_COMMAND;
254
259
  const output = execFileSync(bin, ["completion", "fish"], {
255
260
  encoding: "utf-8"
256
261
  });
@@ -271,4 +276,3 @@ export {
271
276
  generateCompletion,
272
277
  installCompletion
273
278
  };
274
- //# sourceMappingURL=completion-J6HFY6PS.js.map
@@ -0,0 +1,57 @@
1
+ import { createRequire } from 'node:module'; const require = createRequire(import.meta.url);
2
+ import {
3
+ configClaudeCode,
4
+ configClaudeDesktop,
5
+ configCursor,
6
+ configHttpUrl,
7
+ configVscode,
8
+ getClaudeCodeUserConfigPath,
9
+ getClaudeDesktopConfigPath,
10
+ getCursorConfigPath,
11
+ getGeminiCliSettingsPath,
12
+ getVscodeConfigPath,
13
+ getWindsurfMcpConfigPath,
14
+ printChatGptDesktopInstructions,
15
+ removeClaudeCodeUserConfig,
16
+ removeClaudeDesktopConfig,
17
+ removeCursorConfig,
18
+ removeGeminiCliConfig,
19
+ removeVscodeConfig,
20
+ removeWindsurfConfig,
21
+ writeClaudeCodeConfig,
22
+ writeClaudeCodeUserConfig,
23
+ writeClaudeDesktopConfig,
24
+ writeCursorConfig,
25
+ writeGeminiCliConfig,
26
+ writeVscodeConfig,
27
+ writeWindsurfConfig
28
+ } from "./chunk-4F5CI6LX.js";
29
+ import "./chunk-POT2MBEK.js";
30
+ import "./chunk-3WYWXTNN.js";
31
+ export {
32
+ configClaudeCode,
33
+ configClaudeDesktop,
34
+ configCursor,
35
+ configHttpUrl,
36
+ configVscode,
37
+ getClaudeCodeUserConfigPath,
38
+ getClaudeDesktopConfigPath,
39
+ getCursorConfigPath,
40
+ getGeminiCliSettingsPath,
41
+ getVscodeConfigPath,
42
+ getWindsurfMcpConfigPath,
43
+ printChatGptDesktopInstructions,
44
+ removeClaudeCodeUserConfig,
45
+ removeClaudeDesktopConfig,
46
+ removeCursorConfig,
47
+ removeGeminiCliConfig,
48
+ removeVscodeConfig,
49
+ removeWindsurfConfig,
50
+ writeClaudeCodeConfig,
51
+ writeClaudeCodeUserConfig,
52
+ writeClaudeDesktopConfig,
53
+ writeCursorConfig,
54
+ writeGeminiCliConfig,
55
+ writeVscodeConfig,
56
+ writeWindsurfConfig
57
+ };