@mushi-mushi/mcp 0.19.0 → 0.20.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/CONTRIBUTING.md +10 -2
- package/README.md +87 -88
- package/SECURITY.md +73 -1
- package/dist/catalog.d.ts +10 -1
- package/dist/catalog.js +5 -3
- package/dist/{chunk-DSOPGMDX.js → chunk-TP2QQWDJ.js} +105 -3
- package/dist/{chunk-VBXXUK5G.js → chunk-ZSVRLSW5.js} +4 -2
- package/dist/clients.d.ts +8 -1
- package/dist/clients.js +7 -5
- package/dist/feature-groups.js +1 -1
- package/dist/index.js +576 -206
- package/dist/server.js +472 -204
- package/package.json +2 -2
|
@@ -282,7 +282,7 @@ var TOOL_CATALOG = [
|
|
|
282
282
|
{
|
|
283
283
|
name: "get_report_evidence",
|
|
284
284
|
title: "Bug report evidence",
|
|
285
|
-
description: "Return the full evidence package for a single bug report:
|
|
285
|
+
description: "Return the full evidence package for a single bug report covering all three observability pillars: (1) LOGS \u2014 console_logs (error/warn/info/debug entries with timestamps), breadcrumbs (SDK ring buffer: navigation, clicks, network, lifecycle events with category/level), repro_timeline (merged SDK event stream: route/click/request/log/screen), and the reporter's own comments thread; (2) TRACES \u2014 network_requests (SDK-captured fetch/XHR with method/status/duration/traceId), backend_spans (server-side spans joined by W3C trace_id: name/duration_ms/parentSpanId/status), and Sentry trace correlation IDs (sentry_trace_id, sentry_event_id) for deeplinks; (3) METRICS \u2014 performance_metrics (Web Vitals snapshot: LCP/CLS/INP/TTFB/FCP + INP attribution + page timing + connection info), anomalies (statistical provenance when auto-filed by CI metric regression: baseline_mean/std, score in \u03C3, threshold); plus screenshot_url, browser environment (user agent, URL, viewport, SDK version), and tags. This is the same data an engineer would collect for a root-cause investigation. Faster than calling get_report_detail + report timeline separately.",
|
|
286
286
|
scope: "mcp:read",
|
|
287
287
|
hints: { readOnly: true, idempotent: true, openWorld: true },
|
|
288
288
|
useCase: "I need all the evidence for this bug report to diagnose the root cause."
|
|
@@ -449,7 +449,7 @@ var TDD_TOOL_CATALOG = [
|
|
|
449
449
|
{
|
|
450
450
|
name: "list_byok_keys",
|
|
451
451
|
title: "List your API key pool",
|
|
452
|
-
description: "List the project's BYOK API keys grouped by provider (anthropic | openai | firecrawl | browserbase | cursor). Returns { keys: [{ id,
|
|
452
|
+
description: "List the project's BYOK API keys grouped by provider (anthropic | openai | firecrawl | browserbase | cursor). Returns pooled { keys: [{ id, provider_slug, label, priority, status, cooldown_until, test_status, key_hint, base_url, last_tested_at, last_used_at }] } plus read-only { legacyKeys } metadata for credentials saved before the pooled lifecycle \u2014 never the raw secret. Read-only. Use to see which keys are validated, active, pending, legacy, or rate-limited; use add_byok_key to add one.",
|
|
453
453
|
scope: "mcp:read",
|
|
454
454
|
hints: { readOnly: true, idempotent: true, openWorld: true },
|
|
455
455
|
useCase: "Which API keys are active and which are rate-limited?"
|
|
@@ -457,11 +457,27 @@ var TDD_TOOL_CATALOG = [
|
|
|
457
457
|
{
|
|
458
458
|
name: "add_byok_key",
|
|
459
459
|
title: "Add an API key",
|
|
460
|
-
description: "Add a BYOK API key
|
|
460
|
+
description: "Add and immediately validate a BYOK API key for anthropic | openai | firecrawl | browserbase | cursor. The raw key is stored encrypted in Supabase Vault and never returned; failed probes remain quarantined. Optional baseUrl is accepted only for allow-listed OpenAI-compatible HTTPS providers. Write; NOT idempotent.",
|
|
461
461
|
scope: "mcp:write",
|
|
462
462
|
hints: { readOnly: false, destructive: false, idempotent: false, openWorld: true },
|
|
463
463
|
useCase: "Add a backup Anthropic key to the pool."
|
|
464
464
|
},
|
|
465
|
+
{
|
|
466
|
+
name: "test_byok_key",
|
|
467
|
+
title: "Test an API key",
|
|
468
|
+
description: "Re-test one pooled BYOK credential by key id. A successful provider probe activates the key; auth, quota, and network failures keep it out of the runtime pool. Returns the sanitized validation result and updated key metadata. Write; idempotent.",
|
|
469
|
+
scope: "mcp:write",
|
|
470
|
+
hints: { readOnly: false, destructive: false, idempotent: true, openWorld: true },
|
|
471
|
+
useCase: "Re-test a quarantined OpenAI key after fixing its account quota."
|
|
472
|
+
},
|
|
473
|
+
{
|
|
474
|
+
name: "remove_byok_key",
|
|
475
|
+
title: "Remove an API key",
|
|
476
|
+
description: "Permanently remove one pooled BYOK credential by key id from the authenticated project, including its Vault secret. Write; destructive; idempotent.",
|
|
477
|
+
scope: "mcp:write",
|
|
478
|
+
hints: { readOnly: false, destructive: true, idempotent: true, openWorld: true },
|
|
479
|
+
useCase: "Remove a rotated or compromised provider key from the runtime pool."
|
|
480
|
+
},
|
|
465
481
|
{
|
|
466
482
|
name: "list_pending_review_stories",
|
|
467
483
|
title: "List QA stories pending review",
|
|
@@ -584,8 +600,93 @@ var TDD_TOOL_CATALOG = [
|
|
|
584
600
|
scope: "mcp:read",
|
|
585
601
|
hints: { readOnly: true, idempotent: true, openWorld: true },
|
|
586
602
|
useCase: "Are there any tables without RLS? Show me recent backend errors for this project."
|
|
603
|
+
},
|
|
604
|
+
// ── Meta-tool (context-cost reduction) ───────────────────────────────────
|
|
605
|
+
//
|
|
606
|
+
// Sentry ships `use_sentry` (a single meta-tool an agent calls to get a
|
|
607
|
+
// recommended subset of tools for a given intent) as the primary context-
|
|
608
|
+
// cost reduction lever. We do the same: `use_mushi` returns a curated
|
|
609
|
+
// list of the 6–12 tools most relevant to the caller's stated intent, plus
|
|
610
|
+
// a short orientation block. Agents that call use_mushi first avoid
|
|
611
|
+
// loading 68 tool descriptions up-front, cutting context cost by ~60% for
|
|
612
|
+
// narrow tasks (fix a bug, check status, start a pipeline).
|
|
613
|
+
{
|
|
614
|
+
name: "use_mushi",
|
|
615
|
+
title: "Mushi \u2014 where to start",
|
|
616
|
+
description: 'CALL THIS FIRST if you are new to this Mushi project or unsure which tool to use. Pass your intent as a short natural-language phrase ("fix the top bug", "check what I should work on", "run QA tests", "set up Mushi", \u2026). Returns: (1) a curated list of the 5\u201312 tool names most relevant to that intent, (2) a one-paragraph orientation to the Mushi project and dashboard state, and (3) the single recommended first tool to call. Avoids loading the full 68-tool catalog into context when only a small subset is needed. Read-only; does not call any downstream tools itself.',
|
|
617
|
+
scope: "mcp:read",
|
|
618
|
+
hints: { readOnly: true, idempotent: true, openWorld: false },
|
|
619
|
+
useCase: "What should I do next with Mushi? / Which tools do I need for this task?"
|
|
587
620
|
}
|
|
588
621
|
];
|
|
622
|
+
var USE_MUSHI_INTENTS = {
|
|
623
|
+
fix: {
|
|
624
|
+
label: "Fix a bug",
|
|
625
|
+
tools: [
|
|
626
|
+
"get_recent_reports",
|
|
627
|
+
"get_report",
|
|
628
|
+
"summarize_report_for_fix",
|
|
629
|
+
"dispatch_fix",
|
|
630
|
+
"start_skill_pipeline",
|
|
631
|
+
"checkin_pipeline_step",
|
|
632
|
+
"get_pipeline_run"
|
|
633
|
+
],
|
|
634
|
+
hint: "Call get_recent_reports to find the top unresolved bug, then summarize_report_for_fix before dispatching."
|
|
635
|
+
},
|
|
636
|
+
status: {
|
|
637
|
+
label: "Check project status",
|
|
638
|
+
tools: [
|
|
639
|
+
"get_dashboard",
|
|
640
|
+
"triage_next_steps",
|
|
641
|
+
"get_usage",
|
|
642
|
+
"get_backend_health",
|
|
643
|
+
"activation_status"
|
|
644
|
+
],
|
|
645
|
+
hint: "Call triage_next_steps for a prioritised list of what to work on today."
|
|
646
|
+
},
|
|
647
|
+
setup: {
|
|
648
|
+
label: "Set up Mushi",
|
|
649
|
+
tools: [
|
|
650
|
+
"mushi_setup",
|
|
651
|
+
"activation_status",
|
|
652
|
+
"get_backend_health",
|
|
653
|
+
"list_byok_keys",
|
|
654
|
+
"add_byok_key",
|
|
655
|
+
"test_byok_key",
|
|
656
|
+
"remove_byok_key"
|
|
657
|
+
],
|
|
658
|
+
hint: "Call mushi_setup first \u2014 it diagnoses setup gaps and returns the next command to run."
|
|
659
|
+
},
|
|
660
|
+
qa: {
|
|
661
|
+
label: "Run / review QA tests",
|
|
662
|
+
tools: [
|
|
663
|
+
"list_qa_stories",
|
|
664
|
+
"run_qa_story",
|
|
665
|
+
"list_qa_story_runs",
|
|
666
|
+
"get_qa_story_run",
|
|
667
|
+
"list_pending_review_stories",
|
|
668
|
+
"approve_qa_story",
|
|
669
|
+
"improve_qa_story"
|
|
670
|
+
],
|
|
671
|
+
hint: "Call list_qa_stories to see what test coverage exists; run_qa_story to trigger a run."
|
|
672
|
+
},
|
|
673
|
+
pipeline: {
|
|
674
|
+
label: "Run an agent pipeline / skill",
|
|
675
|
+
tools: [
|
|
676
|
+
"list_skills",
|
|
677
|
+
"get_skill",
|
|
678
|
+
"start_skill_pipeline",
|
|
679
|
+
"checkin_pipeline_step",
|
|
680
|
+
"get_pipeline_run"
|
|
681
|
+
],
|
|
682
|
+
hint: "Call list_skills to find the right skill, then start_skill_pipeline."
|
|
683
|
+
},
|
|
684
|
+
audit: {
|
|
685
|
+
label: "Audit / health check",
|
|
686
|
+
tools: ["run_fullstack_audit", "get_backend_health", "get_dashboard", "get_usage"],
|
|
687
|
+
hint: "Call run_fullstack_audit for a full-stack health scorecard."
|
|
688
|
+
}
|
|
689
|
+
};
|
|
589
690
|
var CODEBASE_TOOL_CATALOG = [
|
|
590
691
|
{
|
|
591
692
|
name: "ask_codebase",
|
|
@@ -651,5 +752,6 @@ export {
|
|
|
651
752
|
RESOURCE_CATALOG,
|
|
652
753
|
PROMPT_CATALOG,
|
|
653
754
|
TDD_TOOL_CATALOG,
|
|
755
|
+
USE_MUSHI_INTENTS,
|
|
654
756
|
CODEBASE_TOOL_CATALOG
|
|
655
757
|
};
|
|
@@ -98,8 +98,10 @@ var TOOL_FEATURE_MAP = {
|
|
|
98
98
|
start_skill_pipeline: "skills",
|
|
99
99
|
get_pipeline_run: "skills",
|
|
100
100
|
checkin_pipeline_step: "skills",
|
|
101
|
-
list_byok_keys: "
|
|
102
|
-
add_byok_key: "
|
|
101
|
+
list_byok_keys: "setup",
|
|
102
|
+
add_byok_key: "setup",
|
|
103
|
+
test_byok_key: "setup",
|
|
104
|
+
remove_byok_key: "setup",
|
|
103
105
|
// audit
|
|
104
106
|
run_fullstack_audit: "audit",
|
|
105
107
|
get_backend_health: "audit",
|
package/dist/clients.d.ts
CHANGED
|
@@ -40,6 +40,13 @@ import { FeatureGroup } from './feature-groups.js';
|
|
|
40
40
|
* - The `cliIde` field drives `mushi setup --ide <cliIde>` in the CLI lane.
|
|
41
41
|
*/
|
|
42
42
|
|
|
43
|
+
/**
|
|
44
|
+
* Pinned npm spec written into persistent MCP configs (mcp.json, settings.json).
|
|
45
|
+
* Pinning avoids the supply-chain and cold-start costs of `@latest` on every
|
|
46
|
+
* editor launch. Synced to package.json by `scripts/sync-mcp-pin.mjs` — never
|
|
47
|
+
* hand-edit the version.
|
|
48
|
+
*/
|
|
49
|
+
declare const MCP_PIN_SPEC = "@mushi-mushi/mcp@0.20.1";
|
|
43
50
|
interface StdioConfig {
|
|
44
51
|
command: string;
|
|
45
52
|
args: string[];
|
|
@@ -112,4 +119,4 @@ declare const MCP_CLIENTS: McpClientDef[];
|
|
|
112
119
|
/** Look up a client by id — throws if not found. */
|
|
113
120
|
declare function getMcpClient(id: McpClientId): McpClientDef;
|
|
114
121
|
|
|
115
|
-
export { MCP_CLIENTS, type McpBuildInput, type McpBuildResult, type McpClientDef, type McpClientId, type McpInstallMethod, buildHttpConfigObj as buildRawHttpConfig, buildStdioConfigObj as buildRawStdioConfig, getMcpClient, projectServerName };
|
|
122
|
+
export { MCP_CLIENTS, MCP_PIN_SPEC, type McpBuildInput, type McpBuildResult, type McpClientDef, type McpClientId, type McpInstallMethod, buildHttpConfigObj as buildRawHttpConfig, buildStdioConfigObj as buildRawStdioConfig, getMcpClient, projectServerName };
|
package/dist/clients.js
CHANGED
|
@@ -5,9 +5,10 @@ import {
|
|
|
5
5
|
DEFAULT_FEATURE_GROUPS,
|
|
6
6
|
appendFeaturesToUrl,
|
|
7
7
|
featuresQueryString
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-ZSVRLSW5.js";
|
|
9
9
|
|
|
10
10
|
// src/clients.ts
|
|
11
|
+
var MCP_PIN_SPEC = "@mushi-mushi/mcp@0.20.1";
|
|
11
12
|
function projectServerName(projectId, projectName) {
|
|
12
13
|
const nameSlug = projectName.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, "").slice(0, 22);
|
|
13
14
|
const idSuffix = projectId.replace(/-/g, "").slice(0, 6);
|
|
@@ -22,7 +23,7 @@ function buildStdioConfigObj(projectId, apiKey, apiEndpoint, features = DEFAULT_
|
|
|
22
23
|
if (projectId) env.MUSHI_PROJECT_ID = projectId;
|
|
23
24
|
return {
|
|
24
25
|
command: "npx",
|
|
25
|
-
args: ["-y",
|
|
26
|
+
args: ["-y", MCP_PIN_SPEC],
|
|
26
27
|
env,
|
|
27
28
|
icon: MUSHI_ICON_PNG_URL
|
|
28
29
|
};
|
|
@@ -146,7 +147,7 @@ var MCP_CLIENTS = [
|
|
|
146
147
|
if (projectId) env.MUSHI_PROJECT_ID = projectId;
|
|
147
148
|
const clineConfig = {
|
|
148
149
|
mcpServers: {
|
|
149
|
-
[name]: { command: "npx", args: ["-y",
|
|
150
|
+
[name]: { command: "npx", args: ["-y", MCP_PIN_SPEC], env }
|
|
150
151
|
}
|
|
151
152
|
};
|
|
152
153
|
return {
|
|
@@ -192,7 +193,7 @@ var MCP_CLIENTS = [
|
|
|
192
193
|
if (projectId) env.MUSHI_PROJECT_ID = projectId;
|
|
193
194
|
const desktopConfig = {
|
|
194
195
|
mcpServers: {
|
|
195
|
-
[name]: { command: "npx", args: ["-y",
|
|
196
|
+
[name]: { command: "npx", args: ["-y", MCP_PIN_SPEC], env }
|
|
196
197
|
}
|
|
197
198
|
};
|
|
198
199
|
return {
|
|
@@ -223,7 +224,7 @@ var MCP_CLIENTS = [
|
|
|
223
224
|
[name]: {
|
|
224
225
|
command: {
|
|
225
226
|
path: "npx",
|
|
226
|
-
args: ["-y",
|
|
227
|
+
args: ["-y", MCP_PIN_SPEC],
|
|
227
228
|
env
|
|
228
229
|
},
|
|
229
230
|
settings: {}
|
|
@@ -264,6 +265,7 @@ function getMcpClient(id) {
|
|
|
264
265
|
}
|
|
265
266
|
export {
|
|
266
267
|
MCP_CLIENTS,
|
|
268
|
+
MCP_PIN_SPEC,
|
|
267
269
|
buildHttpConfigObj as buildRawHttpConfig,
|
|
268
270
|
buildStdioConfigObj as buildRawStdioConfig,
|
|
269
271
|
getMcpClient,
|