@vint.tri/report_gen_mcp 1.5.21 → 1.5.22

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.
Files changed (2) hide show
  1. package/dist/index.js +2 -20
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -4,7 +4,6 @@ import { program } from 'commander';
4
4
  import { generateReport } from './utils/reportGenerator.js';
5
5
  import path from 'path';
6
6
  import fs from 'fs-extra';
7
- import os from 'os';
8
7
  import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
9
8
  import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
10
9
  import { pathToFileURL } from 'url';
@@ -99,19 +98,10 @@ program
99
98
  });
100
99
  // Handle stdio mode for Claude Desktop integration
101
100
  if (process.argv.length === 2) {
102
- const serverPort = 3000;
103
- const reportsDir = process.env.REPORTS_DIR || os.tmpdir();
104
- fs.ensureDirSync(reportsDir);
105
- // Start a simple static file server
106
- const app = express();
107
- app.use('/reports', express.static(reportsDir));
108
- app.listen(serverPort, () => {
109
- console.log(`File server running at http://localhost:${serverPort}/reports`);
110
- });
111
101
  // No command specified, run in stdio mode using MCP SDK
112
102
  const mcpServer = new McpServer({
113
103
  name: "report_gen_mcp",
114
- version: "1.5.21"
104
+ version: "1.5.22"
115
105
  }, {
116
106
  // Disable health check to prevent automatic calls
117
107
  capabilities: {
@@ -121,15 +111,7 @@ if (process.argv.length === 2) {
121
111
  mcpServer.registerTool(simpleReportTool.name, {
122
112
  description: simpleReportTool.description,
123
113
  inputSchema: simpleReportTool.inputSchema,
124
- }, async (args) => {
125
- const result = await simpleReportTool.action(args);
126
- // Modify the resource URI to be a localhost URL
127
- if (result.content[0].type === 'resource') {
128
- const fileName = path.basename(new URL(result.content[0].resource.uri).pathname);
129
- result.content[0].resource.uri = `http://localhost:${serverPort}/reports/${fileName}`;
130
- }
131
- return result;
132
- });
114
+ }, simpleReportTool.action);
133
115
  async function main() {
134
116
  const transport = new StdioServerTransport();
135
117
  await mcpServer.connect(transport);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vint.tri/report_gen_mcp",
3
- "version": "1.5.21",
3
+ "version": "1.5.22",
4
4
  "description": "CLI tool for generating HTML reports with embedded charts and images",
5
5
  "main": "dist/index.js",
6
6
  "bin": {