@extension.dev/mcp 10.4.3 → 10.7.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 +100 -0
- package/README.md +42 -1
- package/dist/module.js +2897 -1507
- package/dist/src/lib/artifacts-api.d.ts +2 -0
- package/dist/src/lib/cdp-page-scripts.d.ts +1 -0
- package/dist/src/lib/cdp.d.ts +9 -0
- package/dist/src/lib/device-flow.d.ts +18 -0
- package/dist/src/lib/match-patterns.d.ts +3 -0
- package/dist/src/lib/origins.d.ts +2 -0
- package/dist/src/lib/platform-hold.d.ts +21 -0
- package/dist/src/lib/preview-upload.d.ts +2 -0
- package/dist/src/lib/project-manifest.d.ts +18 -0
- package/dist/src/lib/publish.d.ts +2 -0
- package/dist/src/lib/registry.d.ts +11 -7
- package/dist/src/lib/store-md.d.ts +11 -0
- package/dist/src/lib/verdict.d.ts +63 -0
- package/dist/src/tools/assert.d.ts +90 -0
- package/dist/src/tools/doctor.d.ts +2 -1
- package/dist/src/tools/logs-filter.d.ts +2 -2
- package/dist/src/tools/logs.d.ts +3 -0
- package/dist/src/tools/open.d.ts +4 -0
- package/dist/src/tools/project-create.d.ts +65 -0
- package/package.json +3 -3
- package/server.json +3 -3
|
@@ -56,6 +56,8 @@ export type ArtifactsOutcome<T> = {
|
|
|
56
56
|
message: string;
|
|
57
57
|
status?: number;
|
|
58
58
|
};
|
|
59
|
+
held?: boolean;
|
|
60
|
+
body?: unknown;
|
|
59
61
|
};
|
|
60
62
|
export declare function parseArtifactRef(input: string): string | null;
|
|
61
63
|
export declare function wwwRevokeUrl(value: string): string;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export declare const PAGE_HTML_SCRIPT = "(() => {\n try {\n const doctype = document.doctype;\n const dt = doctype\n ? '<!DOCTYPE ' + doctype.name\n + (doctype.publicId ? ' PUBLIC \"' + doctype.publicId + '\"' : '')\n + (doctype.systemId ? ' \"' + doctype.systemId + '\"' : '')\n + '>'\n : '';\n // Include shadow DOM content from extension roots\n const roots = Array.from(document.querySelectorAll(\n '#extension-root,[data-extension-root]:not([data-extension-root=\"extension-js-devtools\"])'\n ));\n if (roots.length) {\n const clone = document.documentElement.cloneNode(true);\n const clonedRoots = Array.from(clone.querySelectorAll(\n '#extension-root,[data-extension-root]:not([data-extension-root=\"extension-js-devtools\"])'\n ));\n const s = new XMLSerializer();\n for (let i = 0; i < Math.min(roots.length, clonedRoots.length); i++) {\n const sr = roots[i].shadowRoot;\n if (!sr) continue;\n try {\n const shadow = Array.from(sr.childNodes).map(n => {\n try { return s.serializeToString(n); } catch { return ''; }\n }).join('');\n if (shadow) clonedRoots[i].innerHTML = shadow;\n } catch {}\n }\n return dt + '\\n' + clone.outerHTML;\n }\n return dt + '\\n' + document.documentElement.outerHTML;\n } catch (e) { return ''; }\n })()";
|
|
2
2
|
export declare const PAGE_META_SCRIPT = "(() => {\n try {\n return {\n title: document.title,\n url: location.href,\n readyState: document.readyState,\n viewport: {\n width: window.innerWidth,\n height: window.innerHeight,\n devicePixelRatio: window.devicePixelRatio\n },\n frameCount: window.frames.length,\n scriptCount: document.querySelectorAll('script').length,\n styleCount: document.querySelectorAll('style,link[rel=\"stylesheet\"]').length\n };\n } catch { return {}; }\n })()";
|
|
3
3
|
export declare const EXTENSION_ROOT_META_SCRIPT = "(() => {\n try {\n const readGeneration = (node) => {\n const raw = node.getAttribute && node.getAttribute('data-extjs-reinject-generation');\n const parsed = Number(raw);\n return Number.isFinite(parsed) ? parsed : undefined;\n };\n const normalize = (node) => ({\n tag: node.tagName ? String(node.tagName).toLowerCase() : 'unknown',\n id: node.id || undefined,\n key: node.getAttribute ? node.getAttribute('data-extjs-reinject-key') || undefined : undefined,\n generation: readGeneration(node),\n status: node.getAttribute ? node.getAttribute('data-extjs-reinject-status') || undefined : undefined\n });\n const roots = Array.from(\n document.querySelectorAll('#extension-root,[data-extension-root]:not([data-extension-root=\"extension-js-devtools\"])')\n ).slice(0, 10).map(normalize);\n const markers = Array.from(\n document.querySelectorAll('[data-extjs-reinject-marker=\"true\"]')\n ).slice(0, 10).map(normalize);\n if (!roots.length && !markers.length) return null;\n const generations = [...roots, ...markers]\n .map(e => e.generation)\n .filter(g => typeof g === 'number');\n return {\n rootCount: roots.length,\n markerCount: markers.length,\n latestGeneration: generations.length ? Math.max(...generations) : 0,\n roots,\n markers\n };\n } catch { return null; }\n })()";
|
|
4
|
+
export declare const RENDER_EVIDENCE_SCRIPT = "(() => {\n try {\n const body = document.body;\n const roots = document.querySelectorAll(\n '#extension-root,[data-extension-root]:not([data-extension-root=\"extension-js-devtools\"])'\n );\n const text = body ? (body.innerText || body.textContent || '') : '';\n return {\n readyState: document.readyState,\n title: document.title,\n bodyChildCount: body ? body.children.length : 0,\n bodyElementCount: body ? body.querySelectorAll('*').length : 0,\n textLength: text.trim().length,\n extensionRootCount: roots.length\n };\n } catch { return null; }\n })()";
|
|
4
5
|
export declare function probeSelectorsScript(selectors: string[]): string;
|
|
5
6
|
export declare function domSnapshotScript(maxNodes: number): string;
|
package/dist/src/lib/cdp.d.ts
CHANGED
|
@@ -1,4 +1,12 @@
|
|
|
1
1
|
import { CDPConnection } from "./cdp-connection";
|
|
2
|
+
export interface RenderEvidence {
|
|
3
|
+
readyState?: string;
|
|
4
|
+
title?: string;
|
|
5
|
+
bodyChildCount?: number;
|
|
6
|
+
bodyElementCount?: number;
|
|
7
|
+
textLength?: number;
|
|
8
|
+
extensionRootCount?: number;
|
|
9
|
+
}
|
|
2
10
|
export declare class CDPClient extends CDPConnection {
|
|
3
11
|
static discoverBrowserWsUrl(port: number, host?: string): Promise<string>;
|
|
4
12
|
static discoverTargets(port: number, host?: string): Promise<Array<{
|
|
@@ -27,5 +35,6 @@ export declare class CDPClient extends CDPConnection {
|
|
|
27
35
|
samples: Array<Record<string, unknown>>;
|
|
28
36
|
}>>;
|
|
29
37
|
getDomSnapshot(sessionId: string, maxNodes?: number): Promise<Array<Record<string, unknown>>>;
|
|
38
|
+
getRenderEvidence(sessionId: string): Promise<RenderEvidence | null>;
|
|
30
39
|
getExtensionRootMeta(sessionId: string): Promise<Record<string, unknown> | null>;
|
|
31
40
|
}
|
|
@@ -13,6 +13,7 @@ export declare function requestDeviceCode(args: {
|
|
|
13
13
|
path: string;
|
|
14
14
|
project: string;
|
|
15
15
|
clientName?: string;
|
|
16
|
+
intent?: "login" | "create";
|
|
16
17
|
fetchImpl?: FetchImpl;
|
|
17
18
|
}): Promise<DeviceCodeStart>;
|
|
18
19
|
export type DevicePollResult = {
|
|
@@ -23,6 +24,23 @@ export type DevicePollResult = {
|
|
|
23
24
|
reason: "pending" | "denied" | "expired" | "error";
|
|
24
25
|
message?: string;
|
|
25
26
|
};
|
|
27
|
+
export type DeviceGrantPollResult = {
|
|
28
|
+
ok: true;
|
|
29
|
+
data: Record<string, unknown>;
|
|
30
|
+
} | {
|
|
31
|
+
ok: false;
|
|
32
|
+
reason: "pending" | "denied" | "expired" | "error";
|
|
33
|
+
message?: string;
|
|
34
|
+
};
|
|
35
|
+
export declare function pollDeviceGrant(args: {
|
|
36
|
+
apiBase: string;
|
|
37
|
+
path: string;
|
|
38
|
+
project: string;
|
|
39
|
+
deviceCode: string;
|
|
40
|
+
interval: number;
|
|
41
|
+
budgetMs: number;
|
|
42
|
+
fetchImpl?: FetchImpl;
|
|
43
|
+
}): Promise<DeviceGrantPollResult>;
|
|
26
44
|
export declare function pollDeviceToken(args: {
|
|
27
45
|
apiBase: string;
|
|
28
46
|
path: string;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export declare const PLATFORM_HOLD_CODE = "PLATFORM_NOT_OPEN";
|
|
2
|
+
export declare const PLATFORM_HOLD_HEADER = "x-extensiondev-hold";
|
|
3
|
+
export declare const PLATFORM_HOLD_STATUS = "platform-held";
|
|
4
|
+
export declare const PLATFORM_HOLD_RELAYS_THE_PLATFORM_DATE: boolean;
|
|
5
|
+
export declare const PLATFORM_HOLD_STILL_WORKS: string[];
|
|
6
|
+
export declare function templatesOrigin(apiHint?: string): string;
|
|
7
|
+
export declare function readPlatformCode(body: unknown): string;
|
|
8
|
+
export declare function readPlatformMessage(body: unknown): string;
|
|
9
|
+
export declare function sawPlatformHold(res?: {
|
|
10
|
+
headers?: {
|
|
11
|
+
get?: (name: string) => string | null;
|
|
12
|
+
};
|
|
13
|
+
} | null, body?: unknown): boolean;
|
|
14
|
+
export declare function platformHoldMessage(body?: unknown, apiHint?: string): string;
|
|
15
|
+
export declare function platformHoldEnvelope(options: {
|
|
16
|
+
command: string;
|
|
17
|
+
name: string;
|
|
18
|
+
body?: unknown;
|
|
19
|
+
api?: string;
|
|
20
|
+
value?: Record<string, unknown>;
|
|
21
|
+
}): string;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare function manifestCandidates(projectPath: string, browser: string): string[];
|
|
2
|
+
export interface ReadManifest {
|
|
3
|
+
file: string;
|
|
4
|
+
manifest: Record<string, unknown>;
|
|
5
|
+
}
|
|
6
|
+
export declare function readBuiltManifest(projectPath: string, browser: string): ReadManifest | null;
|
|
7
|
+
export type BackgroundKind = "service_worker" | "scripts" | "page" | "none";
|
|
8
|
+
export interface DeclaredBackground {
|
|
9
|
+
kind: BackgroundKind;
|
|
10
|
+
ref?: string;
|
|
11
|
+
}
|
|
12
|
+
export declare function declaredBackground(manifest: Record<string, unknown>): DeclaredBackground;
|
|
13
|
+
export interface DeclaredContentScript {
|
|
14
|
+
index: number;
|
|
15
|
+
matches: string[];
|
|
16
|
+
js: string[];
|
|
17
|
+
}
|
|
18
|
+
export declare function declaredContentScripts(manifest: Record<string, unknown>): DeclaredContentScript[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type RegistryAccessTokens } from "./registry-access";
|
|
2
|
-
import {
|
|
2
|
+
import { mcpOrigins } from "./origins";
|
|
3
3
|
export declare const REGISTRY_BASE_DEFAULT: string;
|
|
4
|
-
export
|
|
4
|
+
export { mcpOrigins };
|
|
5
5
|
export declare function consoleBase(apiHint?: string): string;
|
|
6
6
|
export declare function registryBase(): string;
|
|
7
7
|
export interface ProjectRef {
|
|
@@ -15,14 +15,18 @@ export declare function resolveProjectRef(overrides?: {
|
|
|
15
15
|
export declare function registryFileUrl(ref: ProjectRef, file: string): string;
|
|
16
16
|
export declare function consoleProjectUrl(ref: ProjectRef | null, page: string, apiHint?: string): string;
|
|
17
17
|
export declare function userlandProjectUrl(ref: ProjectRef | null, page?: string, apiHint?: string): string;
|
|
18
|
-
export
|
|
19
|
-
ok: true;
|
|
20
|
-
json: T;
|
|
21
|
-
} | {
|
|
18
|
+
export interface RegistryFetchRefusal {
|
|
22
19
|
ok: false;
|
|
23
20
|
status?: number;
|
|
24
21
|
message: string;
|
|
25
|
-
|
|
22
|
+
code?: string;
|
|
23
|
+
held?: boolean;
|
|
24
|
+
body?: unknown;
|
|
25
|
+
}
|
|
26
|
+
export type RegistryFetchResult<T> = {
|
|
27
|
+
ok: true;
|
|
28
|
+
json: T;
|
|
29
|
+
} | RegistryFetchRefusal;
|
|
26
30
|
export declare function fetchRegistryJson<T = unknown>(url: string, fetchImpl?: typeof fetch, options?: {
|
|
27
31
|
ref?: ProjectRef | null;
|
|
28
32
|
api?: string;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const STORE_MD_FILENAME = "STORE.md";
|
|
2
|
+
export interface StoreMdData {
|
|
3
|
+
firefox?: {
|
|
4
|
+
approvalNotes?: string;
|
|
5
|
+
releaseNotes?: string;
|
|
6
|
+
};
|
|
7
|
+
edge?: {
|
|
8
|
+
certificationNotes?: string;
|
|
9
|
+
};
|
|
10
|
+
}
|
|
11
|
+
export declare function parseStoreMd(content: string): StoreMdData;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
export declare const ASSERT_CONTRACT_NAME = "extension.dev/assert-verdict";
|
|
2
|
+
export declare const ASSERT_CONTRACT_VERSION = 1;
|
|
3
|
+
export declare const OUTCOME_PASS = "pass";
|
|
4
|
+
export declare const OUTCOME_FAIL = "fail";
|
|
5
|
+
export declare const OUTCOME_INCONCLUSIVE = "inconclusive";
|
|
6
|
+
export declare const OUTCOME_SKIPPED = "skipped";
|
|
7
|
+
export type CheckOutcome = typeof OUTCOME_PASS | typeof OUTCOME_FAIL | typeof OUTCOME_INCONCLUSIVE | typeof OUTCOME_SKIPPED;
|
|
8
|
+
export declare const CHECK_OUTCOMES: CheckOutcome[];
|
|
9
|
+
export type CheckSeverity = "fail" | "warn" | "info";
|
|
10
|
+
export type VerdictOutcome = typeof OUTCOME_PASS | typeof OUTCOME_FAIL | typeof OUTCOME_INCONCLUSIVE;
|
|
11
|
+
export interface AssertCheckDeclaration {
|
|
12
|
+
readonly id: string;
|
|
13
|
+
readonly since: number;
|
|
14
|
+
readonly severity: CheckSeverity;
|
|
15
|
+
readonly title: string;
|
|
16
|
+
readonly reads: readonly string[];
|
|
17
|
+
readonly previewCounterpart: string | null;
|
|
18
|
+
readonly counterpartNote?: string;
|
|
19
|
+
}
|
|
20
|
+
export declare const ASSERT_RETIRED_IDS: readonly string[];
|
|
21
|
+
export declare const ASSERT_CHECKS: readonly AssertCheckDeclaration[];
|
|
22
|
+
export declare function assertCheckById(id: string): AssertCheckDeclaration | null;
|
|
23
|
+
export interface CheckResult {
|
|
24
|
+
id: string;
|
|
25
|
+
subject: string | null;
|
|
26
|
+
since: number;
|
|
27
|
+
severity: CheckSeverity;
|
|
28
|
+
outcome: CheckOutcome;
|
|
29
|
+
detail: string;
|
|
30
|
+
evidence: Record<string, unknown> | null;
|
|
31
|
+
settledBy?: string;
|
|
32
|
+
}
|
|
33
|
+
export declare function passCheck(id: string, subject: string | null, detail: string, evidence?: Record<string, unknown>): CheckResult;
|
|
34
|
+
export declare function failCheck(id: string, subject: string | null, detail: string, evidence?: Record<string, unknown>): CheckResult;
|
|
35
|
+
export declare function inconclusiveCheck(id: string, subject: string | null, detail: string, settledBy: string, evidence?: Record<string, unknown>): CheckResult;
|
|
36
|
+
export declare function checkKey(check: CheckResult): string;
|
|
37
|
+
export declare function verdictOutcome(checks: CheckResult[]): VerdictOutcome;
|
|
38
|
+
export interface AssertVerdict {
|
|
39
|
+
contract: typeof ASSERT_CONTRACT_NAME;
|
|
40
|
+
contractVersion: number;
|
|
41
|
+
producer: {
|
|
42
|
+
name: string;
|
|
43
|
+
version?: string;
|
|
44
|
+
} | null;
|
|
45
|
+
subject: Record<string, unknown> | null;
|
|
46
|
+
generatedAt: string;
|
|
47
|
+
outcome: VerdictOutcome;
|
|
48
|
+
passed: boolean;
|
|
49
|
+
checks: CheckResult[];
|
|
50
|
+
failures: string[];
|
|
51
|
+
inconclusive: string[];
|
|
52
|
+
}
|
|
53
|
+
export interface VerdictInput {
|
|
54
|
+
checks: CheckResult[];
|
|
55
|
+
producer?: {
|
|
56
|
+
name: string;
|
|
57
|
+
version?: string;
|
|
58
|
+
};
|
|
59
|
+
subject?: Record<string, unknown>;
|
|
60
|
+
generatedAt?: string;
|
|
61
|
+
}
|
|
62
|
+
export declare function assertVerdict(input: VerdictInput): AssertVerdict;
|
|
63
|
+
export declare function verdictSentence(verdict: AssertVerdict): string;
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { checkKey } from "../lib/verdict";
|
|
2
|
+
export declare const ASSERT_KINDS: string[];
|
|
3
|
+
declare const BACKGROUND = "background-worker-booted";
|
|
4
|
+
declare const SURFACE = "surface-rendered";
|
|
5
|
+
declare const CONTENT_SCRIPT = "content-script-injected";
|
|
6
|
+
declare const STORAGE = "storage-key-present";
|
|
7
|
+
declare const CONSOLE = "console-errors-empty";
|
|
8
|
+
export declare const schema: {
|
|
9
|
+
name: string;
|
|
10
|
+
description: string;
|
|
11
|
+
inputSchema: {
|
|
12
|
+
type: "object";
|
|
13
|
+
properties: {
|
|
14
|
+
projectPath: {
|
|
15
|
+
readonly type: "string";
|
|
16
|
+
readonly description: "Extension project root (needs a live dev session)";
|
|
17
|
+
};
|
|
18
|
+
expect: {
|
|
19
|
+
type: string;
|
|
20
|
+
items: {
|
|
21
|
+
type: string;
|
|
22
|
+
};
|
|
23
|
+
description: string;
|
|
24
|
+
};
|
|
25
|
+
browser: {
|
|
26
|
+
readonly type: "string";
|
|
27
|
+
readonly description: "Session browser; defaults to this project's live session";
|
|
28
|
+
};
|
|
29
|
+
timeout: {
|
|
30
|
+
readonly type: "number";
|
|
31
|
+
readonly description: "Command timeout in ms (default 5000)";
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
required: string[];
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
interface BackgroundClause {
|
|
38
|
+
assert: typeof BACKGROUND;
|
|
39
|
+
subject: null;
|
|
40
|
+
}
|
|
41
|
+
interface SurfaceClause {
|
|
42
|
+
assert: typeof SURFACE;
|
|
43
|
+
subject: string;
|
|
44
|
+
surface: string;
|
|
45
|
+
selector?: string;
|
|
46
|
+
minNodes?: number;
|
|
47
|
+
}
|
|
48
|
+
interface ContentScriptClause {
|
|
49
|
+
assert: typeof CONTENT_SCRIPT;
|
|
50
|
+
subject: string;
|
|
51
|
+
url: string;
|
|
52
|
+
}
|
|
53
|
+
interface StorageClause {
|
|
54
|
+
assert: typeof STORAGE;
|
|
55
|
+
subject: string;
|
|
56
|
+
key: string;
|
|
57
|
+
area: string;
|
|
58
|
+
equals?: unknown;
|
|
59
|
+
hasEquals: boolean;
|
|
60
|
+
context?: string;
|
|
61
|
+
}
|
|
62
|
+
interface ConsoleClause {
|
|
63
|
+
assert: typeof CONSOLE;
|
|
64
|
+
subject: string | null;
|
|
65
|
+
context?: string[];
|
|
66
|
+
since?: number;
|
|
67
|
+
ignore?: string[];
|
|
68
|
+
}
|
|
69
|
+
type Clause = BackgroundClause | SurfaceClause | ContentScriptClause | StorageClause | ConsoleClause;
|
|
70
|
+
interface ParseResult {
|
|
71
|
+
clauses: Clause[];
|
|
72
|
+
issues: string[];
|
|
73
|
+
}
|
|
74
|
+
export declare function parseClauses(raw: unknown): ParseResult;
|
|
75
|
+
export declare function renderedFromEvidence(evidence: {
|
|
76
|
+
bodyElementCount?: number;
|
|
77
|
+
textLength?: number;
|
|
78
|
+
}): boolean;
|
|
79
|
+
interface StorageRead {
|
|
80
|
+
shape: "found" | "absent" | "unreadable";
|
|
81
|
+
value?: unknown;
|
|
82
|
+
}
|
|
83
|
+
export declare function readStorageValue(value: unknown, key: string): StorageRead;
|
|
84
|
+
export declare function handler(args: {
|
|
85
|
+
projectPath: string;
|
|
86
|
+
expect: unknown;
|
|
87
|
+
browser?: string;
|
|
88
|
+
timeout?: number;
|
|
89
|
+
}): Promise<string>;
|
|
90
|
+
export { checkKey };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type LogQuery } from "./logs-filter";
|
|
1
2
|
export declare const schema: {
|
|
2
3
|
name: string;
|
|
3
4
|
description: string;
|
|
@@ -15,7 +16,7 @@ export declare const schema: {
|
|
|
15
16
|
};
|
|
16
17
|
};
|
|
17
18
|
};
|
|
18
|
-
export declare function recentErrorLogs(projectPath: string, browser: string, max?: number): string[];
|
|
19
|
+
export declare function recentErrorLogs(projectPath: string, browser: string, max?: number, query?: Omit<LogQuery, "level">): string[];
|
|
19
20
|
export declare function handler(args: {
|
|
20
21
|
projectPath?: string;
|
|
21
22
|
browser?: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { readLogEvents } from "extension-develop/bridge";
|
|
2
|
-
export { readLogEvents };
|
|
1
|
+
import { readLogEvents, type LogQuery } from "extension-develop/bridge";
|
|
2
|
+
export { readLogEvents, type LogQuery };
|
|
3
3
|
export interface LogsArgs {
|
|
4
4
|
projectPath: string;
|
|
5
5
|
browser?: string;
|
package/dist/src/tools/logs.d.ts
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { type LogsArgs } from "./logs-filter";
|
|
2
2
|
import { type ErrorCode } from "../lib/envelope";
|
|
3
3
|
export { schema } from "./logs-schema";
|
|
4
|
+
export declare function emptyReason(projectPath: string, browser: string): string | undefined;
|
|
5
|
+
export declare function staleFileNote(projectPath: string, browser: string, eventsRunId: string): string | undefined;
|
|
6
|
+
export declare function readLogRunId(projectPath: string, browser: string): string;
|
|
4
7
|
export interface ControlRefusal {
|
|
5
8
|
code: ErrorCode;
|
|
6
9
|
status: string;
|
package/dist/src/tools/open.d.ts
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
import { type ActArgs } from "../lib/act";
|
|
2
2
|
export declare function navigateToUrl(projectPath: string, browser: string, url: string, timeout?: number): Promise<string>;
|
|
3
|
+
export declare function resolveExtensionId(projectPath: string, browser: string): Promise<string | null>;
|
|
4
|
+
export declare function surfaceDocument(projectPath: string, browser: string, surface: string): string | null;
|
|
5
|
+
export declare const SURFACE_MANIFEST_KEYS: Record<string, string>;
|
|
6
|
+
export declare function declaredSurfaces(projectPath: string, browser: string): string[] | null;
|
|
3
7
|
export declare function clampPopupBounds(width: number, height: number): {
|
|
4
8
|
width: number;
|
|
5
9
|
height: number;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
export declare const schema: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
inputSchema: {
|
|
5
|
+
type: "object";
|
|
6
|
+
properties: {
|
|
7
|
+
project: {
|
|
8
|
+
type: string;
|
|
9
|
+
description: string;
|
|
10
|
+
};
|
|
11
|
+
repo: {
|
|
12
|
+
type: string;
|
|
13
|
+
description: string;
|
|
14
|
+
};
|
|
15
|
+
installationId: {
|
|
16
|
+
type: string;
|
|
17
|
+
description: string;
|
|
18
|
+
};
|
|
19
|
+
displayName: {
|
|
20
|
+
type: string;
|
|
21
|
+
description: string;
|
|
22
|
+
};
|
|
23
|
+
description: {
|
|
24
|
+
type: string;
|
|
25
|
+
description: string;
|
|
26
|
+
};
|
|
27
|
+
installCommand: {
|
|
28
|
+
type: string;
|
|
29
|
+
default: string;
|
|
30
|
+
description: string;
|
|
31
|
+
};
|
|
32
|
+
buildCommand: {
|
|
33
|
+
type: string;
|
|
34
|
+
default: string;
|
|
35
|
+
description: string;
|
|
36
|
+
};
|
|
37
|
+
outputDirectory: {
|
|
38
|
+
type: string;
|
|
39
|
+
default: string;
|
|
40
|
+
description: string;
|
|
41
|
+
};
|
|
42
|
+
deviceCode: {
|
|
43
|
+
type: string;
|
|
44
|
+
description: string;
|
|
45
|
+
};
|
|
46
|
+
api: {
|
|
47
|
+
readonly type: "string";
|
|
48
|
+
readonly description: "Platform base URL (default EXTENSION_DEV_API_URL, else https://www.extension.dev)";
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
required: string[];
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
export declare function handler(args: {
|
|
55
|
+
project: string;
|
|
56
|
+
repo: string;
|
|
57
|
+
installationId?: string;
|
|
58
|
+
displayName?: string;
|
|
59
|
+
description?: string;
|
|
60
|
+
installCommand?: string;
|
|
61
|
+
buildCommand?: string;
|
|
62
|
+
outputDirectory?: string;
|
|
63
|
+
deviceCode?: string;
|
|
64
|
+
api?: string;
|
|
65
|
+
}): Promise<string>;
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@extension.dev/mcp",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "10.
|
|
5
|
-
"description": "MCP server that lets AI agents (Claude Code, Claude Desktop, Cursor, Copilot, Codex) build, run, inspect, and publish browser extensions.
|
|
4
|
+
"version": "10.7.0",
|
|
5
|
+
"description": "MCP server that lets AI agents (Claude Code, Claude Desktop, Cursor, Copilot, Codex) build, run, inspect, and publish browser extensions. 30 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",
|
|
8
8
|
"author": {
|
|
@@ -86,6 +86,7 @@
|
|
|
86
86
|
"extension.js"
|
|
87
87
|
],
|
|
88
88
|
"dependencies": {
|
|
89
|
+
"@extension.dev/urls": "^0.8.0",
|
|
89
90
|
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
90
91
|
"browser-extension-manifest-fields": "^2.2.9",
|
|
91
92
|
"cross-spawn": "^7.0.6",
|
|
@@ -95,7 +96,6 @@
|
|
|
95
96
|
"ws": "^8.20.0"
|
|
96
97
|
},
|
|
97
98
|
"devDependencies": {
|
|
98
|
-
"@extension.dev/urls": "^0.6.0",
|
|
99
99
|
"@rslib/core": "^0.19.4",
|
|
100
100
|
"@types/cross-spawn": "^6.0.6",
|
|
101
101
|
"@types/node": "^25.2.0",
|
package/server.json
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://static.modelcontextprotocol.io/schemas/2025-09-29/server.schema.json",
|
|
3
3
|
"name": "io.github.extensiondev/mcp",
|
|
4
|
-
"description": "Build, run, inspect, and publish browser extensions from any MCP client.
|
|
4
|
+
"description": "Build, run, inspect, and publish browser extensions from any MCP client. 30 tools, 11 browsers.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"url": "https://github.com/extensiondev/mcp",
|
|
7
7
|
"source": "github"
|
|
8
8
|
},
|
|
9
9
|
"websiteUrl": "https://extension.dev",
|
|
10
|
-
"version": "10.
|
|
10
|
+
"version": "10.7.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.7.0",
|
|
17
17
|
"runtimeHint": "npx",
|
|
18
18
|
"transport": {
|
|
19
19
|
"type": "stdio"
|