@mcp-use/inspector 0.8.2 → 0.9.0-canary.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/cli.js CHANGED
@@ -1399,6 +1399,35 @@ function registerStaticRoutes(app2, clientDistPath) {
1399
1399
  app2.get("/", (c) => {
1400
1400
  return c.redirect("/inspector");
1401
1401
  });
1402
+ app2.get("/inspector", (c) => {
1403
+ const indexPath = join2(distPath, "index.html");
1404
+ if (existsSync2(indexPath)) {
1405
+ const content = readFileSync(indexPath, "utf-8");
1406
+ return c.html(content);
1407
+ }
1408
+ return c.html(`
1409
+ <!DOCTYPE html>
1410
+ <html>
1411
+ <head>
1412
+ <title>MCP Inspector</title>
1413
+ </head>
1414
+ <body>
1415
+ <h1>MCP Inspector</h1>
1416
+ <p>Client files not found. Please run 'yarn build' to build the UI.</p>
1417
+ </body>
1418
+ </html>
1419
+ `);
1420
+ });
1421
+ const handleInspectorRoute = (c) => {
1422
+ const indexPath = join2(distPath, "index.html");
1423
+ if (existsSync2(indexPath)) {
1424
+ const content = readFileSync(indexPath, "utf-8");
1425
+ return c.html(content);
1426
+ }
1427
+ return c.notFound();
1428
+ };
1429
+ app2.get("/inspector/*", handleInspectorRoute);
1430
+ app2.post("/inspector/*", handleInspectorRoute);
1402
1431
  app2.get("*", (c) => {
1403
1432
  const indexPath = join2(distPath, "index.html");
1404
1433
  if (existsSync2(indexPath)) {
@@ -1,11 +1,11 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/display-YIYC6WJE-CgdZXpyl.js","assets/index-BUncxtIr.js","assets/index-CwF__a_n.css"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/display-YIYC6WJE-DkdhQKHj.js","assets/index-B6TgCktd.js","assets/index-Br7cLVs6.css"])))=>i.map(i=>d[i]);
2
2
  var __defProp = Object.defineProperty;
