@ikhono/mcp 0.1.3 → 0.2.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.
Files changed (2) hide show
  1. package/dist/index.js +27 -9
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -168,7 +168,7 @@ async function handleRate(client2, args2) {
168
168
  // src/version.ts
169
169
  import { createRequire } from "module";
170
170
  function getVersion() {
171
- if (true) return "0.1.3";
171
+ if (true) return "0.2.0";
172
172
  const require2 = createRequire(import.meta.url);
173
173
  return require2("../package.json").version;
174
174
  }
@@ -185,7 +185,7 @@ function readCliConfig() {
185
185
  }
186
186
  var cliConfig = readCliConfig();
187
187
  var args = process.argv.slice(2);
188
- var apiUrl = "http://localhost:3456";
188
+ var apiUrl = "https://ikhono.io";
189
189
  var token;
190
190
  for (let i = 0; i < args.length; i++) {
191
191
  if (args[i] === "--api-url" && args[i + 1]) {
@@ -196,7 +196,7 @@ for (let i = 0; i < args.length; i++) {
196
196
  i++;
197
197
  }
198
198
  }
199
- apiUrl = process.env.IKHONO_API_URL || apiUrl || cliConfig.apiUrl || "http://localhost:3456";
199
+ apiUrl = process.env.IKHONO_API_URL || apiUrl || cliConfig.apiUrl || "https://ikhono.io";
200
200
  token = process.env.IKHONO_API_TOKEN || token || cliConfig.token;
201
201
  var client = new IkhonoClient({ apiUrl, token });
202
202
  var server = new McpServer({
@@ -205,7 +205,10 @@ var server = new McpServer({
205
205
  }, {
206
206
  instructions: `You have access to iKhono, a registry of AI skills that enhance your capabilities. When the user asks you to do something that could benefit from specialized expertise (code review, test writing, documentation, refactoring, etc.), use ikhono_skill_search to find relevant skills, then use ikhono_skill_get to load the skill's full instructions. Follow those instructions to give a better, more structured response. Always tell the user which skill you're using and its rating.`
207
207
  });
208
- server.tool(searchToolName, searchToolDescription, searchToolSchema.shape, async (args2) => {
208
+ server.registerTool(searchToolName, {
209
+ description: searchToolDescription,
210
+ inputSchema: searchToolSchema.shape
211
+ }, async (args2) => {
209
212
  try {
210
213
  const results = await handleSearch(client, searchToolSchema.parse(args2));
211
214
  return { content: [{ type: "text", text: formatSearchResults(results) }] };
@@ -213,7 +216,10 @@ server.tool(searchToolName, searchToolDescription, searchToolSchema.shape, async
213
216
  return { content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], isError: true };
214
217
  }
215
218
  });
216
- server.tool(getSkillToolName, getSkillToolDescription, getSkillToolSchema.shape, async (args2) => {
219
+ server.registerTool(getSkillToolName, {
220
+ description: getSkillToolDescription,
221
+ inputSchema: getSkillToolSchema.shape
222
+ }, async (args2) => {
217
223
  try {
218
224
  const parsed = getSkillToolSchema.parse(args2);
219
225
  const skill = await handleGetSkill(client, parsed);
@@ -233,7 +239,10 @@ This helps skill creators improve their work.`;
233
239
  return { content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], isError: true };
234
240
  }
235
241
  });
236
- server.tool(pinToolName, pinToolDescription, pinToolSchema.shape, async (args2) => {
242
+ server.registerTool(pinToolName, {
243
+ description: pinToolDescription,
244
+ inputSchema: pinToolSchema.shape
245
+ }, async (args2) => {
237
246
  try {
238
247
  const result = await handlePin(client, pinToolSchema.parse(args2));
239
248
  return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] };
@@ -241,7 +250,10 @@ server.tool(pinToolName, pinToolDescription, pinToolSchema.shape, async (args2)
241
250
  return { content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], isError: true };
242
251
  }
243
252
  });
244
- server.tool(unpinToolName, unpinToolDescription, unpinToolSchema.shape, async (args2) => {
253
+ server.registerTool(unpinToolName, {
254
+ description: unpinToolDescription,
255
+ inputSchema: unpinToolSchema.shape
256
+ }, async (args2) => {
245
257
  try {
246
258
  const result = await handleUnpin(client, unpinToolSchema.parse(args2));
247
259
  return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] };
@@ -249,7 +261,10 @@ server.tool(unpinToolName, unpinToolDescription, unpinToolSchema.shape, async (a
249
261
  return { content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], isError: true };
250
262
  }
251
263
  });
252
- server.tool(listPinnedToolName, listPinnedToolDescription, listPinnedToolSchema.shape, async () => {
264
+ server.registerTool(listPinnedToolName, {
265
+ description: listPinnedToolDescription,
266
+ inputSchema: listPinnedToolSchema.shape
267
+ }, async () => {
253
268
  try {
254
269
  const result = await handleListPinned(client);
255
270
  return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] };
@@ -257,7 +272,10 @@ server.tool(listPinnedToolName, listPinnedToolDescription, listPinnedToolSchema.
257
272
  return { content: [{ type: "text", text: `Error: ${err instanceof Error ? err.message : String(err)}` }], isError: true };
258
273
  }
259
274
  });
260
- server.tool(rateToolName, rateToolDescription, rateToolSchema.shape, async (args2) => {
275
+ server.registerTool(rateToolName, {
276
+ description: rateToolDescription,
277
+ inputSchema: rateToolSchema.shape
278
+ }, async (args2) => {
261
279
  try {
262
280
  const result = await handleRate(client, rateToolSchema.parse(args2));
263
281
  return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ikhono/mcp",
3
- "version": "0.1.3",
3
+ "version": "0.2.0",
4
4
  "description": "iKhono MCP Server — runtime skill router for AI agents",
5
5
  "type": "module",
6
6
  "bin": {