@extension.dev/mcp 10.0.0 → 10.2.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 +2 -2
- package/.claude-plugin/plugin.json +2 -2
- package/CHANGELOG.md +120 -0
- package/README.md +10 -9
- package/bin/extension-mcp.js +24 -2
- package/claude/ARCHITECTURE.md +1 -1
- package/claude/CLAUDE.md +5 -5
- package/claude/rules/cross-browser.md +4 -2
- package/claude/rules/mcp-tools.md +5 -5
- package/dist/module.js +2439 -996
- package/dist/src/index.d.ts +7 -0
- package/dist/src/lib/artifacts-api.d.ts +2 -0
- package/dist/src/lib/boot-verdict.d.ts +3 -10
- package/dist/src/lib/carrier-exit.d.ts +8 -0
- package/dist/src/lib/carrier-registry.d.ts +4 -0
- package/dist/src/lib/carrier.d.ts +8 -0
- package/dist/src/lib/engine-version.d.ts +24 -0
- package/dist/src/lib/envelope.d.ts +7 -1
- package/dist/src/lib/exec.d.ts +4 -0
- package/dist/src/lib/guest-load-oracle.d.ts +1 -0
- package/dist/src/lib/login-flow.d.ts +2 -1
- package/dist/src/lib/process-manager.d.ts +4 -2
- package/dist/src/lib/server-identity.d.ts +16 -0
- package/dist/src/lib/session-browser.d.ts +1 -1
- package/dist/src/lib/session-paths.d.ts +12 -0
- package/dist/src/lib/share-cors-probe.d.ts +17 -0
- package/dist/src/lib/template-artifact-source.d.ts +1 -1
- package/dist/src/lib/zip-entries.d.ts +5 -0
- package/dist/src/tools/build.d.ts +23 -0
- package/dist/src/tools/inspect-schema.d.ts +48 -0
- package/dist/src/tools/inspect.d.ts +2 -48
- package/dist/src/tools/logs-constants.d.ts +2 -2
- package/dist/src/tools/logs-filter.d.ts +3 -1
- package/dist/src/tools/logs.d.ts +8 -0
- package/dist/src/tools/submit.d.ts +5 -0
- package/dist/src/tools/whoami.d.ts +3 -1
- package/package.json +21 -7
- package/server.json +2 -2
package/dist/src/index.d.ts
CHANGED
|
@@ -7,5 +7,12 @@ export interface ToolModule {
|
|
|
7
7
|
handler: (args: any) => Promise<string>;
|
|
8
8
|
}
|
|
9
9
|
export declare const tools: ToolModule[];
|
|
10
|
+
export declare function toolResultFrame(result: string): {
|
|
11
|
+
content: Array<{
|
|
12
|
+
type: "text";
|
|
13
|
+
text: string;
|
|
14
|
+
}>;
|
|
15
|
+
isError?: boolean;
|
|
16
|
+
};
|
|
10
17
|
export declare function startServer(): Promise<void>;
|
|
11
18
|
export declare function runCli(cmd: string, args: string[]): Promise<number>;
|
|
@@ -37,6 +37,7 @@ export interface ArtifactListing {
|
|
|
37
37
|
matched: number;
|
|
38
38
|
limit: number;
|
|
39
39
|
truncated: boolean;
|
|
40
|
+
truncatedReported: boolean;
|
|
40
41
|
scanned: number;
|
|
41
42
|
}
|
|
42
43
|
export interface ArtifactRevocation {
|
|
@@ -56,6 +57,7 @@ export type ArtifactsOutcome<T> = {
|
|
|
56
57
|
};
|
|
57
58
|
};
|
|
58
59
|
export declare function parseArtifactRef(input: string): string | null;
|
|
60
|
+
export declare function wwwRevokeUrl(value: string): string;
|
|
59
61
|
export declare function listArtifacts(options?: {
|
|
60
62
|
limit?: number;
|
|
61
63
|
liveOnly?: boolean;
|
|
@@ -5,6 +5,8 @@ export interface ProfileLockOwner {
|
|
|
5
5
|
}
|
|
6
6
|
export type BootVerdict = {
|
|
7
7
|
kind: "alive";
|
|
8
|
+
} | {
|
|
9
|
+
kind: "silent-within-budget";
|
|
8
10
|
} | {
|
|
9
11
|
kind: "exited";
|
|
10
12
|
exitCode: number | null;
|
|
@@ -28,10 +30,8 @@ export type BootVerdict = {
|
|
|
28
30
|
};
|
|
29
31
|
export interface BootReading {
|
|
30
32
|
verdict: BootVerdict;
|
|
31
|
-
/** The CLI stamped a schema-1 ready contract, so no prose was read. */
|
|
32
33
|
machineContract: boolean;
|
|
33
|
-
|
|
34
|
-
output: string;
|
|
34
|
+
evidenceTail: string;
|
|
35
35
|
warnings: string[];
|
|
36
36
|
}
|
|
37
37
|
export interface PollOptions {
|
|
@@ -39,15 +39,8 @@ export interface PollOptions {
|
|
|
39
39
|
readOutput: () => string;
|
|
40
40
|
budgetMs: number;
|
|
41
41
|
since: number;
|
|
42
|
-
/** A build-only session never launches a browser, so it has no browser legs. */
|
|
43
42
|
noBrowser?: boolean;
|
|
44
43
|
intervalMs?: number;
|
|
45
44
|
}
|
|
46
|
-
export declare function readyContractPath(projectPath: string, browser: string): string;
|
|
47
45
|
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
46
|
export declare function pollBootVerdict(projectPath: string, browser: string, options: PollOptions): Promise<BootReading>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { type CarrierRemoval } from "./carrier";
|
|
2
|
+
export type CarrierSweepEntry = CarrierRemoval & {
|
|
3
|
+
projectPath: string;
|
|
4
|
+
};
|
|
5
|
+
export declare function sweepCarriers(projectPaths: string[]): CarrierSweepEntry[];
|
|
6
|
+
export declare function sweepCarriersPlacedHere(): CarrierSweepEntry[];
|
|
7
|
+
export declare function installCarrierExitCleanup(): void;
|
|
8
|
+
export declare function uninstallCarrierExitCleanup(): void;
|
|
@@ -2,6 +2,14 @@ export declare const CARRIER_DIR_NAME = "extension-dev-live-preview";
|
|
|
2
2
|
export declare const CARRIER_EXTENSION_ID = "ibppeifnekhjjjmpjfiobccjlicbmgcb";
|
|
3
3
|
export declare function carrierPath(projectPath: string): string;
|
|
4
4
|
export declare function isManagedCarrier(projectPath: string): boolean;
|
|
5
|
+
export type CarrierClaim = {
|
|
6
|
+
ours: true;
|
|
7
|
+
how: "marker" | "payload" | "partial";
|
|
8
|
+
} | {
|
|
9
|
+
ours: false;
|
|
10
|
+
how: "foreign";
|
|
11
|
+
};
|
|
12
|
+
export declare function claimCarrier(target: string): CarrierClaim;
|
|
5
13
|
export type CarrierRemoval = {
|
|
6
14
|
removed: boolean;
|
|
7
15
|
path: string;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export declare const OUTPUT_JSON_FLOOR: {
|
|
2
|
+
readonly act: "3.18.1";
|
|
3
|
+
readonly doctor: "4.0.11";
|
|
4
|
+
readonly dev: "4.0.17";
|
|
5
|
+
readonly build: "4.0.17";
|
|
6
|
+
};
|
|
7
|
+
export type OutputJsonCommand = keyof typeof OUTPUT_JSON_FLOOR;
|
|
8
|
+
export declare function parseVersion(text: string): string | null;
|
|
9
|
+
export declare function compareVersions(a: string, b: string): number | null;
|
|
10
|
+
export interface EngineFacts {
|
|
11
|
+
version: string | null;
|
|
12
|
+
outputJsonCommands: readonly string[] | null;
|
|
13
|
+
}
|
|
14
|
+
export declare function resetEngineVersionCache(): void;
|
|
15
|
+
export declare function resolvedEngineFacts(projectPath?: string): Promise<EngineFacts>;
|
|
16
|
+
export declare function resolvedEngineVersion(projectPath?: string): Promise<string | null>;
|
|
17
|
+
export interface OutputJsonVerdict {
|
|
18
|
+
supported: boolean | null;
|
|
19
|
+
version: string | null;
|
|
20
|
+
floor: string;
|
|
21
|
+
}
|
|
22
|
+
export declare function outputJsonVerdict(command: OutputJsonCommand, projectPath?: string): Promise<OutputJsonVerdict>;
|
|
23
|
+
export declare function refusedTheOutputFlag(stderr: string): boolean;
|
|
24
|
+
export declare function outputFlagRefusalMessage(command: OutputJsonCommand, cliName: string, projectPath?: string): Promise<string>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export declare const ENVELOPE_SCHEMA: 1;
|
|
2
|
-
export
|
|
2
|
+
export declare const DECISION_D6 = "The MCP tool name owns the envelope `command` key; forking the key to `tool` would fork the schema the checksum test pins.";
|
|
3
|
+
export type ErrorCode = "E_AMBIGUOUS_TARGET" | "E_AUTH_DENIED" | "E_AUTH_EXPIRED" | "E_AUTH_FAILED" | "E_AUTH_PENDING" | "E_AUTH_REQUIRED" | "E_BAD_HOST_URL" | "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_CONTROL_ENVELOPE" | "E_ENGINE_TOO_OLD" | "E_ENTRYPOINT_MISSING" | "E_FIRST_COMPILE" | "E_INPUT_VALIDATION" | "E_INTERNAL" | "E_INVALID_BUNDLE_ID" | "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_PREVIEW_HOST_UNREACHABLE" | "E_PROFILE_LOCKED" | "E_RDP" | "E_SAFARI_ONLY_OPTION" | "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
4
|
export declare const ERROR_CODES: ErrorCode[];
|
|
4
5
|
export interface EnvelopeError {
|
|
5
6
|
code: ErrorCode | string;
|
|
@@ -32,4 +33,9 @@ export interface EnvelopeInit {
|
|
|
32
33
|
}
|
|
33
34
|
export declare function envelopeObject(init: EnvelopeInit): Envelope;
|
|
34
35
|
export declare function envelope(init: EnvelopeInit): string;
|
|
36
|
+
export declare function sessionCommandSinceEnvelopeOwnsCommand(contract: {
|
|
37
|
+
command?: string;
|
|
38
|
+
}): {
|
|
39
|
+
sessionCommand?: string;
|
|
40
|
+
};
|
|
35
41
|
export declare function isEnvelope(frame: unknown): frame is Envelope;
|
package/dist/src/lib/exec.d.ts
CHANGED
|
@@ -4,6 +4,8 @@ export interface CliResult {
|
|
|
4
4
|
stdout: string;
|
|
5
5
|
stderr: string;
|
|
6
6
|
}
|
|
7
|
+
export declare function pinnedCliVersion(): string;
|
|
8
|
+
export declare function exactVersion(spec: string): string;
|
|
7
9
|
export declare function resolveExtensionInvocation(projectDir?: string): {
|
|
8
10
|
command: string;
|
|
9
11
|
prefixArgs: string[];
|
|
@@ -16,8 +18,10 @@ export interface SpawnedCli {
|
|
|
16
18
|
child: ChildProcess;
|
|
17
19
|
logPath: string;
|
|
18
20
|
readOutput: () => string;
|
|
21
|
+
spawnError?: () => Error | null;
|
|
19
22
|
}
|
|
20
23
|
export declare function spawnExtensionCli(args: string[], options?: {
|
|
21
24
|
cwd?: string;
|
|
22
25
|
projectDir?: string;
|
|
23
26
|
}): SpawnedCli;
|
|
27
|
+
export declare function spawnFailedEnvelope(command: string, spawned: SpawnedCli): Promise<string>;
|
|
@@ -2,7 +2,7 @@ import { type StoredCredentials } from "./credentials";
|
|
|
2
2
|
export declare function tokenTtlNote(workspaceSlug?: string, projectSlug?: string): string;
|
|
3
3
|
type FetchImpl = typeof fetch;
|
|
4
4
|
export declare function resolveApiBase(api?: string): string;
|
|
5
|
-
export declare function safeApiBase(raw: string): {
|
|
5
|
+
export declare function safeApiBase(raw: string, callerSupplied?: string): {
|
|
6
6
|
ok: true;
|
|
7
7
|
base: string;
|
|
8
8
|
} | {
|
|
@@ -17,6 +17,7 @@ export interface LoginConfig {
|
|
|
17
17
|
export declare function fetchLoginConfig(apiBase: string, fetchImpl?: FetchImpl): Promise<LoginConfig>;
|
|
18
18
|
export declare function persistTokenResponse(args: {
|
|
19
19
|
apiBase: string;
|
|
20
|
+
project: string;
|
|
20
21
|
data: Record<string, unknown>;
|
|
21
22
|
}): StoredCredentials;
|
|
22
23
|
export {};
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import type { ProcessInfo } from "./types";
|
|
2
|
-
export declare function
|
|
2
|
+
export declare function sessionStateDir(): string;
|
|
3
|
+
export declare function removeSessionMarker(projectPath: string, browser: string, pid?: number): void;
|
|
3
4
|
export declare function listSessionMarkers(): ProcessInfo[];
|
|
4
5
|
export declare function registerSession(info: ProcessInfo): void;
|
|
6
|
+
export declare function sessionSinceMs(projectPath: string, browser: string): number | null;
|
|
5
7
|
export declare function getSession(projectPath: string, browser: string): ProcessInfo | undefined;
|
|
6
8
|
export declare function findSessionInfo(projectPath: string, browser: string): ProcessInfo | undefined;
|
|
7
|
-
export declare function removeSession(projectPath: string, browser: string): void;
|
|
9
|
+
export declare function removeSession(projectPath: string, browser: string, pid?: number): void;
|
|
8
10
|
export declare function listSessions(): ProcessInfo[];
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export type ServerIdentityAnswer = {
|
|
2
|
+
kind: "confirmed";
|
|
3
|
+
login: string;
|
|
4
|
+
live: boolean;
|
|
5
|
+
} | {
|
|
6
|
+
kind: "refused";
|
|
7
|
+
} | {
|
|
8
|
+
kind: "unavailable";
|
|
9
|
+
detail: string;
|
|
10
|
+
};
|
|
11
|
+
export declare function askServerIdentity(args: {
|
|
12
|
+
apiBase: string;
|
|
13
|
+
token: string;
|
|
14
|
+
fetchImpl?: typeof fetch;
|
|
15
|
+
timeoutMs?: number;
|
|
16
|
+
}): Promise<ServerIdentityAnswer>;
|
|
@@ -6,7 +6,7 @@ export declare function knownSessionBrowsers(projectPath: string): string[];
|
|
|
6
6
|
export interface LiveSession {
|
|
7
7
|
browser: string;
|
|
8
8
|
pid: number;
|
|
9
|
-
source: "registry" | "contract";
|
|
9
|
+
source: "registry" | "contract" | "marker";
|
|
10
10
|
}
|
|
11
11
|
export declare function liveProjectSessions(projectPath: string): LiveSession[];
|
|
12
12
|
export declare function deadReadySession(projectPath: string): {
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export { actionsPath, browserArtifactsDir, buildSummaryPath, eventsPath, logsPath, readyContractPath, sessionArtifactsRootDir, sessionStateDir, } from "extension-develop/bridge";
|
|
2
|
+
export { readReadyContract, type ReadyContractInfo, } from "extension-develop/bridge";
|
|
3
|
+
export declare function sessionPathHint(file: string): string;
|
|
4
|
+
export declare function profilesRootDir(projectPath: string): string;
|
|
5
|
+
export declare function browserProfileRootDir(projectPath: string, browser: string): string;
|
|
6
|
+
export declare const PERSISTED_PROFILE_DIR_NAME = "dev";
|
|
7
|
+
export interface ProfileRemediationInput {
|
|
8
|
+
projectPath: string;
|
|
9
|
+
browser: string;
|
|
10
|
+
profile?: string;
|
|
11
|
+
}
|
|
12
|
+
export declare function profileRemediation(input: ProfileRemediationInput): string;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
type FetchImpl = typeof fetch;
|
|
2
|
+
export interface ShareCorsVerdict {
|
|
3
|
+
ok: boolean;
|
|
4
|
+
checkedUrl: string;
|
|
5
|
+
origin: string;
|
|
6
|
+
finalUrl: string;
|
|
7
|
+
finalStatus: number;
|
|
8
|
+
redirects: number;
|
|
9
|
+
allowOrigin: string | null;
|
|
10
|
+
reason: string;
|
|
11
|
+
}
|
|
12
|
+
export declare function probeShareCors(options: {
|
|
13
|
+
zipUrl: string;
|
|
14
|
+
origin: string;
|
|
15
|
+
fetchImpl?: FetchImpl;
|
|
16
|
+
}): Promise<ShareCorsVerdict>;
|
|
17
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const PINNED_COMMIT = "
|
|
1
|
+
export declare const PINNED_COMMIT = "520a8ede767fe1937c7184f4857408caf9c5934f";
|
|
2
2
|
export declare function templateMetaUrls(): Promise<string[]>;
|
|
3
3
|
export declare function stripTemplatePathPrefix(slug: string, relativePath: string): string;
|
|
4
4
|
export declare function templateFileUrls(slug: string, relativePath: string): Promise<string[]>;
|
|
@@ -48,10 +48,29 @@ export declare const schema: {
|
|
|
48
48
|
default: boolean;
|
|
49
49
|
description: string;
|
|
50
50
|
};
|
|
51
|
+
appName: {
|
|
52
|
+
type: string;
|
|
53
|
+
description: string;
|
|
54
|
+
};
|
|
55
|
+
bundleId: {
|
|
56
|
+
type: string;
|
|
57
|
+
description: string;
|
|
58
|
+
};
|
|
59
|
+
macOsOnly: {
|
|
60
|
+
type: string;
|
|
61
|
+
default: boolean;
|
|
62
|
+
description: string;
|
|
63
|
+
};
|
|
64
|
+
forceRegenerate: {
|
|
65
|
+
type: string;
|
|
66
|
+
default: boolean;
|
|
67
|
+
description: string;
|
|
68
|
+
};
|
|
51
69
|
};
|
|
52
70
|
required: string[];
|
|
53
71
|
};
|
|
54
72
|
};
|
|
73
|
+
export declare const BUNDLE_ID_PATTERN: RegExp;
|
|
55
74
|
export declare function handler(args: {
|
|
56
75
|
projectPath: string;
|
|
57
76
|
browser?: string;
|
|
@@ -62,4 +81,8 @@ export declare function handler(args: {
|
|
|
62
81
|
silent?: boolean;
|
|
63
82
|
mode?: "development" | "production" | "none";
|
|
64
83
|
skipValidation?: boolean;
|
|
84
|
+
appName?: string;
|
|
85
|
+
bundleId?: string;
|
|
86
|
+
macOsOnly?: boolean;
|
|
87
|
+
forceRegenerate?: boolean;
|
|
65
88
|
}): Promise<string>;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
export declare const schema: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
inputSchema: {
|
|
5
|
+
type: "object";
|
|
6
|
+
properties: {
|
|
7
|
+
projectPath: {
|
|
8
|
+
readonly type: "string";
|
|
9
|
+
readonly description: "Extension project root (needs a live dev session)";
|
|
10
|
+
};
|
|
11
|
+
url: {
|
|
12
|
+
type: string;
|
|
13
|
+
description: string;
|
|
14
|
+
};
|
|
15
|
+
probe: {
|
|
16
|
+
type: string;
|
|
17
|
+
items: {
|
|
18
|
+
type: string;
|
|
19
|
+
};
|
|
20
|
+
description: string;
|
|
21
|
+
};
|
|
22
|
+
include: {
|
|
23
|
+
type: string;
|
|
24
|
+
items: {
|
|
25
|
+
type: string;
|
|
26
|
+
enum: string[];
|
|
27
|
+
};
|
|
28
|
+
default: string[];
|
|
29
|
+
description: string;
|
|
30
|
+
};
|
|
31
|
+
browser: {
|
|
32
|
+
readonly type: "string";
|
|
33
|
+
readonly description: "Session browser; defaults to this project's live session";
|
|
34
|
+
};
|
|
35
|
+
maxBytes: {
|
|
36
|
+
type: string;
|
|
37
|
+
default: number;
|
|
38
|
+
description: string;
|
|
39
|
+
};
|
|
40
|
+
deepDom: {
|
|
41
|
+
type: string;
|
|
42
|
+
default: boolean;
|
|
43
|
+
description: string;
|
|
44
|
+
};
|
|
45
|
+
};
|
|
46
|
+
required: string[];
|
|
47
|
+
};
|
|
48
|
+
};
|
|
@@ -1,51 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
description: string;
|
|
4
|
-
inputSchema: {
|
|
5
|
-
type: "object";
|
|
6
|
-
properties: {
|
|
7
|
-
projectPath: {
|
|
8
|
-
readonly type: "string";
|
|
9
|
-
readonly description: "Extension project root (needs a live dev session)";
|
|
10
|
-
};
|
|
11
|
-
url: {
|
|
12
|
-
type: string;
|
|
13
|
-
description: string;
|
|
14
|
-
};
|
|
15
|
-
probe: {
|
|
16
|
-
type: string;
|
|
17
|
-
items: {
|
|
18
|
-
type: string;
|
|
19
|
-
};
|
|
20
|
-
description: string;
|
|
21
|
-
};
|
|
22
|
-
include: {
|
|
23
|
-
type: string;
|
|
24
|
-
items: {
|
|
25
|
-
type: string;
|
|
26
|
-
enum: string[];
|
|
27
|
-
};
|
|
28
|
-
default: string[];
|
|
29
|
-
description: string;
|
|
30
|
-
};
|
|
31
|
-
browser: {
|
|
32
|
-
readonly type: "string";
|
|
33
|
-
readonly description: "Session browser; defaults to this project's live session";
|
|
34
|
-
};
|
|
35
|
-
maxBytes: {
|
|
36
|
-
type: string;
|
|
37
|
-
default: number;
|
|
38
|
-
description: string;
|
|
39
|
-
};
|
|
40
|
-
deepDom: {
|
|
41
|
-
type: string;
|
|
42
|
-
default: boolean;
|
|
43
|
-
description: string;
|
|
44
|
-
};
|
|
45
|
-
};
|
|
46
|
-
required: string[];
|
|
47
|
-
};
|
|
48
|
-
};
|
|
1
|
+
import { schema } from "./inspect-schema";
|
|
2
|
+
export { schema };
|
|
49
3
|
export declare function handler(args: {
|
|
50
4
|
projectPath: string;
|
|
51
5
|
url?: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export
|
|
2
|
-
export declare const
|
|
1
|
+
export { CLOSE_BAD_HELLO, CLOSE_BAD_INSTANCE, CLOSE_CONTROL_UNAVAILABLE, CLOSE_SLOW_CONSUMER, CONTROL_ENVELOPE_VERSION, CONTROL_WS_PATH, LOG_EVENT_VERSION, } from "extension-develop/bridge";
|
|
2
|
+
export declare const CLOSE_REFUSAL_FLOOR = 4000;
|
|
3
3
|
export declare const DEFAULT_LIMIT = 200;
|
|
4
4
|
export declare const DEFAULT_FOLLOW_MS = 4000;
|
|
5
5
|
export declare const MIN_FOLLOW_MS = 500;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { readLogEvents } from "extension-develop/bridge";
|
|
2
|
+
export { readLogEvents };
|
|
1
3
|
export interface LogsArgs {
|
|
2
4
|
projectPath: string;
|
|
3
5
|
browser?: string;
|
|
@@ -11,4 +13,4 @@ export interface LogsArgs {
|
|
|
11
13
|
followMs?: number;
|
|
12
14
|
limit?: number;
|
|
13
15
|
}
|
|
14
|
-
export declare function makeFilter(args: LogsArgs): (event:
|
|
16
|
+
export declare function makeFilter(args: LogsArgs): (event: unknown) => boolean;
|
package/dist/src/tools/logs.d.ts
CHANGED
|
@@ -1,3 +1,11 @@
|
|
|
1
1
|
import { type LogsArgs } from "./logs-filter";
|
|
2
|
+
import { type ErrorCode } from "../lib/envelope";
|
|
2
3
|
export { schema } from "./logs-schema";
|
|
4
|
+
export interface ControlRefusal {
|
|
5
|
+
code: ErrorCode;
|
|
6
|
+
status: string;
|
|
7
|
+
message: string;
|
|
8
|
+
hint: string;
|
|
9
|
+
}
|
|
10
|
+
export declare function controlRefusal(closeCode: number, reason: string, url: string, sentVersion: number): ControlRefusal | undefined;
|
|
3
11
|
export declare function handler(args: LogsArgs): Promise<string>;
|
|
@@ -5,6 +5,7 @@ export interface SubmitToolArgs {
|
|
|
5
5
|
channel?: string;
|
|
6
6
|
version?: string;
|
|
7
7
|
dryRun?: boolean;
|
|
8
|
+
projectPath?: string;
|
|
8
9
|
api?: string;
|
|
9
10
|
}
|
|
10
11
|
export declare const schema: {
|
|
@@ -38,6 +39,10 @@ export declare const schema: {
|
|
|
38
39
|
default: boolean;
|
|
39
40
|
description: string;
|
|
40
41
|
};
|
|
42
|
+
projectPath: {
|
|
43
|
+
type: string;
|
|
44
|
+
description: string;
|
|
45
|
+
};
|
|
41
46
|
api: {
|
|
42
47
|
readonly type: "string";
|
|
43
48
|
readonly description: "Platform base URL (default EXTENSION_DEV_API_URL, else https://www.extension.dev)";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@extension.dev/mcp",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "10.
|
|
4
|
+
"version": "10.2.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",
|
|
@@ -42,9 +42,7 @@
|
|
|
42
42
|
"server.json",
|
|
43
43
|
"README.md",
|
|
44
44
|
"CHANGELOG.md",
|
|
45
|
-
"LICENSE"
|
|
46
|
-
"NOTICE",
|
|
47
|
-
"TRADEMARK.md"
|
|
45
|
+
"LICENSE"
|
|
48
46
|
],
|
|
49
47
|
"scripts": {
|
|
50
48
|
"clean": "rm -rf dist",
|
|
@@ -91,9 +89,9 @@
|
|
|
91
89
|
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
92
90
|
"browser-extension-manifest-fields": "^2.2.9",
|
|
93
91
|
"cross-spawn": "^7.0.6",
|
|
94
|
-
"extension-create": "4.0.
|
|
95
|
-
"extension-develop": "4.0.
|
|
96
|
-
"extension-install": "4.0.
|
|
92
|
+
"extension-create": "4.0.20",
|
|
93
|
+
"extension-develop": "4.0.20",
|
|
94
|
+
"extension-install": "4.0.20",
|
|
97
95
|
"ws": "^8.20.0"
|
|
98
96
|
},
|
|
99
97
|
"devDependencies": {
|
|
@@ -103,6 +101,22 @@
|
|
|
103
101
|
"@types/node": "^25.2.0",
|
|
104
102
|
"@types/ws": "^8.18.1",
|
|
105
103
|
"typescript": "6.0.2",
|
|
104
|
+
"vite": "^8.1.5",
|
|
106
105
|
"vitest": "^4.1.3"
|
|
106
|
+
},
|
|
107
|
+
"pnpm": {
|
|
108
|
+
"overrides": {
|
|
109
|
+
"hono": "^4.12.27",
|
|
110
|
+
"@hono/node-server": "^2.0.5",
|
|
111
|
+
"ws@>=8 <8.21.0": "^8.21.0",
|
|
112
|
+
"form-data@4": "^4.0.6",
|
|
113
|
+
"js-yaml@4": "^4.3.0",
|
|
114
|
+
"fast-uri@3": "^3.1.4",
|
|
115
|
+
"postcss@8": "^8.5.18",
|
|
116
|
+
"body-parser@2": "^2.3.0",
|
|
117
|
+
"ip-address@10": "^10.1.1",
|
|
118
|
+
"qs@6": "^6.15.2",
|
|
119
|
+
"vite@8": "^8.0.16"
|
|
120
|
+
}
|
|
107
121
|
}
|
|
108
122
|
}
|
package/server.json
CHANGED
|
@@ -7,13 +7,13 @@
|
|
|
7
7
|
"source": "github"
|
|
8
8
|
},
|
|
9
9
|
"websiteUrl": "https://extension.dev",
|
|
10
|
-
"version": "10.
|
|
10
|
+
"version": "10.2.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": "10.
|
|
16
|
+
"version": "10.2.0",
|
|
17
17
|
"runtimeHint": "npx",
|
|
18
18
|
"transport": {
|
|
19
19
|
"type": "stdio"
|