3
3
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4
4
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
5
5
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
6
- import { _ as __name, c as ZodIssueCode, u as unionType, a as anyType, d as booleanType, n as numberType, s as stringType, e as arrayType, o as objectType, f as nullType, Z as ZodFirstPartyTypeKind, h as custom, i as ZodType$1, l as literalType, j as undefinedType, k as functionType, p as promiseType, m as enumType, r as recordType, q as instanceOfType, t as logger, w as __vitePreload, v as v4$1 } from "./index-BUncxtIr.js";
7
- import { B, x, H, L, y, M, W, z } from "./index-BUncxtIr.js";
8
- import { u as rng, w as unsafeStringify, x as parse$1, y as $constructor, z as $ZodError, A as flattenError, B as formatError, C as _parse, D as _safeParse, E as _parseAsync, F as _safeParseAsync, G as _any, H as $ZodAny, I as $ZodType, d as clone, J as _overwrite, g as globalRegistry, K as _refine, L as normalizeParams, M as _array, N as $ZodCheck, O as issue, h as $ZodOptional, Q as $ZodNullable, R as $ZodNonOptional, S as $ZodUnion, U as $ZodIntersection, W as $ZodPipe, X as $ZodTransform, Y as $ZodDefault, Z as $ZodPrefault, a0 as $ZodCatch, a1 as $ZodReadonly, a2 as $ZodArray, a3 as _minLength, a4 as _maxLength, a5 as _length, a6 as $ZodCustom, a7 as camelCase, s as snakeCase, v as v4, P as PQueueMod, p as pRetry, a as v5, b as styles, c as parseAsync$1, i as parse$2, j as extend, f as partial, _ as _never, $ as $ZodNever, e as _unknown, k as $ZodUnknown, t as toJSONSchema, l as deepCompareStrict, V as Validator, m as dereference, n as validate$1, o as getEncodingNameForModel, T as Tiktoken, q as prettifyError, r as validate$2, a8 as $ZodRegistry } from "./chunk-VL2OQCWN-BXe1iwaF.js";
6
+ import { _ as __name, c as ZodIssueCode, u as unionType, a as anyType, d as booleanType, n as numberType, s as stringType, e as arrayType, o as objectType, f as nullType, Z as ZodFirstPartyTypeKind, h as custom, i as ZodType$1, l as literalType, j as undefinedType, k as functionType, p as promiseType, m as enumType, r as recordType, q as instanceOfType, t as logger, w as __vitePreload, v as v4$1 } from "./index-B6TgCktd.js";
7
+ import { B, x, H, L, y, M, W, z } from "./index-B6TgCktd.js";
8
+ import { u as rng, w as unsafeStringify, x as parse$1, y as $constructor, z as $ZodError, A as flattenError, B as formatError, C as _parse, D as _safeParse, E as _parseAsync, F as _safeParseAsync, G as _any, H as $ZodAny, I as $ZodType, d as clone, J as _overwrite, g as globalRegistry, K as _refine, L as normalizeParams, M as _array, N as $ZodCheck, O as issue, h as $ZodOptional, Q as $ZodNullable, R as $ZodNonOptional, S as $ZodUnion, U as $ZodIntersection, W as $ZodPipe, X as $ZodTransform, Y as $ZodDefault, Z as $ZodPrefault, a0 as $ZodCatch, a1 as $ZodReadonly, a2 as $ZodArray, a3 as _minLength, a4 as _maxLength, a5 as _length, a6 as $ZodCustom, a7 as camelCase, s as snakeCase, v as v4, P as PQueueMod, p as pRetry, a as v5, b as styles, c as parseAsync$1, i as parse$2, j as extend, f as partial, _ as _never, $ as $ZodNever, e as _unknown, k as $ZodUnknown, t as toJSONSchema, l as deepCompareStrict, V as Validator, m as dereference, n as validate$1, o as getEncodingNameForModel, T as Tiktoken, q as prettifyError, r as validate$2, a8 as $ZodRegistry } from "./chunk-VL2OQCWN-CX6x4kxU.js";
9
9
  import { o as os } from "./__vite-browser-external-CHS79mP1.js";
10
10
  import { j as join, d as dirname, i as isAbsolute } from "./path-QsnVvLoj.js";
11
11
  import "./index-DX0TIfSM.js";
@@ -37536,7 +37536,7 @@ var MCPAgent = (_p = class {
37536
37536
  */
37537
37537
  async *prettyStreamEvents(query, maxSteps, manageConnector = true, externalHistory, outputSchema) {
37538
37538
  const { prettyStreamEvents: prettyStream } = await __vitePreload(async () => {
37539
- const { prettyStreamEvents: prettyStream2 } = await import("./display-YIYC6WJE-CgdZXpyl.js");
37539
+ const { prettyStreamEvents: prettyStream2 } = await import("./display-YIYC6WJE-DkdhQKHj.js");
37540
37540
  return { prettyStreamEvents: prettyStream2 };
37541
37541
  }, true ? __vite__mapDeps([0,1,2]) : void 0);
37542
37542
  const finalResponse = "";
@@ -1,4 +1,4 @@
1
- import { g as getDefaultExportFromCjs } from "./index-BUncxtIr.js";
1
+ import { g as getDefaultExportFromCjs } from "./index-B6TgCktd.js";
2
2
  import { r as requireBase64Js } from "./index-DX0TIfSM.js";
3
3
  var decamelize;
4
4
  var hasRequiredDecamelize;
@@ -1,4 +1,4 @@
1
- import { _ as __name } from "./index-BUncxtIr.js";
1
+ import { _ as __name } from "./index-B6TgCktd.js";
2
2
  var core;
3
3
  var hasRequiredCore;
4
4
  function requireCore() {
@@ -1,4 +1,4 @@
1
- import { _ as __export, A as AsyncCaller } from "./index-Dh5c60Cf.js";
1
+ import { _ as __export, A as AsyncCaller } from "./index-C74kq9On.js";
2
2
  var chunk_array_exports = {};
3
3
  __export(chunk_array_exports, { chunkArray: () => chunkArray });
4
4
  const chunkArray = (arr, chunkSize) => arr.reduce((chunks, elem, index) => {