@extension.dev/mcp 9.0.0 → 10.0.0
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/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/CHANGELOG.md +47 -0
- package/claude/rules/mcp-tools.md +22 -10
- package/dist/module.js +2083 -1020
- package/dist/src/lib/act.d.ts +4 -1
- package/dist/src/lib/boot-verdict.d.ts +53 -0
- package/dist/src/lib/bridge-tabs.d.ts +2 -2
- package/dist/src/lib/envelope.d.ts +35 -0
- package/dist/src/lib/legacy-stdout.d.ts +7 -0
- package/package.json +4 -4
- package/server.json +2 -2
package/dist/src/lib/act.d.ts
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
export declare function toMcpSpeak(text: string): string;
|
|
2
|
-
export declare function runActVerb(args: string[], projectPath: string, timeoutMs?: number): Promise<string>;
|
|
2
|
+
export declare function runActVerb(args: string[], projectPath: string, timeoutMs?: number, tool?: string): Promise<string>;
|
|
3
|
+
export declare function addWarning(frame: any, text: unknown): void;
|
|
4
|
+
export declare function actFrameJson(frame: unknown): string;
|
|
5
|
+
export declare function patchValue(frame: any, patch: Record<string, unknown>): void;
|
|
3
6
|
export interface ActArgs {
|
|
4
7
|
projectPath: string;
|
|
5
8
|
browser?: string;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import type { ChildProcess } from "node:child_process";
|
|
2
|
+
export interface ProfileLockOwner {
|
|
3
|
+
host?: string;
|
|
4
|
+
pid?: number;
|
|
5
|
+
}
|
|
6
|
+
export type BootVerdict = {
|
|
7
|
+
kind: "alive";
|
|
8
|
+
} | {
|
|
9
|
+
kind: "exited";
|
|
10
|
+
exitCode: number | null;
|
|
11
|
+
signal: string | null;
|
|
12
|
+
} | {
|
|
13
|
+
kind: "compile-failed";
|
|
14
|
+
message?: string;
|
|
15
|
+
compileErrors: string[];
|
|
16
|
+
} | {
|
|
17
|
+
kind: "browser-exited";
|
|
18
|
+
stamp: {
|
|
19
|
+
code?: string;
|
|
20
|
+
browserExitCode?: number | null;
|
|
21
|
+
browserExitedAt?: string;
|
|
22
|
+
};
|
|
23
|
+
} | {
|
|
24
|
+
kind: "profile-locked";
|
|
25
|
+
owner: ProfileLockOwner | null;
|
|
26
|
+
message?: string;
|
|
27
|
+
lockedAt?: string;
|
|
28
|
+
};
|
|
29
|
+
export interface BootReading {
|
|
30
|
+
verdict: BootVerdict;
|
|
31
|
+
/** The CLI stamped a schema-1 ready contract, so no prose was read. */
|
|
32
|
+
machineContract: boolean;
|
|
33
|
+
/** Denoised session-log tail, evidence of last resort. Never branched on. */
|
|
34
|
+
output: string;
|
|
35
|
+
warnings: string[];
|
|
36
|
+
}
|
|
37
|
+
export interface PollOptions {
|
|
38
|
+
child: ChildProcess;
|
|
39
|
+
readOutput: () => string;
|
|
40
|
+
budgetMs: number;
|
|
41
|
+
since: number;
|
|
42
|
+
/** A build-only session never launches a browser, so it has no browser legs. */
|
|
43
|
+
noBrowser?: boolean;
|
|
44
|
+
intervalMs?: number;
|
|
45
|
+
}
|
|
46
|
+
export declare function readyContractPath(projectPath: string, browser: string): string;
|
|
47
|
+
export declare function speaksMachineContract(contract: unknown): boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Poll the dev server's own contract for a boot verdict, and only fall back to
|
|
50
|
+
* reading its output when the contract never lands. Replaces a blind sleep plus
|
|
51
|
+
* a regex over first-party copy.
|
|
52
|
+
*/
|
|
53
|
+
export declare function pollBootVerdict(projectPath: string, browser: string, options: PollOptions): Promise<BootReading>;
|
|
@@ -3,12 +3,12 @@ export interface BridgeTab {
|
|
|
3
3
|
url: string;
|
|
4
4
|
title: string;
|
|
5
5
|
}
|
|
6
|
-
export declare function listBridgeTabs(projectPath: string, browser: string, timeout?: number): Promise<{
|
|
6
|
+
export declare function listBridgeTabs(projectPath: string, browser: string, timeout?: number, tool?: string): Promise<{
|
|
7
7
|
tabs: BridgeTab[];
|
|
8
8
|
} | {
|
|
9
9
|
error: string;
|
|
10
10
|
}>;
|
|
11
11
|
export declare function matchTabsByUrl(tabs: BridgeTab[], needle: string): BridgeTab[];
|
|
12
12
|
export declare function pollForBridgeTab(projectPath: string, browser: string, url: string, budgetMs: number): Promise<BridgeTab | null>;
|
|
13
|
-
export declare function navigateToUrlViaBridge(projectPath: string, browser: string, url: string, timeout?: number): Promise<string>;
|
|
13
|
+
export declare function navigateToUrlViaBridge(projectPath: string, browser: string, url: string, timeout?: number, tool?: string): Promise<string>;
|
|
14
14
|
export declare function resolveBridgeBaseUrl(projectPath: string, browser: string, timeout?: number): Promise<string | null>;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
export declare const ENVELOPE_SCHEMA: 1;
|
|
2
|
+
export type ErrorCode = "E_AMBIGUOUS_TARGET" | "E_AUTH_DENIED" | "E_AUTH_EXPIRED" | "E_AUTH_FAILED" | "E_AUTH_PENDING" | "E_AUTH_REQUIRED" | "E_BAD_MANIFEST" | "E_BAD_REQUEST" | "E_BRIDGE" | "E_BROWSER_EXITED" | "E_BROWSER_INSTALL" | "E_BROWSER_UNINSTALL" | "E_BUILD_FAILED" | "E_CARRIER_IN_DIST" | "E_CDP" | "E_CLI" | "E_COMPILE" | "E_CONFIG" | "E_CONTRACT_ERROR" | "E_CONTROL_CHANNEL" | "E_ENTRYPOINT_MISSING" | "E_FIRST_COMPILE" | "E_INPUT_VALIDATION" | "E_INTERNAL" | "E_LOGS_MISSING" | "E_MANIFEST_BLOCKING" | "E_MANIFEST_NOT_FOUND" | "E_NAVIGATE_ERROR" | "E_NAVIGATE_FAILED" | "E_NETWORK" | "E_NO_CONTROL_CHANNEL" | "E_NO_DIST" | "E_NO_EXTENSION_ID" | "E_NO_MATCHING_TARGET" | "E_NO_REFERENCE_TEMPLATE" | "E_NO_SESSION" | "E_NO_SURFACE_DOCUMENT" | "E_NO_TARGET" | "E_NOT_ATTACHED" | "E_PARSE" | "E_PLATFORM" | "E_PROFILE_LOCKED" | "E_RDP" | "E_SCAFFOLD_FAILED" | "E_SCAFFOLD_INCOMPLETE" | "E_SESSION_EXISTS" | "E_SESSION_EXITED" | "E_STALE_CONTRACT" | "E_SURFACE_DID_NOT_OPEN" | "E_TEMPLATE_FETCH" | "E_TEMPLATE_NOT_FOUND" | "E_UNKNOWN_COMMAND" | "E_UNKNOWN_TOOL" | "E_UNSUPPORTED_BROWSER" | "E_WAIT_TIMEOUT";
|
|
3
|
+
export declare const ERROR_CODES: ErrorCode[];
|
|
4
|
+
export interface EnvelopeError {
|
|
5
|
+
code: ErrorCode | string;
|
|
6
|
+
message: string;
|
|
7
|
+
name?: string;
|
|
8
|
+
engine?: string | null;
|
|
9
|
+
hint?: string;
|
|
10
|
+
[key: string]: unknown;
|
|
11
|
+
}
|
|
12
|
+
export interface Envelope {
|
|
13
|
+
schema: typeof ENVELOPE_SCHEMA;
|
|
14
|
+
ok: boolean;
|
|
15
|
+
command: string;
|
|
16
|
+
status: string;
|
|
17
|
+
value: unknown;
|
|
18
|
+
error: EnvelopeError | null;
|
|
19
|
+
truncated?: boolean;
|
|
20
|
+
hint?: string;
|
|
21
|
+
warnings: string[];
|
|
22
|
+
}
|
|
23
|
+
export interface EnvelopeInit {
|
|
24
|
+
ok: boolean;
|
|
25
|
+
command: string;
|
|
26
|
+
status: string;
|
|
27
|
+
value?: unknown;
|
|
28
|
+
error?: EnvelopeError | null;
|
|
29
|
+
truncated?: boolean;
|
|
30
|
+
hint?: string;
|
|
31
|
+
warnings?: (string | null | undefined | false)[];
|
|
32
|
+
}
|
|
33
|
+
export declare function envelopeObject(init: EnvelopeInit): Envelope;
|
|
34
|
+
export declare function envelope(init: EnvelopeInit): string;
|
|
35
|
+
export declare function isEnvelope(frame: unknown): frame is Envelope;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** @deprecated see the module note. */
|
|
2
|
+
export declare function denoiseCliLog(raw: string): string;
|
|
3
|
+
/** @deprecated Replaced by `ready.json` `status:"error"`. */
|
|
4
|
+
export declare function legacyCompileScrape(cleanOutput: string): boolean;
|
|
5
|
+
/** @deprecated Replaced by `ready.json` `code:"profile_locked"`. */
|
|
6
|
+
export declare function legacyProfileLockScrape(cleanOutput: string): boolean;
|
|
7
|
+
export declare const LEGACY_FIDELITY_WARNING = "This session ran a CLI that does not stamp the machine contract, so the boot verdict was read from the dev server's output instead of its ready contract. Diagnostics are less precise: compile errors come back as a text tail rather than a list. Upgrade the project's extension dependency to get the precise verdict.";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@extension.dev/mcp",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "10.0.0",
|
|
5
5
|
"description": "MCP server that lets AI agents (Claude Code, Claude Desktop, Cursor, Copilot, Codex) build, run, inspect, and publish browser extensions. 28 tools for scaffolding, live DOM inspection, log streaming, and store-ready builds across Chrome, Edge, Firefox, Safari, and every Chromium- or Gecko-based browser (Brave, Opera, Vivaldi, Yandex, Waterfox, LibreWolf). Powered by extension.dev and Extension.js.",
|
|
6
6
|
"mcpName": "io.github.extensiondev/mcp",
|
|
7
7
|
"license": "Apache-2.0",
|
|
@@ -91,9 +91,9 @@
|
|
|
91
91
|
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
92
92
|
"browser-extension-manifest-fields": "^2.2.9",
|
|
93
93
|
"cross-spawn": "^7.0.6",
|
|
94
|
-
"extension-create": "4.0.
|
|
95
|
-
"extension-develop": "4.0.
|
|
96
|
-
"extension-install": "4.0.
|
|
94
|
+
"extension-create": "4.0.17",
|
|
95
|
+
"extension-develop": "4.0.17",
|
|
96
|
+
"extension-install": "4.0.17",
|
|
97
97
|
"ws": "^8.20.0"
|
|
98
98
|
},
|
|
99
99
|
"devDependencies": {
|
package/server.json
CHANGED
|
@@ -7,13 +7,13 @@
|
|
|
7
7
|
"source": "github"
|
|
8
8
|
},
|
|
9
9
|
"websiteUrl": "https://extension.dev",
|
|
10
|
-
"version": "
|
|
10
|
+
"version": "10.0.0",
|
|
11
11
|
"packages": [
|
|
12
12
|
{
|
|
13
13
|
"registryType": "npm",
|
|
14
14
|
"registryBaseUrl": "https://registry.npmjs.org",
|
|
15
15
|
"identifier": "@extension.dev/mcp",
|
|
16
|
-
"version": "
|
|
16
|
+
"version": "10.0.0",
|
|
17
17
|
"runtimeHint": "npx",
|
|
18
18
|
"transport": {
|
|
19
19
|
"type": "stdio"
|