@modelcontextprotocol/inspector 0.7.0 → 0.8.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/README.md +13 -1
- package/bin/cli.js +36 -38
- package/client/bin/cli.js +16 -2
- package/client/dist/assets/{OAuthCallback-C5xCfXlk.js → OAuthCallback-DrQsfqzq.js} +1 -1
- package/client/dist/assets/{index-Dt6l7sEy.css → index-BxIjx6su.css} +59 -12
- package/client/dist/assets/{index-D7o7JmLV.js → index-DrNN0pLZ.js} +464 -171
- package/client/dist/index.html +2 -2
- package/package.json +5 -3
- package/server/build/index.js +15 -13
package/client/dist/index.html
CHANGED
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
<link rel="icon" type="image/svg+xml" href="/mcp.svg" />
|
|
6
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
7
7
|
<title>MCP Inspector</title>
|
|
8
|
-
<script type="module" crossorigin src="/assets/index-
|
|
9
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
8
|
+
<script type="module" crossorigin src="/assets/index-DrNN0pLZ.js"></script>
|
|
9
|
+
<link rel="stylesheet" crossorigin href="/assets/index-BxIjx6su.css">
|
|
10
10
|
</head>
|
|
11
11
|
<body>
|
|
12
12
|
<div id="root"></div>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@modelcontextprotocol/inspector",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.0",
|
|
4
4
|
"description": "Model Context Protocol inspector",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Anthropic, PBC (https://anthropic.com)",
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
"scripts": {
|
|
24
24
|
"dev": "concurrently \"cd client && npm run dev\" \"cd server && npm run dev\"",
|
|
25
25
|
"dev:windows": "concurrently \"cd client && npm run dev\" \"cd server && npm run dev:windows",
|
|
26
|
+
"test": "npm run prettier-check && cd client && npm test",
|
|
26
27
|
"build-server": "cd server && npm run build",
|
|
27
28
|
"build-client": "cd client && npm run build",
|
|
28
29
|
"build": "npm run build-server && npm run build-client",
|
|
@@ -31,11 +32,12 @@
|
|
|
31
32
|
"start": "node ./bin/cli.js",
|
|
32
33
|
"prepare": "npm run build",
|
|
33
34
|
"prettier-fix": "prettier --write .",
|
|
35
|
+
"prettier-check": "prettier --check .",
|
|
34
36
|
"publish-all": "npm publish --workspaces --access public && npm publish --access public"
|
|
35
37
|
},
|
|
36
38
|
"dependencies": {
|
|
37
|
-
"@modelcontextprotocol/inspector-client": "^0.
|
|
38
|
-
"@modelcontextprotocol/inspector-server": "^0.
|
|
39
|
+
"@modelcontextprotocol/inspector-client": "^0.8.0",
|
|
40
|
+
"@modelcontextprotocol/inspector-server": "^0.8.0",
|
|
39
41
|
"concurrently": "^9.0.1",
|
|
40
42
|
"shell-quote": "^1.8.2",
|
|
41
43
|
"spawn-rx": "^5.1.2",
|
package/server/build/index.js
CHANGED
|
@@ -74,11 +74,12 @@ const createTransport = async (req) => {
|
|
|
74
74
|
throw new Error("Invalid transport type specified");
|
|
75
75
|
}
|
|
76
76
|
};
|
|
77
|
+
let backingServerTransport;
|
|
77
78
|
app.get("/sse", async (req, res) => {
|
|
78
79
|
try {
|
|
79
80
|
console.log("New SSE connection");
|
|
80
|
-
let backingServerTransport;
|
|
81
81
|
try {
|
|
82
|
+
await backingServerTransport?.close();
|
|
82
83
|
backingServerTransport = await createTransport(req);
|
|
83
84
|
}
|
|
84
85
|
catch (error) {
|
|
@@ -146,16 +147,17 @@ app.get("/config", (req, res) => {
|
|
|
146
147
|
res.status(500).json(error);
|
|
147
148
|
}
|
|
148
149
|
});
|
|
149
|
-
const PORT = process.env.PORT ||
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
|
|
150
|
+
const PORT = process.env.PORT || 6277;
|
|
151
|
+
const server = app.listen(PORT);
|
|
152
|
+
server.on("listening", () => {
|
|
153
|
+
console.log(`⚙️ Proxy server listening on port ${PORT}`);
|
|
154
|
+
});
|
|
155
|
+
server.on("error", (err) => {
|
|
156
|
+
if (err.message.includes(`EADDRINUSE`)) {
|
|
157
|
+
console.error(`❌ Proxy Server PORT IS IN USE at port ${PORT} ❌ `);
|
|
158
|
+
}
|
|
159
|
+
else {
|
|
160
|
+
console.error(err.message);
|
|
161
|
+
}
|
|
160
162
|
process.exit(1);
|
|
161
|
-
}
|
|
163
|
+
});
|