@midscene/computer 1.9.1-beta-20260605030736.0 → 1.9.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/dist/es/cli.mjs +9 -12
- package/dist/es/index.mjs +9 -12
- package/dist/es/mcp-server.mjs +9 -12
- package/dist/lib/cli.js +9 -12
- package/dist/lib/index.js +9 -12
- package/dist/lib/mcp-server.js +9 -12
- package/dist/types/index.d.ts +0 -6
- package/dist/types/mcp-server.d.ts +0 -6
- package/package.json +3 -3
package/dist/es/cli.mjs
CHANGED
|
@@ -520,7 +520,7 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
520
520
|
}
|
|
521
521
|
async healthCheck() {
|
|
522
522
|
console.log('[HealthCheck] Starting health check...');
|
|
523
|
-
console.log("[HealthCheck] @midscene/computer v1.9.1
|
|
523
|
+
console.log("[HealthCheck] @midscene/computer v1.9.1");
|
|
524
524
|
console.log('[HealthCheck] Taking screenshot...');
|
|
525
525
|
const screenshotTimeout = 15000;
|
|
526
526
|
let timeoutId;
|
|
@@ -550,11 +550,11 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
550
550
|
const msg = `[HealthCheck] WARNING: Mouse control may not be working. Expected (${targetX}, ${targetY}), got (${movedPos.x}, ${movedPos.y}), delta=(${deltaX}, ${deltaY})`;
|
|
551
551
|
console.warn(msg);
|
|
552
552
|
debugDevice(msg);
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
553
|
+
if ('win32' === process.platform && !this.isRunningAsAdmin()) {
|
|
554
|
+
const hint = "Midscene is NOT running as Administrator. Windows blocks mouse/keyboard input to elevated (admin) applications from non-admin processes (UIPI). Please run your terminal or Node.js as Administrator and try again.";
|
|
555
|
+
console.error(`\n[HealthCheck] ${hint}\n`);
|
|
556
|
+
debugDevice(hint);
|
|
557
|
+
}
|
|
558
558
|
}
|
|
559
559
|
this.inputDriver.moveMouse(startPos.x, startPos.y);
|
|
560
560
|
console.log(`[HealthCheck] Mouse restored to (${startPos.x}, ${startPos.y})`);
|
|
@@ -571,16 +571,14 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
571
571
|
}
|
|
572
572
|
isRunningAsAdmin() {
|
|
573
573
|
if ('win32' !== process.platform) return false;
|
|
574
|
-
if (void 0 !== this.adminCheckCache) return this.adminCheckCache;
|
|
575
574
|
try {
|
|
576
575
|
execSync('net session', {
|
|
577
576
|
stdio: 'pipe'
|
|
578
577
|
});
|
|
579
|
-
|
|
578
|
+
return true;
|
|
580
579
|
} catch {
|
|
581
|
-
|
|
580
|
+
return false;
|
|
582
581
|
}
|
|
583
|
-
return this.adminCheckCache;
|
|
584
582
|
}
|
|
585
583
|
async screenshotBase64() {
|
|
586
584
|
if (this.destroyed) throw new Error('ComputerDevice has been destroyed');
|
|
@@ -813,7 +811,6 @@ Original error: ${lastRawMessage}`);
|
|
|
813
811
|
debug: (message)=>debugDevice(message)
|
|
814
812
|
}));
|
|
815
813
|
device_define_property(this, "useAppleScript", void 0);
|
|
816
|
-
device_define_property(this, "adminCheckCache", void 0);
|
|
817
814
|
device_define_property(this, "uri", void 0);
|
|
818
815
|
device_define_property(this, "inputPrimitives", {
|
|
819
816
|
pointer: {
|
|
@@ -1700,7 +1697,7 @@ class ComputerMidsceneTools extends BaseMidsceneTools {
|
|
|
1700
1697
|
const tools = new ComputerMidsceneTools();
|
|
1701
1698
|
runToolsCLI(tools, 'midscene-computer', {
|
|
1702
1699
|
stripPrefix: 'computer_',
|
|
1703
|
-
version: "1.9.1
|
|
1700
|
+
version: "1.9.1",
|
|
1704
1701
|
extraCommands: createReportCliCommands()
|
|
1705
1702
|
}).catch((e)=>{
|
|
1706
1703
|
process.exit(reportCLIError(e));
|
package/dist/es/index.mjs
CHANGED
|
@@ -520,7 +520,7 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
520
520
|
}
|
|
521
521
|
async healthCheck() {
|
|
522
522
|
console.log('[HealthCheck] Starting health check...');
|
|
523
|
-
console.log("[HealthCheck] @midscene/computer v1.9.1
|
|
523
|
+
console.log("[HealthCheck] @midscene/computer v1.9.1");
|
|
524
524
|
console.log('[HealthCheck] Taking screenshot...');
|
|
525
525
|
const screenshotTimeout = 15000;
|
|
526
526
|
let timeoutId;
|
|
@@ -550,11 +550,11 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
550
550
|
const msg = `[HealthCheck] WARNING: Mouse control may not be working. Expected (${targetX}, ${targetY}), got (${movedPos.x}, ${movedPos.y}), delta=(${deltaX}, ${deltaY})`;
|
|
551
551
|
console.warn(msg);
|
|
552
552
|
debugDevice(msg);
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
553
|
+
if ('win32' === process.platform && !this.isRunningAsAdmin()) {
|
|
554
|
+
const hint = "Midscene is NOT running as Administrator. Windows blocks mouse/keyboard input to elevated (admin) applications from non-admin processes (UIPI). Please run your terminal or Node.js as Administrator and try again.";
|
|
555
|
+
console.error(`\n[HealthCheck] ${hint}\n`);
|
|
556
|
+
debugDevice(hint);
|
|
557
|
+
}
|
|
558
558
|
}
|
|
559
559
|
this.inputDriver.moveMouse(startPos.x, startPos.y);
|
|
560
560
|
console.log(`[HealthCheck] Mouse restored to (${startPos.x}, ${startPos.y})`);
|
|
@@ -571,16 +571,14 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
571
571
|
}
|
|
572
572
|
isRunningAsAdmin() {
|
|
573
573
|
if ('win32' !== process.platform) return false;
|
|
574
|
-
if (void 0 !== this.adminCheckCache) return this.adminCheckCache;
|
|
575
574
|
try {
|
|
576
575
|
execSync('net session', {
|
|
577
576
|
stdio: 'pipe'
|
|
578
577
|
});
|
|
579
|
-
|
|
578
|
+
return true;
|
|
580
579
|
} catch {
|
|
581
|
-
|
|
580
|
+
return false;
|
|
582
581
|
}
|
|
583
|
-
return this.adminCheckCache;
|
|
584
582
|
}
|
|
585
583
|
async screenshotBase64() {
|
|
586
584
|
if (this.destroyed) throw new Error('ComputerDevice has been destroyed');
|
|
@@ -813,7 +811,6 @@ Original error: ${lastRawMessage}`);
|
|
|
813
811
|
debug: (message)=>debugDevice(message)
|
|
814
812
|
}));
|
|
815
813
|
device_define_property(this, "useAppleScript", void 0);
|
|
816
|
-
device_define_property(this, "adminCheckCache", void 0);
|
|
817
814
|
device_define_property(this, "uri", void 0);
|
|
818
815
|
device_define_property(this, "inputPrimitives", {
|
|
819
816
|
pointer: {
|
|
@@ -1741,7 +1738,7 @@ class ComputerMidsceneTools extends BaseMidsceneTools {
|
|
|
1741
1738
|
}
|
|
1742
1739
|
}
|
|
1743
1740
|
function version() {
|
|
1744
|
-
const currentVersion = "1.9.1
|
|
1741
|
+
const currentVersion = "1.9.1";
|
|
1745
1742
|
console.log(`@midscene/computer v${currentVersion}`);
|
|
1746
1743
|
return currentVersion;
|
|
1747
1744
|
}
|
package/dist/es/mcp-server.mjs
CHANGED
|
@@ -520,7 +520,7 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
520
520
|
}
|
|
521
521
|
async healthCheck() {
|
|
522
522
|
console.log('[HealthCheck] Starting health check...');
|
|
523
|
-
console.log("[HealthCheck] @midscene/computer v1.9.1
|
|
523
|
+
console.log("[HealthCheck] @midscene/computer v1.9.1");
|
|
524
524
|
console.log('[HealthCheck] Taking screenshot...');
|
|
525
525
|
const screenshotTimeout = 15000;
|
|
526
526
|
let timeoutId;
|
|
@@ -550,11 +550,11 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
550
550
|
const msg = `[HealthCheck] WARNING: Mouse control may not be working. Expected (${targetX}, ${targetY}), got (${movedPos.x}, ${movedPos.y}), delta=(${deltaX}, ${deltaY})`;
|
|
551
551
|
console.warn(msg);
|
|
552
552
|
debugDevice(msg);
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
553
|
+
if ('win32' === process.platform && !this.isRunningAsAdmin()) {
|
|
554
|
+
const hint = "Midscene is NOT running as Administrator. Windows blocks mouse/keyboard input to elevated (admin) applications from non-admin processes (UIPI). Please run your terminal or Node.js as Administrator and try again.";
|
|
555
|
+
console.error(`\n[HealthCheck] ${hint}\n`);
|
|
556
|
+
debugDevice(hint);
|
|
557
|
+
}
|
|
558
558
|
}
|
|
559
559
|
this.inputDriver.moveMouse(startPos.x, startPos.y);
|
|
560
560
|
console.log(`[HealthCheck] Mouse restored to (${startPos.x}, ${startPos.y})`);
|
|
@@ -571,16 +571,14 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
571
571
|
}
|
|
572
572
|
isRunningAsAdmin() {
|
|
573
573
|
if ('win32' !== process.platform) return false;
|
|
574
|
-
if (void 0 !== this.adminCheckCache) return this.adminCheckCache;
|
|
575
574
|
try {
|
|
576
575
|
execSync('net session', {
|
|
577
576
|
stdio: 'pipe'
|
|
578
577
|
});
|
|
579
|
-
|
|
578
|
+
return true;
|
|
580
579
|
} catch {
|
|
581
|
-
|
|
580
|
+
return false;
|
|
582
581
|
}
|
|
583
|
-
return this.adminCheckCache;
|
|
584
582
|
}
|
|
585
583
|
async screenshotBase64() {
|
|
586
584
|
if (this.destroyed) throw new Error('ComputerDevice has been destroyed');
|
|
@@ -813,7 +811,6 @@ Original error: ${lastRawMessage}`);
|
|
|
813
811
|
debug: (message)=>debugDevice(message)
|
|
814
812
|
}));
|
|
815
813
|
device_define_property(this, "useAppleScript", void 0);
|
|
816
|
-
device_define_property(this, "adminCheckCache", void 0);
|
|
817
814
|
device_define_property(this, "uri", void 0);
|
|
818
815
|
device_define_property(this, "inputPrimitives", {
|
|
819
816
|
pointer: {
|
|
@@ -1704,7 +1701,7 @@ class ComputerMCPServer extends BaseMCPServer {
|
|
|
1704
1701
|
constructor(toolsManager){
|
|
1705
1702
|
super({
|
|
1706
1703
|
name: '@midscene/computer-mcp',
|
|
1707
|
-
version: "1.9.1
|
|
1704
|
+
version: "1.9.1",
|
|
1708
1705
|
description: 'Control the computer desktop using natural language commands'
|
|
1709
1706
|
}, toolsManager);
|
|
1710
1707
|
}
|
package/dist/lib/cli.js
CHANGED
|
@@ -546,7 +546,7 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
546
546
|
}
|
|
547
547
|
async healthCheck() {
|
|
548
548
|
console.log('[HealthCheck] Starting health check...');
|
|
549
|
-
console.log("[HealthCheck] @midscene/computer v1.9.1
|
|
549
|
+
console.log("[HealthCheck] @midscene/computer v1.9.1");
|
|
550
550
|
console.log('[HealthCheck] Taking screenshot...');
|
|
551
551
|
const screenshotTimeout = 15000;
|
|
552
552
|
let timeoutId;
|
|
@@ -576,11 +576,11 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
576
576
|
const msg = `[HealthCheck] WARNING: Mouse control may not be working. Expected (${targetX}, ${targetY}), got (${movedPos.x}, ${movedPos.y}), delta=(${deltaX}, ${deltaY})`;
|
|
577
577
|
console.warn(msg);
|
|
578
578
|
debugDevice(msg);
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
579
|
+
if ('win32' === process.platform && !this.isRunningAsAdmin()) {
|
|
580
|
+
const hint = "Midscene is NOT running as Administrator. Windows blocks mouse/keyboard input to elevated (admin) applications from non-admin processes (UIPI). Please run your terminal or Node.js as Administrator and try again.";
|
|
581
|
+
console.error(`\n[HealthCheck] ${hint}\n`);
|
|
582
|
+
debugDevice(hint);
|
|
583
|
+
}
|
|
584
584
|
}
|
|
585
585
|
this.inputDriver.moveMouse(startPos.x, startPos.y);
|
|
586
586
|
console.log(`[HealthCheck] Mouse restored to (${startPos.x}, ${startPos.y})`);
|
|
@@ -597,16 +597,14 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
597
597
|
}
|
|
598
598
|
isRunningAsAdmin() {
|
|
599
599
|
if ('win32' !== process.platform) return false;
|
|
600
|
-
if (void 0 !== this.adminCheckCache) return this.adminCheckCache;
|
|
601
600
|
try {
|
|
602
601
|
(0, external_node_child_process_namespaceObject.execSync)('net session', {
|
|
603
602
|
stdio: 'pipe'
|
|
604
603
|
});
|
|
605
|
-
|
|
604
|
+
return true;
|
|
606
605
|
} catch {
|
|
607
|
-
|
|
606
|
+
return false;
|
|
608
607
|
}
|
|
609
|
-
return this.adminCheckCache;
|
|
610
608
|
}
|
|
611
609
|
async screenshotBase64() {
|
|
612
610
|
if (this.destroyed) throw new Error('ComputerDevice has been destroyed');
|
|
@@ -839,7 +837,6 @@ Original error: ${lastRawMessage}`);
|
|
|
839
837
|
debug: (message)=>debugDevice(message)
|
|
840
838
|
}));
|
|
841
839
|
device_define_property(this, "useAppleScript", void 0);
|
|
842
|
-
device_define_property(this, "adminCheckCache", void 0);
|
|
843
840
|
device_define_property(this, "uri", void 0);
|
|
844
841
|
device_define_property(this, "inputPrimitives", {
|
|
845
842
|
pointer: {
|
|
@@ -1727,7 +1724,7 @@ class ComputerMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools
|
|
|
1727
1724
|
const tools = new ComputerMidsceneTools();
|
|
1728
1725
|
(0, cli_namespaceObject.runToolsCLI)(tools, 'midscene-computer', {
|
|
1729
1726
|
stripPrefix: 'computer_',
|
|
1730
|
-
version: "1.9.1
|
|
1727
|
+
version: "1.9.1",
|
|
1731
1728
|
extraCommands: (0, core_namespaceObject.createReportCliCommands)()
|
|
1732
1729
|
}).catch((e)=>{
|
|
1733
1730
|
process.exit((0, cli_namespaceObject.reportCLIError)(e));
|
package/dist/lib/index.js
CHANGED
|
@@ -573,7 +573,7 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
573
573
|
}
|
|
574
574
|
async healthCheck() {
|
|
575
575
|
console.log('[HealthCheck] Starting health check...');
|
|
576
|
-
console.log("[HealthCheck] @midscene/computer v1.9.1
|
|
576
|
+
console.log("[HealthCheck] @midscene/computer v1.9.1");
|
|
577
577
|
console.log('[HealthCheck] Taking screenshot...');
|
|
578
578
|
const screenshotTimeout = 15000;
|
|
579
579
|
let timeoutId;
|
|
@@ -603,11 +603,11 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
603
603
|
const msg = `[HealthCheck] WARNING: Mouse control may not be working. Expected (${targetX}, ${targetY}), got (${movedPos.x}, ${movedPos.y}), delta=(${deltaX}, ${deltaY})`;
|
|
604
604
|
console.warn(msg);
|
|
605
605
|
debugDevice(msg);
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
606
|
+
if ('win32' === process.platform && !this.isRunningAsAdmin()) {
|
|
607
|
+
const hint = "Midscene is NOT running as Administrator. Windows blocks mouse/keyboard input to elevated (admin) applications from non-admin processes (UIPI). Please run your terminal or Node.js as Administrator and try again.";
|
|
608
|
+
console.error(`\n[HealthCheck] ${hint}\n`);
|
|
609
|
+
debugDevice(hint);
|
|
610
|
+
}
|
|
611
611
|
}
|
|
612
612
|
this.inputDriver.moveMouse(startPos.x, startPos.y);
|
|
613
613
|
console.log(`[HealthCheck] Mouse restored to (${startPos.x}, ${startPos.y})`);
|
|
@@ -624,16 +624,14 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
624
624
|
}
|
|
625
625
|
isRunningAsAdmin() {
|
|
626
626
|
if ('win32' !== process.platform) return false;
|
|
627
|
-
if (void 0 !== this.adminCheckCache) return this.adminCheckCache;
|
|
628
627
|
try {
|
|
629
628
|
(0, external_node_child_process_namespaceObject.execSync)('net session', {
|
|
630
629
|
stdio: 'pipe'
|
|
631
630
|
});
|
|
632
|
-
|
|
631
|
+
return true;
|
|
633
632
|
} catch {
|
|
634
|
-
|
|
633
|
+
return false;
|
|
635
634
|
}
|
|
636
|
-
return this.adminCheckCache;
|
|
637
635
|
}
|
|
638
636
|
async screenshotBase64() {
|
|
639
637
|
if (this.destroyed) throw new Error('ComputerDevice has been destroyed');
|
|
@@ -866,7 +864,6 @@ Original error: ${lastRawMessage}`);
|
|
|
866
864
|
debug: (message)=>debugDevice(message)
|
|
867
865
|
}));
|
|
868
866
|
device_define_property(this, "useAppleScript", void 0);
|
|
869
|
-
device_define_property(this, "adminCheckCache", void 0);
|
|
870
867
|
device_define_property(this, "uri", void 0);
|
|
871
868
|
device_define_property(this, "inputPrimitives", {
|
|
872
869
|
pointer: {
|
|
@@ -1799,7 +1796,7 @@ class ComputerMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools
|
|
|
1799
1796
|
}
|
|
1800
1797
|
const env_namespaceObject = require("@midscene/shared/env");
|
|
1801
1798
|
function version() {
|
|
1802
|
-
const currentVersion = "1.9.1
|
|
1799
|
+
const currentVersion = "1.9.1";
|
|
1803
1800
|
console.log(`@midscene/computer v${currentVersion}`);
|
|
1804
1801
|
return currentVersion;
|
|
1805
1802
|
}
|
package/dist/lib/mcp-server.js
CHANGED
|
@@ -560,7 +560,7 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
560
560
|
}
|
|
561
561
|
async healthCheck() {
|
|
562
562
|
console.log('[HealthCheck] Starting health check...');
|
|
563
|
-
console.log("[HealthCheck] @midscene/computer v1.9.1
|
|
563
|
+
console.log("[HealthCheck] @midscene/computer v1.9.1");
|
|
564
564
|
console.log('[HealthCheck] Taking screenshot...');
|
|
565
565
|
const screenshotTimeout = 15000;
|
|
566
566
|
let timeoutId;
|
|
@@ -590,11 +590,11 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
590
590
|
const msg = `[HealthCheck] WARNING: Mouse control may not be working. Expected (${targetX}, ${targetY}), got (${movedPos.x}, ${movedPos.y}), delta=(${deltaX}, ${deltaY})`;
|
|
591
591
|
console.warn(msg);
|
|
592
592
|
debugDevice(msg);
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
593
|
+
if ('win32' === process.platform && !this.isRunningAsAdmin()) {
|
|
594
|
+
const hint = "Midscene is NOT running as Administrator. Windows blocks mouse/keyboard input to elevated (admin) applications from non-admin processes (UIPI). Please run your terminal or Node.js as Administrator and try again.";
|
|
595
|
+
console.error(`\n[HealthCheck] ${hint}\n`);
|
|
596
|
+
debugDevice(hint);
|
|
597
|
+
}
|
|
598
598
|
}
|
|
599
599
|
this.inputDriver.moveMouse(startPos.x, startPos.y);
|
|
600
600
|
console.log(`[HealthCheck] Mouse restored to (${startPos.x}, ${startPos.y})`);
|
|
@@ -611,16 +611,14 @@ Available Displays: ${displays.length > 0 ? displays.map((d)=>d.name).join(', ')
|
|
|
611
611
|
}
|
|
612
612
|
isRunningAsAdmin() {
|
|
613
613
|
if ('win32' !== process.platform) return false;
|
|
614
|
-
if (void 0 !== this.adminCheckCache) return this.adminCheckCache;
|
|
615
614
|
try {
|
|
616
615
|
(0, external_node_child_process_namespaceObject.execSync)('net session', {
|
|
617
616
|
stdio: 'pipe'
|
|
618
617
|
});
|
|
619
|
-
|
|
618
|
+
return true;
|
|
620
619
|
} catch {
|
|
621
|
-
|
|
620
|
+
return false;
|
|
622
621
|
}
|
|
623
|
-
return this.adminCheckCache;
|
|
624
622
|
}
|
|
625
623
|
async screenshotBase64() {
|
|
626
624
|
if (this.destroyed) throw new Error('ComputerDevice has been destroyed');
|
|
@@ -853,7 +851,6 @@ Original error: ${lastRawMessage}`);
|
|
|
853
851
|
debug: (message)=>debugDevice(message)
|
|
854
852
|
}));
|
|
855
853
|
device_define_property(this, "useAppleScript", void 0);
|
|
856
|
-
device_define_property(this, "adminCheckCache", void 0);
|
|
857
854
|
device_define_property(this, "uri", void 0);
|
|
858
855
|
device_define_property(this, "inputPrimitives", {
|
|
859
856
|
pointer: {
|
|
@@ -1747,7 +1744,7 @@ class ComputerMCPServer extends mcp_namespaceObject.BaseMCPServer {
|
|
|
1747
1744
|
constructor(toolsManager){
|
|
1748
1745
|
super({
|
|
1749
1746
|
name: '@midscene/computer-mcp',
|
|
1750
|
-
version: "1.9.1
|
|
1747
|
+
version: "1.9.1",
|
|
1751
1748
|
description: 'Control the computer desktop using natural language commands'
|
|
1752
1749
|
}, toolsManager);
|
|
1753
1750
|
}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -77,8 +77,6 @@ export declare class ComputerDevice implements AbstractInterface {
|
|
|
77
77
|
* to avoid focus issues with system overlays (e.g. Spotlight).
|
|
78
78
|
*/
|
|
79
79
|
private useAppleScript;
|
|
80
|
-
/** Cached result of the elevation check; see isRunningAsAdmin(). */
|
|
81
|
-
private adminCheckCache?;
|
|
82
80
|
uri?: string;
|
|
83
81
|
readonly inputPrimitives: ComputerInputPrimitives;
|
|
84
82
|
constructor(options?: ComputerDeviceOpt);
|
|
@@ -92,10 +90,6 @@ export declare class ComputerDevice implements AbstractInterface {
|
|
|
92
90
|
/**
|
|
93
91
|
* Check if the current process is running with Administrator privileges.
|
|
94
92
|
* Uses "net session" which succeeds only when elevated.
|
|
95
|
-
*
|
|
96
|
-
* The result is cached because elevation cannot change during the process
|
|
97
|
-
* lifetime, and the underlying `execSync('net session')` is a blocking
|
|
98
|
-
* subprocess spawn that should not run on every connect / health check.
|
|
99
93
|
*/
|
|
100
94
|
private isRunningAsAdmin;
|
|
101
95
|
screenshotBase64(): Promise<string>;
|
|
@@ -29,8 +29,6 @@ declare class ComputerDevice implements AbstractInterface {
|
|
|
29
29
|
* to avoid focus issues with system overlays (e.g. Spotlight).
|
|
30
30
|
*/
|
|
31
31
|
private useAppleScript;
|
|
32
|
-
/** Cached result of the elevation check; see isRunningAsAdmin(). */
|
|
33
|
-
private adminCheckCache?;
|
|
34
32
|
uri?: string;
|
|
35
33
|
readonly inputPrimitives: ComputerInputPrimitives;
|
|
36
34
|
constructor(options?: ComputerDeviceOpt);
|
|
@@ -44,10 +42,6 @@ declare class ComputerDevice implements AbstractInterface {
|
|
|
44
42
|
/**
|
|
45
43
|
* Check if the current process is running with Administrator privileges.
|
|
46
44
|
* Uses "net session" which succeeds only when elevated.
|
|
47
|
-
*
|
|
48
|
-
* The result is cached because elevation cannot change during the process
|
|
49
|
-
* lifetime, and the underlying `execSync('net session')` is a blocking
|
|
50
|
-
* subprocess spawn that should not run on every connect / health check.
|
|
51
45
|
*/
|
|
52
46
|
private isRunningAsAdmin;
|
|
53
47
|
screenshotBase64(): Promise<string>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@midscene/computer",
|
|
3
|
-
"version": "1.9.1
|
|
3
|
+
"version": "1.9.1",
|
|
4
4
|
"description": "Midscene.js Computer Desktop Automation",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -38,8 +38,8 @@
|
|
|
38
38
|
"@computer-use/libnut": "^4.2.0",
|
|
39
39
|
"clipboardy": "^4.0.0",
|
|
40
40
|
"screenshot-desktop": "^1.15.3",
|
|
41
|
-
"@midscene/core": "1.9.1
|
|
42
|
-
"@midscene/shared": "1.9.1
|
|
41
|
+
"@midscene/core": "1.9.1",
|
|
42
|
+
"@midscene/shared": "1.9.1"
|
|
43
43
|
},
|
|
44
44
|
"optionalDependencies": {
|
|
45
45
|
"node-mac-permissions": "2.5.0"
|