@chessceo/mcp 0.49.1 → 0.49.2

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 CHANGED
@@ -6,7 +6,7 @@ Player/game lookups need no API key or auth. Cloud engines and prep-file tools n
6
6
 
7
7
  ## What it can do
8
8
 
9
- 49 tools as of v0.49.0, mirroring the `chess.ceo` API surface. A few of the most-used:
9
+ 50 tools as of v0.49.2, mirroring the `chess.ceo` API surface. A few of the most-used:
10
10
 
11
11
  | Tool | What it answers |
12
12
  |---|---|
package/dist/index.js CHANGED
@@ -29,7 +29,7 @@ import { getNodeByPath, resolveFromNodeOrFen, storeEvalOnNode, } from "./analysi
29
29
  import { findPositionInCourses, readCourseAtPosition, runSfEval } from "./courses.js";
30
30
  import { applyBatchMutations, applyMutation, argNodeId, } from "./prep/mutations.js";
31
31
  import { listNodes, listTranspositions, readPrepFile, } from "./prep/read.js";
32
- import { createCollection, createPrepFile, findPositionInFiles, listCollections, listPrepFiles, searchPrepFiles, } from "./prep/library.js";
32
+ import { createCollection, createPrepFile, findPositionInFiles, listCollections, listPrepFiles, renameCollection, searchPrepFiles, } from "./prep/library.js";
33
33
  import { convertAvailableMovesToSAN, normalizeSourceForBackend, stripPositionResponse, trimGamesMovetext, } from "./response_transforms.js";
34
34
  // Tools that require an MCP token — cloud engine + prep-file tools
35
35
  // operate on the caller's own account so we can't service them
@@ -43,6 +43,7 @@ const AUTHED_TOOLS = new Set([
43
43
  "cloud_analyse",
44
44
  "list_collections",
45
45
  "create_collection",
46
+ "rename_collection",
46
47
  "list_prep_files",
47
48
  "search_prep_files",
48
49
  "find_position_in_files",
@@ -440,6 +441,8 @@ async function callToolInner(name, args) {
440
441
  return listCollections(args);
441
442
  case "create_collection":
442
443
  return createCollection(args);
444
+ case "rename_collection":
445
+ return renameCollection(args);
443
446
  case "list_prep_files":
444
447
  return listPrepFiles(args);
445
448
  case "search_prep_files":
@@ -91,6 +91,17 @@ export async function createCollection(args) {
91
91
  folder_path: collection.folderPath,
92
92
  };
93
93
  }
94
+ export async function renameCollection(args) {
95
+ const id = typeof args.id === "string" ? args.id.trim() : "";
96
+ if (!id)
97
+ throw new Error("id is required");
98
+ const title = String(args.title || "").trim();
99
+ if (!title)
100
+ throw new Error("title is required");
101
+ const raw = await authedRequest("PUT", `${PGN_BASE}/${encodeURIComponent(id)}`, { title });
102
+ const collection = unwrap(raw);
103
+ return { ok: true, id: collection.id, title: collection.title };
104
+ }
94
105
  export async function createPrepFile(args) {
95
106
  const collectionId = typeof args.collection_id === "string" ? args.collection_id.trim() : "";
96
107
  if (!collectionId) {
package/dist/tools.js CHANGED
@@ -487,6 +487,18 @@ export const TOOLS = [
487
487
  required: ["title"],
488
488
  },
489
489
  },
490
+ {
491
+ name: "rename_collection",
492
+ description: "Rename a collection — changes only its title, not its contents or folder_path. Use when reorganizing: consolidating similarly-named collections, fixing a typo, or renaming a working title to something clearer once its scope is settled.",
493
+ inputSchema: {
494
+ type: "object",
495
+ properties: {
496
+ id: { type: "string", description: "Collection id, from list_collections." },
497
+ title: { type: "string", description: "New collection name." },
498
+ },
499
+ required: ["id", "title"],
500
+ },
501
+ },
490
502
  {
491
503
  name: "create_prep_file",
492
504
  description: "Create a new (empty) prep file in the specified collection. `name` becomes the Event PGN tag. You then extend it with mutation tools (add_move, set_comment, …).\n\n" +
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chessceo/mcp",
3
- "version": "0.49.1",
3
+ "version": "0.49.2",
4
4
  "description": "Model Context Protocol server for chess.ceo — 11.7M+ games, ~1.5M FIDE player profiles, opening preparation, live broadcasts.",
5
5
  "type": "module",
6
6
  "bin": {