Commit Graph

3 Commits

Author SHA1 Message Date
Namhyeon, Go
03d078bde8 Allow no-reply notifications; also write messages to stderr
Treat a callback returning false as a signal to suppress a JSON-RPC reply (jsonrpc2.extract). Add a special-case in mcploader to return false for "notifications/initialized" so no response is sent. In stdio-server, skip sending falsy messages, keep object serialization, and write outgoing messages to both StdOut and StdErr (useful for logging/debugging). Small cleanup in catch formatting.
2026-04-12 21:11:22 +09:00
Namhyeon, Go
c22ca660ec Add MCP JSON-RPC handlers and stdio fixes
Implement MCP JSON-RPC handling and related I/O fixes: mcploader now handles initialize, tools/list and tools/call (implements add_both_numbers) and returns JSON-RPC responses; stdio-server.send serializes object messages before writing; console logging on WScript now writes muted messages to StdErr; bump jsonrpc2 version to 0.1.7 and reformat extract(). These changes enable proper MCP capability negotiation, tool discovery and invocation over stdio.
2026-04-12 20:39:50 +09:00
Namhyeon, Go
4c48fdbb4d Add stdio server, mcploader and JSON-RPC extract
Introduce a StdioServer module and mcploader entry script, and extend jsonrpc2 with an extract() helper. stdio-server.js provides an EventTarget-based wrapper for reading/writing via WScript stdio. mcploader.js uses the server and JsonRpc2.extract to parse incoming JSON-RPC messages and respond. Also change DEFAULT_JSONRPC2_URL to http://localhost:5555, export the new extract function, and bump jsonrpc2 version to 0.1.6.
2026-04-12 19:11:30 +09:00