law-mcp-server 0.1.2 → 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.
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
 
3
- const entry = new URL("../dist/index.js", import.meta.url);
3
+ const entry = new URL("../dist/src/index.js", import.meta.url);
4
4
 
5
5
  import(entry.href).catch((error) => {
6
6
  console.error(
package/dist/src/index.js CHANGED
@@ -2,6 +2,23 @@
2
2
  import { StdioJsonRpcServer } from "./mcp.js";
3
3
  import { tools, resolveTool } from "./tools.js";
4
4
  const server = new StdioJsonRpcServer();
5
+ const serverInfo = { name: "law-mcp-server", version: "0.1.2" };
6
+ server.register("initialize", async (params) => {
7
+ const payload = (params ?? {});
8
+ const protocolVersion = typeof payload.protocolVersion === "string"
9
+ ? payload.protocolVersion
10
+ : "2024-06-17";
11
+ return {
12
+ protocolVersion,
13
+ serverInfo,
14
+ capabilities: {
15
+ tools: {
16
+ list: true,
17
+ call: true,
18
+ },
19
+ },
20
+ };
21
+ });
5
22
  server.register("ping", async () => ({ ok: true }));
6
23
  server.register("tools/list", async () => ({
7
24
  tools: tools.map((tool) => ({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "law-mcp-server",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "type": "module",
5
5
  "description": "MCP server for e-Gov law API consistency checks",
6
6
  "files": [
@@ -12,7 +12,7 @@
12
12
  "bin": {
13
13
  "law-mcp-server": "bin/law-mcp-server.js"
14
14
  },
15
- "main": "dist/index.js",
15
+ "main": "dist/src/index.js",
16
16
  "scripts": {
17
17
  "build": "tsc",
18
18
  "prepare": "npm run build",