midnight-mcp 0.1.40 → 0.1.41
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 +3 -0
- package/dist/server.js +5 -2
- package/dist/tools/health.js +5 -2
- package/package.json +1 -1
package/README.md
CHANGED
package/dist/server.js
CHANGED
|
@@ -7,8 +7,11 @@ import { allTools } from "./tools/index.js";
|
|
|
7
7
|
import { allResources, getDocumentation, getCode, getSchema, } from "./resources/index.js";
|
|
8
8
|
import { promptDefinitions, generatePrompt } from "./prompts/index.js";
|
|
9
9
|
import { registerSamplingCallback } from "./services/index.js";
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
import { createRequire } from "module";
|
|
11
|
+
// Read version from package.json (single source of truth)
|
|
12
|
+
const require = createRequire(import.meta.url);
|
|
13
|
+
const packageJson = require("../package.json");
|
|
14
|
+
const CURRENT_VERSION = packageJson.version;
|
|
12
15
|
const SERVER_INFO = {
|
|
13
16
|
name: "midnight-mcp",
|
|
14
17
|
version: CURRENT_VERSION,
|
package/dist/tools/health.js
CHANGED
|
@@ -6,8 +6,11 @@ import * as os from "os";
|
|
|
6
6
|
import * as path from "path";
|
|
7
7
|
import { getHealthStatus, getQuickHealthStatus, getRateLimitStatus, formatRateLimitStatus, } from "../utils/index.js";
|
|
8
8
|
import { searchCache, fileCache, metadataCache } from "../utils/cache.js";
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
import { createRequire } from "module";
|
|
10
|
+
// Read version from package.json (single source of truth)
|
|
11
|
+
const require = createRequire(import.meta.url);
|
|
12
|
+
const packageJson = require("../../package.json");
|
|
13
|
+
const CURRENT_VERSION = packageJson.version;
|
|
11
14
|
// Schema definitions
|
|
12
15
|
export const HealthCheckInputSchema = z.object({
|
|
13
16
|
detailed: z
|