botbrowser-mcp 0.1.1 → 0.1.3

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/cli.d.ts CHANGED
@@ -1,9 +1,5 @@
1
1
  #!/usr/bin/env node
2
2
  /**
3
3
  * botbrowser-mcp CLI
4
- * 转发所有参数到 @playwright/mcp
5
4
  */
6
- declare const spawn: any;
7
- declare const path: any;
8
- declare const mcpBin: any;
9
- declare const child: any;
5
+ export {};
package/dist/cli.js CHANGED
@@ -1,17 +1,15 @@
1
1
  #!/usr/bin/env node
2
+ "use strict";
2
3
  /**
3
4
  * botbrowser-mcp CLI
4
- * 转发所有参数到 @playwright/mcp
5
5
  */
6
- const { spawn } = require('child_process');
7
- const path = require('path');
8
- // 找到 @playwright/mcp 的 bin 文件
9
- const mcpBin = path.resolve(__dirname, '../node_modules/@playwright/mcp/cli.js');
10
- // 转发所有参数
11
- const child = spawn('node', [mcpBin, ...process.argv.slice(2)], {
12
- stdio: 'inherit'
13
- });
14
- child.on('exit', (code) => {
15
- process.exit(code || 0);
16
- });
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ const stdio_js_1 = require("@modelcontextprotocol/sdk/server/stdio.js");
8
+ const index_1 = require("./index");
9
+ (async () => {
10
+ // 直接使用 @playwright/mcp 的 createConnection
11
+ const server = await (0, index_1.createConnection)();
12
+ const transport = new stdio_js_1.StdioServerTransport();
13
+ await server.connect(transport);
14
+ })();
17
15
  //# sourceMappingURL=cli.js.map
package/dist/cli.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;GAGG;AAEH,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;AAC3C,MAAM,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AAE7B,8BAA8B;AAC9B,MAAM,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,wCAAwC,CAAC,CAAC;AAEjF,SAAS;AACT,MAAM,KAAK,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE;IAC9D,KAAK,EAAE,SAAS;CACjB,CAAC,CAAC;AAEH,KAAK,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,EAAE;IACxB,OAAO,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC;AAC1B,CAAC,CAAC,CAAC"}
1
+ {"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";;AACA;;GAEG;;AAEH,wEAAiF;AACjF,mCAA2C;AAE3C,CAAC,KAAK,IAAI,EAAE;IACV,0CAA0C;IAC1C,MAAM,MAAM,GAAG,MAAM,IAAA,wBAAgB,GAAE,CAAC;IACxC,MAAM,SAAS,GAAG,IAAI,+BAAoB,EAAE,CAAC;IAC7C,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;AAClC,CAAC,CAAC,EAAE,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "botbrowser-mcp",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "description": "Enhanced browser automation MCP server based on Playwright",
5
5
  "author": "tonwe",
6
6
  "license": "Apache-2.0",