kaneo-mcp 0.0.4 → 0.0.6

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/bin/kaneo-mcp.js CHANGED
@@ -1,14 +1,6 @@
1
- #!/usr/bin/env node
2
- import { createRequire } from "module";
3
- import { fileURLToPath } from "url";
4
- import { dirname, join } from "path";
5
- import { execSync } from "child_process";
6
-
7
- const scriptPath = fileURLToPath(import.meta.url);
8
- const scriptDir = dirname(scriptPath);
9
- const distPath = join(scriptDir, "..", "dist", "index.js");
10
-
11
- const require = createRequire(import.meta.url);
12
- const modulePath = require.resolve(distPath);
13
-
14
- execSync(`node ${modulePath}`, { stdio: "inherit" });
1
+ #!/bin/sh
2
+ basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
3
+ case "$(uname -s)" in
4
+ CYGWIN*|MINGW*|MSYS*) basedir=$(cygpath -w "$basedir");;
5
+ esac
6
+ exec node "$basedir/../dist/index.js" "$@"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kaneo-mcp",
3
- "version": "0.0.4",
3
+ "version": "0.0.6",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
package/src/client.ts CHANGED
@@ -405,6 +405,13 @@ export class KaneoClient {
405
405
  }
406
406
 
407
407
  // Workspace
408
+ async listWorkspaces() {
409
+ // Uses search endpoint with type=workspaces
410
+ // Using a space as query since API requires at least 1 character
411
+ const params = new URLSearchParams({ q: " ", type: "workspaces" });
412
+ return this.request<{ results: unknown[] }>(`/search?${params.toString()}`);
413
+ }
414
+
408
415
  async listWorkspaceMembers(workspaceId: string) {
409
416
  return this.request<{ members: unknown[] }>(
410
417
  `/workspace/${workspaceId}/members`,
package/src/index.ts CHANGED
@@ -591,6 +591,15 @@ class KaneoMCPServer {
591
591
  };
592
592
 
593
593
  // Workspace
594
+ case "list_workspaces":
595
+ return {
596
+ content: [
597
+ {
598
+ type: "text",
599
+ text: JSON.stringify(await this.client.listWorkspaces()),
600
+ },
601
+ ],
602
+ };
594
603
  case "list_workspace_members":
595
604
  return {
596
605
  content: [
@@ -1260,6 +1269,11 @@ class KaneoMCPServer {
1260
1269
  },
1261
1270
 
1262
1271
  // Workspace
1272
+ {
1273
+ name: "list_workspaces",
1274
+ description: "List all workspaces the current user has access to",
1275
+ inputSchema: { type: "object", properties: {} },
1276
+ },
1263
1277
  {
1264
1278
  name: "list_workspace_members",
1265
1279
  description: "List all members in a workspace",