@utaba/ucm-mcp-server 6.5.0 → 6.6.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 (198) hide show
  1. package/dist/clients/UcmLocalApiClient.d.ts +175 -2
  2. package/dist/clients/UcmLocalApiClient.js +203 -3
  3. package/dist/index.js +1 -1
  4. package/dist/mcp-server/clients/UcmLocalApiClient.d.ts +399 -0
  5. package/dist/mcp-server/clients/UcmLocalApiClient.js +719 -0
  6. package/dist/mcp-server/index.d.ts +3 -0
  7. package/dist/mcp-server/index.js +68 -0
  8. package/dist/mcp-server/interfaces/ILogger.d.ts +8 -0
  9. package/dist/mcp-server/interfaces/ILogger.js +4 -0
  10. package/dist/mcp-server/interfaces/IMcpTool.d.ts +7 -0
  11. package/dist/mcp-server/interfaces/IMcpTool.js +3 -0
  12. package/dist/mcp-server/logging/ConsoleLogger.d.ts +16 -0
  13. package/dist/mcp-server/logging/ConsoleLogger.js +45 -0
  14. package/dist/mcp-server/logging/LoggerFactory.d.ts +9 -0
  15. package/dist/mcp-server/logging/LoggerFactory.js +12 -0
  16. package/dist/mcp-server/server/McpConfig.d.ts +26 -0
  17. package/dist/mcp-server/server/McpConfig.js +90 -0
  18. package/dist/mcp-server/server/McpHandler.d.ts +12 -0
  19. package/dist/mcp-server/server/McpHandler.js +84 -0
  20. package/dist/mcp-server/server/McpServer.d.ts +15 -0
  21. package/dist/mcp-server/server/McpServer.js +49 -0
  22. package/dist/mcp-server/server/ToolRegistry.d.ts +23 -0
  23. package/dist/mcp-server/server/ToolRegistry.js +169 -0
  24. package/dist/mcp-server/tools/authorization/ListAuthorizationsTool.d.ts +21 -0
  25. package/dist/mcp-server/tools/authorization/ListAuthorizationsTool.js +146 -0
  26. package/dist/mcp-server/tools/authorization/SignOutTool.d.ts +23 -0
  27. package/dist/mcp-server/tools/authorization/SignOutTool.js +128 -0
  28. package/dist/mcp-server/tools/base/BaseToolController.d.ts +19 -0
  29. package/dist/mcp-server/tools/base/BaseToolController.js +58 -0
  30. package/dist/mcp-server/tools/connections/AccessConnectionTool.d.ts +21 -0
  31. package/dist/mcp-server/tools/connections/AccessConnectionTool.js +107 -0
  32. package/dist/mcp-server/tools/connections/CallRemoteToolTool.d.ts +22 -0
  33. package/dist/mcp-server/tools/connections/CallRemoteToolTool.js +124 -0
  34. package/dist/mcp-server/tools/core/DeleteArtifactTool.d.ts +11 -0
  35. package/dist/mcp-server/tools/core/DeleteArtifactTool.js +83 -0
  36. package/dist/mcp-server/tools/core/EditArtifactMetadataTool.d.ts +12 -0
  37. package/dist/mcp-server/tools/core/EditArtifactMetadataTool.js +173 -0
  38. package/dist/mcp-server/tools/core/GetArtifactTool.d.ts +13 -0
  39. package/dist/mcp-server/tools/core/GetArtifactTool.js +124 -0
  40. package/dist/mcp-server/tools/core/GetArtifactVersionsTool.d.ts +11 -0
  41. package/dist/mcp-server/tools/core/GetArtifactVersionsTool.js +63 -0
  42. package/dist/mcp-server/tools/core/GetChunkTool.d.ts +11 -0
  43. package/dist/mcp-server/tools/core/GetChunkTool.js +56 -0
  44. package/dist/mcp-server/tools/core/ListArtifactsTool.d.ts +11 -0
  45. package/dist/mcp-server/tools/core/ListArtifactsTool.js +84 -0
  46. package/dist/mcp-server/tools/core/MoveArtifactTool.d.ts +12 -0
  47. package/dist/mcp-server/tools/core/MoveArtifactTool.js +104 -0
  48. package/dist/mcp-server/tools/core/PublishArtifactFromFileTool.d.ts +15 -0
  49. package/dist/mcp-server/tools/core/PublishArtifactFromFileTool.js +277 -0
  50. package/dist/mcp-server/tools/core/PublishArtifactTool.d.ts +13 -0
  51. package/dist/mcp-server/tools/core/PublishArtifactTool.js +218 -0
  52. package/dist/mcp-server/tools/core/SearchArtifactsTool.d.ts +11 -0
  53. package/dist/mcp-server/tools/core/SearchArtifactsTool.js +137 -0
  54. package/dist/mcp-server/tools/list/ListNamespaceController.d.ts +1 -0
  55. package/dist/mcp-server/tools/list/ListNamespaceController.js +8 -0
  56. package/dist/mcp-server/tools/memory-graph/GraphCreateEntitiesTool.d.ts +14 -0
  57. package/dist/mcp-server/tools/memory-graph/GraphCreateEntitiesTool.js +58 -0
  58. package/dist/mcp-server/tools/memory-graph/GraphCreateRelationshipsTool.d.ts +14 -0
  59. package/dist/mcp-server/tools/memory-graph/GraphCreateRelationshipsTool.js +57 -0
  60. package/dist/mcp-server/tools/memory-graph/GraphCreateTool.d.ts +14 -0
  61. package/dist/mcp-server/tools/memory-graph/GraphCreateTool.js +64 -0
  62. package/dist/mcp-server/tools/memory-graph/GraphDeleteEntitiesTool.d.ts +14 -0
  63. package/dist/mcp-server/tools/memory-graph/GraphDeleteEntitiesTool.js +45 -0
  64. package/dist/mcp-server/tools/memory-graph/GraphDeleteRelationshipsTool.d.ts +14 -0
  65. package/dist/mcp-server/tools/memory-graph/GraphDeleteRelationshipsTool.js +45 -0
  66. package/dist/mcp-server/tools/memory-graph/GraphExploreTool.d.ts +14 -0
  67. package/dist/mcp-server/tools/memory-graph/GraphExploreTool.js +73 -0
  68. package/dist/mcp-server/tools/memory-graph/GraphFindEntitiesTool.d.ts +14 -0
  69. package/dist/mcp-server/tools/memory-graph/GraphFindEntitiesTool.js +68 -0
  70. package/dist/mcp-server/tools/memory-graph/GraphFindPathsTool.d.ts +14 -0
  71. package/dist/mcp-server/tools/memory-graph/GraphFindPathsTool.js +62 -0
  72. package/dist/mcp-server/tools/memory-graph/GraphGetEntityTool.d.ts +14 -0
  73. package/dist/mcp-server/tools/memory-graph/GraphGetEntityTool.js +49 -0
  74. package/dist/mcp-server/tools/memory-graph/GraphGetRelationshipsTool.d.ts +14 -0
  75. package/dist/mcp-server/tools/memory-graph/GraphGetRelationshipsTool.js +62 -0
  76. package/dist/mcp-server/tools/memory-graph/GraphListTemplatesTool.d.ts +14 -0
  77. package/dist/mcp-server/tools/memory-graph/GraphListTemplatesTool.js +34 -0
  78. package/dist/mcp-server/tools/memory-graph/GraphListTool.d.ts +14 -0
  79. package/dist/mcp-server/tools/memory-graph/GraphListTool.js +45 -0
  80. package/dist/mcp-server/tools/memory-graph/GraphOpenTool.d.ts +15 -0
  81. package/dist/mcp-server/tools/memory-graph/GraphOpenTool.js +50 -0
  82. package/dist/mcp-server/tools/memory-graph/GraphProposeVocabularyTool.d.ts +14 -0
  83. package/dist/mcp-server/tools/memory-graph/GraphProposeVocabularyTool.js +108 -0
  84. package/dist/mcp-server/tools/memory-graph/GraphSearchTool.d.ts +14 -0
  85. package/dist/mcp-server/tools/memory-graph/GraphSearchTool.js +94 -0
  86. package/dist/mcp-server/tools/memory-graph/GraphTraverseTool.d.ts +14 -0
  87. package/dist/mcp-server/tools/memory-graph/GraphTraverseTool.js +114 -0
  88. package/dist/mcp-server/tools/memory-graph/GraphUpdateEntitiesTool.d.ts +14 -0
  89. package/dist/mcp-server/tools/memory-graph/GraphUpdateEntitiesTool.js +58 -0
  90. package/dist/mcp-server/tools/memory-graph/KnowledgeSetListTool.d.ts +14 -0
  91. package/dist/mcp-server/tools/memory-graph/KnowledgeSetListTool.js +25 -0
  92. package/dist/mcp-server/tools/memory-graph/KnowledgeSetOpenTool.d.ts +14 -0
  93. package/dist/mcp-server/tools/memory-graph/KnowledgeSetOpenTool.js +31 -0
  94. package/dist/mcp-server/tools/repository/CreateRepositoryTool.d.ts +12 -0
  95. package/dist/mcp-server/tools/repository/CreateRepositoryTool.js +116 -0
  96. package/dist/mcp-server/tools/repository/GetRepositoryTool.d.ts +12 -0
  97. package/dist/mcp-server/tools/repository/GetRepositoryTool.js +85 -0
  98. package/dist/mcp-server/tools/repository/UpdateRepositoryTool.d.ts +12 -0
  99. package/dist/mcp-server/tools/repository/UpdateRepositoryTool.js +115 -0
  100. package/dist/mcp-server/tools/sharepoint/SharePointListConnectionsTool.d.ts +19 -0
  101. package/dist/mcp-server/tools/sharepoint/SharePointListConnectionsTool.js +90 -0
  102. package/dist/mcp-server/tools/sharepoint/SharePointListFoldersTool.d.ts +21 -0
  103. package/dist/mcp-server/tools/sharepoint/SharePointListFoldersTool.js +133 -0
  104. package/dist/mcp-server/tools/sharepoint/SharePointReadFileTool.d.ts +22 -0
  105. package/dist/mcp-server/tools/sharepoint/SharePointReadFileTool.js +146 -0
  106. package/dist/mcp-server/tools/sharepoint/SharePointReadRelatedFileTool.d.ts +18 -0
  107. package/dist/mcp-server/tools/sharepoint/SharePointReadRelatedFileTool.js +108 -0
  108. package/dist/mcp-server/tools/sharepoint/SharePointSearchTool.d.ts +22 -0
  109. package/dist/mcp-server/tools/sharepoint/SharePointSearchTool.js +125 -0
  110. package/dist/mcp-server/tools/utility/AuthorIndexTool.d.ts +11 -0
  111. package/dist/mcp-server/tools/utility/AuthorIndexTool.js +49 -0
  112. package/dist/mcp-server/tools/utility/AuthorRecentsTool.d.ts +11 -0
  113. package/dist/mcp-server/tools/utility/AuthorRecentsTool.js +49 -0
  114. package/dist/mcp-server/tools/utility/ListRepositoriesTool.d.ts +11 -0
  115. package/dist/mcp-server/tools/utility/ListRepositoriesTool.js +68 -0
  116. package/dist/mcp-server/tools/utility/QuickstartTool.d.ts +11 -0
  117. package/dist/mcp-server/tools/utility/QuickstartTool.js +36 -0
  118. package/dist/mcp-server/types/UcmApiTypes.d.ts +40 -0
  119. package/dist/mcp-server/types/UcmApiTypes.js +4 -0
  120. package/dist/mcp-server/utils/McpErrorHandler.d.ts +25 -0
  121. package/dist/mcp-server/utils/McpErrorHandler.js +67 -0
  122. package/dist/mcp-server/utils/PathUtils.d.ts +61 -0
  123. package/dist/mcp-server/utils/PathUtils.js +178 -0
  124. package/dist/mcp-server/utils/ResponseChunker.d.ts +25 -0
  125. package/dist/mcp-server/utils/ResponseChunker.js +79 -0
  126. package/dist/mcp-server/utils/SharePointErrorHandler.d.ts +34 -0
  127. package/dist/mcp-server/utils/SharePointErrorHandler.js +55 -0
  128. package/dist/schemas/memory-graph-tool-schemas.d.ts +789 -0
  129. package/dist/schemas/memory-graph-tool-schemas.js +181 -0
  130. package/dist/server/ToolRegistry.js +42 -8
  131. package/dist/tools/authorization/ListAuthorizationsTool.js +2 -2
  132. package/dist/tools/authorization/SignOutTool.js +2 -2
  133. package/dist/tools/connections/AccessConnectionTool.js +8 -6
  134. package/dist/tools/connections/CallRemoteToolTool.js +4 -4
  135. package/dist/tools/core/DeleteArtifactTool.js +5 -4
  136. package/dist/tools/core/EditArtifactMetadataTool.js +1 -1
  137. package/dist/tools/core/GetArtifactTool.js +1 -1
  138. package/dist/tools/core/GetArtifactVersionsTool.js +1 -1
  139. package/dist/tools/core/GetChunkTool.js +1 -1
  140. package/dist/tools/core/ListArtifactsTool.js +1 -1
  141. package/dist/tools/core/MoveArtifactTool.js +1 -1
  142. package/dist/tools/core/PublishArtifactFromFileTool.js +1 -1
  143. package/dist/tools/core/PublishArtifactTool.js +2 -2
  144. package/dist/tools/core/SearchArtifactsTool.js +7 -6
  145. package/dist/tools/memory-graph/GraphCreateEntitiesTool.d.ts +11 -0
  146. package/dist/tools/memory-graph/GraphCreateEntitiesTool.js +56 -0
  147. package/dist/tools/memory-graph/GraphCreateRelationshipsTool.d.ts +11 -0
  148. package/dist/tools/memory-graph/GraphCreateRelationshipsTool.js +55 -0
  149. package/dist/tools/memory-graph/GraphCreateTool.d.ts +11 -0
  150. package/dist/tools/memory-graph/GraphCreateTool.js +62 -0
  151. package/dist/tools/memory-graph/GraphDeleteEntitiesTool.d.ts +11 -0
  152. package/dist/tools/memory-graph/GraphDeleteEntitiesTool.js +43 -0
  153. package/dist/tools/memory-graph/GraphDeleteRelationshipsTool.d.ts +11 -0
  154. package/dist/tools/memory-graph/GraphDeleteRelationshipsTool.js +43 -0
  155. package/dist/tools/memory-graph/GraphExploreTool.d.ts +11 -0
  156. package/dist/tools/memory-graph/GraphExploreTool.js +71 -0
  157. package/dist/tools/memory-graph/GraphFindEntitiesTool.d.ts +11 -0
  158. package/dist/tools/memory-graph/GraphFindEntitiesTool.js +66 -0
  159. package/dist/tools/memory-graph/GraphFindPathsTool.d.ts +11 -0
  160. package/dist/tools/memory-graph/GraphFindPathsTool.js +60 -0
  161. package/dist/tools/memory-graph/GraphGetEntityTool.d.ts +11 -0
  162. package/dist/tools/memory-graph/GraphGetEntityTool.js +47 -0
  163. package/dist/tools/memory-graph/GraphGetRelationshipsTool.d.ts +11 -0
  164. package/dist/tools/memory-graph/GraphGetRelationshipsTool.js +60 -0
  165. package/dist/tools/memory-graph/GraphGetStatsTool.d.ts +11 -0
  166. package/dist/tools/memory-graph/GraphGetStatsTool.js +42 -0
  167. package/dist/tools/memory-graph/GraphListTemplatesTool.d.ts +11 -0
  168. package/dist/tools/memory-graph/GraphListTemplatesTool.js +32 -0
  169. package/dist/tools/memory-graph/GraphListTool.d.ts +11 -0
  170. package/dist/tools/memory-graph/GraphListTool.js +43 -0
  171. package/dist/tools/memory-graph/GraphOpenTool.d.ts +12 -0
  172. package/dist/tools/memory-graph/GraphOpenTool.js +48 -0
  173. package/dist/tools/memory-graph/GraphProposeVocabularyTool.d.ts +11 -0
  174. package/dist/tools/memory-graph/GraphProposeVocabularyTool.js +104 -0
  175. package/dist/tools/memory-graph/GraphRemoveRelationshipsTool.d.ts +11 -0
  176. package/dist/tools/memory-graph/GraphRemoveRelationshipsTool.js +47 -0
  177. package/dist/tools/memory-graph/GraphSearchTool.d.ts +11 -0
  178. package/dist/tools/memory-graph/GraphSearchTool.js +92 -0
  179. package/dist/tools/memory-graph/GraphTraverseTool.d.ts +11 -0
  180. package/dist/tools/memory-graph/GraphTraverseTool.js +112 -0
  181. package/dist/tools/memory-graph/GraphUpdateEntitiesTool.d.ts +11 -0
  182. package/dist/tools/memory-graph/GraphUpdateEntitiesTool.js +56 -0
  183. package/dist/tools/memory-graph/KnowledgeSetListTool.d.ts +11 -0
  184. package/dist/tools/memory-graph/KnowledgeSetListTool.js +23 -0
  185. package/dist/tools/memory-graph/KnowledgeSetOpenTool.d.ts +11 -0
  186. package/dist/tools/memory-graph/KnowledgeSetOpenTool.js +29 -0
  187. package/dist/tools/repository/CreateRepositoryTool.js +10 -9
  188. package/dist/tools/repository/GetRepositoryTool.js +15 -15
  189. package/dist/tools/repository/UpdateRepositoryTool.js +10 -9
  190. package/dist/tools/sharepoint/SharePointListConnectionsTool.js +1 -1
  191. package/dist/tools/sharepoint/SharePointListFoldersTool.js +1 -1
  192. package/dist/tools/utility/AuthorIndexTool.js +6 -5
  193. package/dist/tools/utility/AuthorRecentsTool.js +6 -5
  194. package/dist/tools/utility/HealthCheckController.js +1 -1
  195. package/dist/tools/utility/ListRepositoriesTool.js +5 -4
  196. package/dist/utils/McpErrorHandler.js +1 -1
  197. package/package.json +1 -1
  198. package/package.json.backup +1 -1
@@ -0,0 +1,181 @@
1
+ /**
2
+ * Shared Zod schemas for all Memory Graph and Knowledge Set MCP tools.
3
+ *
4
+ * Used by three MCP servers (Local, Remote, Agent) for runtime validation.
5
+ * Each schema defines the tool input shape (what the AI sends).
6
+ */
7
+ import { z } from 'zod';
8
+ // ─── Common Fragments ───────────────────────────────────────────────
9
+ const memoryGraphId = z.string().describe('The Memory Graph ID');
10
+ const entityId = z.string().describe('The entity ID');
11
+ const detailLevel = z.enum(['brief', 'summary', 'full']);
12
+ const direction = z.enum(['outbound', 'inbound', 'both']);
13
+ const traversalDirection = z.enum(['out', 'in', 'both']);
14
+ const returnMode = z.enum(['terminal', 'all', 'paths']);
15
+ const graphScope = z.enum(['organization', 'personal', 'all']);
16
+ const createScope = z.enum(['personal', 'organization']);
17
+ const entityInput = z.object({
18
+ entityType: z.string().describe('Entity type (must exist in vocabulary)'),
19
+ label: z.string().describe('Human-readable label'),
20
+ summary: z.string().optional().describe('Brief summary/description'),
21
+ properties: z.record(z.unknown()).optional().describe('Entity properties (validated against vocabulary schema)'),
22
+ data: z.union([z.string(), z.record(z.unknown())]).optional().describe('Optional freeform data'),
23
+ });
24
+ const entityUpdateInput = z.object({
25
+ entityId: z.string().describe('The entity ID to update'),
26
+ label: z.string().optional().describe('New label'),
27
+ summary: z.string().optional().describe('New summary'),
28
+ properties: z.record(z.unknown()).optional().describe('Properties to update (merged with existing)'),
29
+ data: z.record(z.unknown()).optional().describe('Data to update (merged with existing)'),
30
+ });
31
+ const relationshipInput = z.object({
32
+ relationshipType: z.string().describe('Relationship type (must exist in vocabulary)'),
33
+ sourceEntityId: z.string().describe('Source entity ID'),
34
+ targetEntityId: z.string().describe('Target entity ID'),
35
+ properties: z.record(z.unknown()).optional().describe('Optional relationship properties'),
36
+ });
37
+ const propertyFilter = z.object({
38
+ key: z.string(),
39
+ operator: z.string().describe('eq, neq, gt, gte, lt, lte, contains, isNull, isNotNull'),
40
+ value: z.unknown().optional(),
41
+ });
42
+ const traversalStart = z.object({
43
+ entityId: z.string().optional().describe('Start from specific entity'),
44
+ entityType: z.string().optional().describe('Start from all entities of this type'),
45
+ filter: z.array(propertyFilter).optional().describe('Property filters on start entities'),
46
+ }).passthrough();
47
+ const traversalStep = z.object({
48
+ direction: traversalDirection.optional().describe('Hop direction'),
49
+ relationshipTypes: z.array(z.string()).optional().describe('Filter by relationship types'),
50
+ entityTypes: z.array(z.string()).optional().describe('Filter by entity types at this step'),
51
+ filter: z.array(propertyFilter).optional().describe('Property filters on entities at this step'),
52
+ repeat: z.object({
53
+ min: z.number().optional(),
54
+ max: z.number().optional(),
55
+ }).optional().describe('Repeat this step min to max times'),
56
+ }).passthrough();
57
+ const entityTypeProposal = z.object({
58
+ type: z.string().describe('Entity type name (PascalCase, singular)'),
59
+ description: z.string().describe('What this entity type represents'),
60
+ justification: z.string().describe('Why this entity type is needed'),
61
+ properties: z.array(z.object({
62
+ name: z.string().describe('Property name (camelCase)'),
63
+ type: z.enum(['string', 'number', 'boolean', 'date']).describe('Property data type'),
64
+ required: z.boolean().optional().describe('Whether the property is required'),
65
+ description: z.string().describe('What this property captures'),
66
+ embeddable: z.boolean().optional().describe('Include in embedding text for semantic search'),
67
+ })).optional().describe('Property definitions'),
68
+ }).passthrough();
69
+ const relationshipTypeProposal = z.object({
70
+ type: z.string().describe('Relationship type name (UPPER_SNAKE_CASE)'),
71
+ description: z.string().describe('What this relationship means'),
72
+ justification: z.string().describe('Why this relationship type is needed'),
73
+ allowedSourceTypes: z.array(z.string()).describe('Entity types that can be the source'),
74
+ allowedTargetTypes: z.array(z.string()).describe('Entity types that can be the target'),
75
+ bidirectional: z.boolean().optional().describe('Whether the relationship is bidirectional'),
76
+ properties: z.array(z.object({
77
+ name: z.string(),
78
+ type: z.enum(['string', 'number', 'boolean', 'date']),
79
+ required: z.boolean().optional(),
80
+ description: z.string(),
81
+ })).optional().describe('Relationship property definitions'),
82
+ }).passthrough();
83
+ // ─── Discovery Tool Schemas ─────────────────────────────────────────
84
+ export const GraphListSchema = z.object({
85
+ scope: graphScope.optional().describe('Filter by ownership scope (default: all)'),
86
+ });
87
+ export const GraphListTemplatesSchema = z.object({});
88
+ export const KnowledgeSetListSchema = z.object({});
89
+ export const KnowledgeSetOpenSchema = z.object({
90
+ knowledgeSetId: z.string().describe('The Knowledge Set ID to open'),
91
+ });
92
+ // ─── Graph Lifecycle Schemas ────────────────────────────────────────
93
+ export const GraphCreateSchema = z.object({
94
+ label: z.string().describe('Display name for the new Memory Graph'),
95
+ templateId: z.string().describe('Vocabulary template ID — call ucm_graph_list_templates first'),
96
+ description: z.string().optional().describe('What this graph is for'),
97
+ scope: createScope.optional().describe('personal (default) or organization (requires Owner role)'),
98
+ });
99
+ export const GraphOpenSchema = z.object({
100
+ memoryGraphId,
101
+ });
102
+ // ─── Read Tool Schemas ──────────────────────────────────────────────
103
+ export const GraphFindEntitiesSchema = z.object({
104
+ memoryGraphId,
105
+ searchTerm: z.string().optional().describe('Search term to match against entity labels'),
106
+ entityTypes: z.array(z.string()).optional().describe('Filter by entity types'),
107
+ detailLevel: detailLevel.optional().describe('Detail level (default: summary)'),
108
+ limit: z.number().optional().describe('Maximum results (default: 20, max: 100)'),
109
+ offset: z.number().optional().describe('Pagination offset (default: 0)'),
110
+ });
111
+ export const GraphGetEntitySchema = z.object({
112
+ memoryGraphId,
113
+ entityId,
114
+ detailLevel: detailLevel.optional().describe('Detail level (default: full)'),
115
+ });
116
+ export const GraphGetRelationshipsSchema = z.object({
117
+ memoryGraphId,
118
+ entityId,
119
+ relationshipTypes: z.array(z.string()).optional().describe('Filter by relationship types'),
120
+ direction: direction.optional().describe('Direction (default: both)'),
121
+ limit: z.number().optional().describe('Maximum results (default: 50)'),
122
+ });
123
+ export const GraphExploreSchema = z.object({
124
+ memoryGraphId,
125
+ entityId: z.string().describe('Starting entity ID'),
126
+ depth: z.number().optional().describe('Exploration depth: 1, 2, or 3 (default: 1)'),
127
+ relationshipTypes: z.array(z.string()).optional().describe('Filter by relationship types'),
128
+ entityTypes: z.array(z.string()).optional().describe('Filter by entity types'),
129
+ direction: direction.optional().describe('Direction (default: both)'),
130
+ limitPerType: z.number().optional().describe('Max results per type (default: 10)'),
131
+ });
132
+ export const GraphFindPathsSchema = z.object({
133
+ memoryGraphId,
134
+ sourceEntityId: z.string().describe('Starting entity ID'),
135
+ targetEntityId: z.string().describe('Target entity ID'),
136
+ maxDepth: z.number().optional().describe('Maximum path depth (default: 3, max: 5)'),
137
+ relationshipTypes: z.array(z.string()).optional().describe('Filter by relationship types'),
138
+ });
139
+ export const GraphTraverseSchema = z.object({
140
+ memoryGraphId,
141
+ start: traversalStart.describe('Start point specification'),
142
+ steps: z.array(traversalStep).describe('Ordered traversal steps (hops)'),
143
+ returnMode: returnMode.optional().describe('Return mode (default: terminal)'),
144
+ limit: z.number().optional().describe('Max results (default: 50)'),
145
+ detailLevel: detailLevel.optional().describe('Detail level (default: summary)'),
146
+ });
147
+ export const GraphSearchSchema = z.object({
148
+ memoryGraphId: z.string().optional().describe('Search a single graph (backwards compatible)'),
149
+ graphIds: z.array(z.string()).optional().describe('Search multiple graphs. Omit to search all accessible.'),
150
+ query: z.string().describe('Natural language search query'),
151
+ entityTypes: z.array(z.string()).optional().describe('Filter by entity types'),
152
+ limit: z.number().optional().describe('Per-graph result limit'),
153
+ similarityThreshold: z.number().optional().describe('Minimum similarity score (0-1)'),
154
+ });
155
+ // ─── Write Tool Schemas ─────────────────────────────────────────────
156
+ export const GraphCreateEntitiesSchema = z.object({
157
+ memoryGraphId,
158
+ entities: z.array(entityInput).min(1).describe('Array of entities to create'),
159
+ });
160
+ export const GraphUpdateEntitiesSchema = z.object({
161
+ memoryGraphId,
162
+ updates: z.array(entityUpdateInput).min(1).describe('Array of entity updates'),
163
+ });
164
+ export const GraphDeleteEntitiesSchema = z.object({
165
+ memoryGraphId,
166
+ entityIds: z.array(z.string()).min(1).describe('Array of entity IDs to delete'),
167
+ });
168
+ export const GraphCreateRelationshipsSchema = z.object({
169
+ memoryGraphId,
170
+ relationships: z.array(relationshipInput).min(1).describe('Array of relationships to create'),
171
+ });
172
+ export const GraphDeleteRelationshipsSchema = z.object({
173
+ memoryGraphId,
174
+ relationshipIds: z.array(z.string()).min(1).describe('Array of relationship IDs to delete'),
175
+ });
176
+ export const GraphProposeVocabularySchema = z.object({
177
+ memoryGraphId,
178
+ entityTypes: z.array(entityTypeProposal).optional().describe('Entity type proposals'),
179
+ relationshipTypes: z.array(relationshipTypeProposal).optional().describe('Relationship type proposals'),
180
+ });
181
+ //# sourceMappingURL=memory-graph-tool-schemas.js.map
@@ -1,11 +1,9 @@
1
1
  import { McpError, McpErrorCode } from '../utils/McpErrorHandler.js';
2
2
  // Import utility tools
3
- // import { HealthCheckController } from '../tools/utility/HealthCheckController.js'; // commented out — use ucm_connect instead
4
3
  import { QuickstartTool } from '../tools/utility/QuickstartTool.js';
5
4
  import { AuthorIndexTool } from '../tools/utility/AuthorIndexTool.js';
6
5
  import { AuthorRecentsTool } from '../tools/utility/AuthorRecentsTool.js';
7
6
  import { ListRepositoriesTool } from '../tools/utility/ListRepositoriesTool.js';
8
- // import { SubmitFeedbackTool } from '../tools/utility/SubmitFeedbackTool.js'; // removed — tool disabled
9
7
  // Import core tools
10
8
  import { GetArtifactTool } from '../tools/core/GetArtifactTool.js';
11
9
  import { GetChunkTool } from '../tools/core/GetChunkTool.js';
@@ -21,10 +19,9 @@ import { MoveArtifactTool } from '../tools/core/MoveArtifactTool.js';
21
19
  import { CreateRepositoryTool } from '../tools/repository/CreateRepositoryTool.js';
22
20
  import { GetRepositoryTool } from '../tools/repository/GetRepositoryTool.js';
23
21
  import { UpdateRepositoryTool } from '../tools/repository/UpdateRepositoryTool.js';
24
- import { DeleteRepositoryGuidanceTool } from '../tools/repository/DeleteRepositoryGuidanceTool.js';
25
22
  // Import connection/SharePoint tools
26
23
  import { ListConnectionsTool } from '../tools/sharepoint/SharePointListConnectionsTool.js';
27
- // DEPRECATED: Legacy SharePoint tools - use ucm_call_remote_tool via unified gateway instead
24
+ // DEPRECATED: Legacy SharePoint tools - use ucm_connection_call_tool via unified gateway instead
28
25
  // Commented out 2026-02-13 - pending confirmation that unified gateway works correctly
29
26
  // import { SharePointSearchTool } from '../tools/sharepoint/SharePointSearchTool.js';
30
27
  // import { SharePointListFoldersTool } from '../tools/sharepoint/SharePointListFoldersTool.js';
@@ -36,6 +33,26 @@ import { ListAuthorizationsTool } from '../tools/authorization/ListAuthorization
36
33
  // Import connection tools
37
34
  import { AccessConnectionTool } from '../tools/connections/AccessConnectionTool.js';
38
35
  import { CallRemoteToolTool } from '../tools/connections/CallRemoteToolTool.js';
36
+ // Import memory graph tools
37
+ import { GraphListTool } from '../tools/memory-graph/GraphListTool.js';
38
+ import { GraphCreateTool } from '../tools/memory-graph/GraphCreateTool.js';
39
+ import { GraphListTemplatesTool } from '../tools/memory-graph/GraphListTemplatesTool.js';
40
+ import { KnowledgeSetListTool } from '../tools/memory-graph/KnowledgeSetListTool.js';
41
+ import { KnowledgeSetOpenTool } from '../tools/memory-graph/KnowledgeSetOpenTool.js';
42
+ import { GraphOpenTool } from '../tools/memory-graph/GraphOpenTool.js';
43
+ import { GraphFindEntitiesTool } from '../tools/memory-graph/GraphFindEntitiesTool.js';
44
+ import { GraphGetEntityTool } from '../tools/memory-graph/GraphGetEntityTool.js';
45
+ import { GraphGetRelationshipsTool } from '../tools/memory-graph/GraphGetRelationshipsTool.js';
46
+ import { GraphExploreTool } from '../tools/memory-graph/GraphExploreTool.js';
47
+ import { GraphFindPathsTool } from '../tools/memory-graph/GraphFindPathsTool.js';
48
+ import { GraphTraverseTool } from '../tools/memory-graph/GraphTraverseTool.js';
49
+ import { GraphSearchTool } from '../tools/memory-graph/GraphSearchTool.js';
50
+ import { GraphCreateEntitiesTool } from '../tools/memory-graph/GraphCreateEntitiesTool.js';
51
+ import { GraphUpdateEntitiesTool } from '../tools/memory-graph/GraphUpdateEntitiesTool.js';
52
+ import { GraphDeleteEntitiesTool } from '../tools/memory-graph/GraphDeleteEntitiesTool.js';
53
+ import { GraphCreateRelationshipsTool } from '../tools/memory-graph/GraphCreateRelationshipsTool.js';
54
+ import { GraphDeleteRelationshipsTool } from '../tools/memory-graph/GraphDeleteRelationshipsTool.js';
55
+ import { GraphProposeVocabularyTool } from '../tools/memory-graph/GraphProposeVocabularyTool.js';
39
56
  export class ToolRegistry {
40
57
  ucmClient;
41
58
  logger;
@@ -54,11 +71,9 @@ export class ToolRegistry {
54
71
  registerTools() {
55
72
  // Register utility tools
56
73
  this.registerTool(new QuickstartTool(this.ucmClient, this.logger, this.authorId));
57
- // this.registerTool(new HealthCheckController(this.ucmClient, this.logger, this.authorId)); // commented out — use ucm_connect instead
58
74
  this.registerTool(new AuthorIndexTool(this.ucmClient, this.logger, this.authorId));
59
75
  this.registerTool(new AuthorRecentsTool(this.ucmClient, this.logger, this.authorId));
60
76
  this.registerTool(new ListRepositoriesTool(this.ucmClient, this.logger, this.authorId));
61
- // this.registerTool(new SubmitFeedbackTool(this.ucmClient, this.logger, this.authorId)); // removed — tool disabled
62
77
  // Register core tools
63
78
  this.registerTool(new GetArtifactTool(this.ucmClient, this.logger, this.authorId, this.trustedAuthors));
64
79
  this.registerTool(new GetChunkTool(this.ucmClient, this.logger, this.authorId));
@@ -74,10 +89,9 @@ export class ToolRegistry {
74
89
  this.registerTool(new CreateRepositoryTool(this.ucmClient, this.logger, this.authorId));
75
90
  this.registerTool(new GetRepositoryTool(this.ucmClient, this.logger, this.authorId));
76
91
  this.registerTool(new UpdateRepositoryTool(this.ucmClient, this.logger, this.authorId));
77
- this.registerTool(new DeleteRepositoryGuidanceTool(this.ucmClient, this.logger, this.authorId, this.baseUrl));
78
92
  // Register connection tools (ListConnectionsTool is unified - lists all connection types)
79
93
  this.registerTool(new ListConnectionsTool(this.ucmClient, this.logger, this.authorId));
80
- // DEPRECATED: Legacy SharePoint tools - use ucm_call_remote_tool via unified gateway instead
94
+ // DEPRECATED: Legacy SharePoint tools - use ucm_connection_call_tool via unified gateway instead
81
95
  // Commented out 2026-02-13 - pending confirmation that unified gateway works correctly
82
96
  // this.registerTool(new SharePointSearchTool(this.ucmClient, this.logger, this.authorId));
83
97
  // this.registerTool(new SharePointListFoldersTool(this.ucmClient, this.logger, this.authorId));
@@ -89,6 +103,26 @@ export class ToolRegistry {
89
103
  // Register unified authorization tools
90
104
  this.registerTool(new SignOutTool(this.ucmClient, this.logger, this.authorId));
91
105
  this.registerTool(new ListAuthorizationsTool(this.ucmClient, this.logger, this.authorId));
106
+ // Register memory graph tools
107
+ this.registerTool(new GraphListTool(this.ucmClient, this.logger, this.authorId));
108
+ this.registerTool(new GraphCreateTool(this.ucmClient, this.logger, this.authorId));
109
+ this.registerTool(new GraphListTemplatesTool(this.ucmClient, this.logger, this.authorId));
110
+ this.registerTool(new KnowledgeSetListTool(this.ucmClient, this.logger, this.authorId));
111
+ this.registerTool(new KnowledgeSetOpenTool(this.ucmClient, this.logger, this.authorId));
112
+ this.registerTool(new GraphOpenTool(this.ucmClient, this.logger, this.authorId));
113
+ this.registerTool(new GraphFindEntitiesTool(this.ucmClient, this.logger, this.authorId));
114
+ this.registerTool(new GraphGetEntityTool(this.ucmClient, this.logger, this.authorId));
115
+ this.registerTool(new GraphGetRelationshipsTool(this.ucmClient, this.logger, this.authorId));
116
+ this.registerTool(new GraphExploreTool(this.ucmClient, this.logger, this.authorId));
117
+ this.registerTool(new GraphFindPathsTool(this.ucmClient, this.logger, this.authorId));
118
+ this.registerTool(new GraphTraverseTool(this.ucmClient, this.logger, this.authorId));
119
+ this.registerTool(new GraphSearchTool(this.ucmClient, this.logger, this.authorId));
120
+ this.registerTool(new GraphCreateEntitiesTool(this.ucmClient, this.logger, this.authorId));
121
+ this.registerTool(new GraphUpdateEntitiesTool(this.ucmClient, this.logger, this.authorId));
122
+ this.registerTool(new GraphDeleteEntitiesTool(this.ucmClient, this.logger, this.authorId));
123
+ this.registerTool(new GraphCreateRelationshipsTool(this.ucmClient, this.logger, this.authorId));
124
+ this.registerTool(new GraphDeleteRelationshipsTool(this.ucmClient, this.logger, this.authorId));
125
+ this.registerTool(new GraphProposeVocabularyTool(this.ucmClient, this.logger, this.authorId));
92
126
  this.logger.info('ToolRegistry', `Registered ${this.tools.size} MCP tools`);
93
127
  }
94
128
  registerTool(tool) {
@@ -8,7 +8,7 @@ export class ListAuthorizationsTool extends BaseToolController {
8
8
  super(ucmClient, logger, publishingAuthorId);
9
9
  }
10
10
  get name() {
11
- return 'ucm_list_authorizations';
11
+ return 'ucm_connection_list_auth';
12
12
  }
13
13
  get description() {
14
14
  return 'List all your active OAuth authorizations across connection types. Shows which services you are currently authorized to access, with expiry info and connection details.';
@@ -138,7 +138,7 @@ export class ListAuthorizationsTool extends BaseToolController {
138
138
  }
139
139
  }
140
140
  lines.push('\n## Actions\n');
141
- lines.push('To revoke an authorization, use: `ucm_signout` with connectionType and connectionId');
141
+ lines.push('To revoke an authorization, use: `ucm_connection_signout` with connectionType and connectionId');
142
142
  }
143
143
  return lines.join('\n');
144
144
  }
@@ -9,7 +9,7 @@ export class SignOutTool extends BaseToolController {
9
9
  super(ucmClient, logger, publishingAuthorId);
10
10
  }
11
11
  get name() {
12
- return 'ucm_signout';
12
+ return 'ucm_connection_signout';
13
13
  }
14
14
  get description() {
15
15
  return 'Sign out from an OAuth-authorized connection. Revokes user-delegated permissions by deleting access tokens. Works for SharePoint OnBehalfOf connections and Remote MCP Servers with user-delegated OAuth.';
@@ -25,7 +25,7 @@ export class SignOutTool extends BaseToolController {
25
25
  },
26
26
  connectionId: {
27
27
  type: 'string',
28
- description: 'Connection ID to revoke authorization for (get from ucm_list_authorizations or ucm_list_connections)',
28
+ description: 'Connection ID to revoke authorization for (get from ucm_connection_list_auth or ucm_connection_list)',
29
29
  minLength: 36,
30
30
  maxLength: 36
31
31
  }
@@ -11,10 +11,10 @@ export class AccessConnectionTool extends BaseToolController {
11
11
  super(ucmClient, logger, publishingAuthorId);
12
12
  }
13
13
  get name() {
14
- return 'ucm_access_connection';
14
+ return 'ucm_connection_access';
15
15
  }
16
16
  get description() {
17
- return 'Access a specific external connection, check auth status, and return available tool schemas. Call without toolNames to get a summary index of all available tools. Pass toolNames to retrieve full parameter schemas. If any tool name in toolNames is not recognised, the full catalogue is returned for all tools — use this to identify the correct name.';
17
+ return 'Access a specific external connection, check auth status, and return available tool schemas. Call without toolNames to get a summary index of all available tools. Pass toolNames to retrieve full parameter schemas.';
18
18
  }
19
19
  get inputSchema() {
20
20
  return {
@@ -22,7 +22,7 @@ export class AccessConnectionTool extends BaseToolController {
22
22
  properties: {
23
23
  connectionId: {
24
24
  type: 'string',
25
- description: 'Connection ID (SharePoint connection or Remote MCP Server) from ucm_list_connections',
25
+ description: 'Connection ID (SharePoint connection or Remote MCP Server) from ucm_connection_list',
26
26
  minLength: 36,
27
27
  maxLength: 36
28
28
  },
@@ -66,14 +66,16 @@ export class AccessConnectionTool extends BaseToolController {
66
66
  if (result.markdown) {
67
67
  return result.markdown;
68
68
  }
69
- // toolNames mode — return compact JSON with filtered tools
70
- return JSON.stringify({
69
+ // Tools mode — return compact JSON with schemas
70
+ const json = {
71
71
  connectionId: result.connectionId,
72
72
  connectionName: result.connectionName,
73
73
  instructions: result.instructions,
74
74
  policies: result.policies,
75
+ ...(result.error && { error: result.error }),
75
76
  tools: result.tools
76
- });
77
+ };
78
+ return JSON.stringify(json);
77
79
  }
78
80
  catch (error) {
79
81
  // Sanitize error for logging
@@ -11,10 +11,10 @@ export class CallRemoteToolTool extends BaseToolController {
11
11
  super(ucmClient, logger, publishingAuthorId);
12
12
  }
13
13
  get name() {
14
- return 'ucm_call_remote_tool';
14
+ return 'ucm_connection_call_tool';
15
15
  }
16
16
  get description() {
17
- return 'Call a tool on an external connection. If the tool name is invalid, the response will include the full tool catalogue so you can identify the correct tool and retry immediately. If the parameters are invalid, the response will include the correct schema — retry using that schema directly. No additional discovery calls are needed to recover from errors.';
17
+ return 'Call a tool on an external connection.';
18
18
  }
19
19
  get inputSchema() {
20
20
  return {
@@ -22,13 +22,13 @@ export class CallRemoteToolTool extends BaseToolController {
22
22
  properties: {
23
23
  connectionId: {
24
24
  type: 'string',
25
- description: 'Connection ID (SharePoint connection or Remote MCP Server) from ucm_list_connections',
25
+ description: 'Connection ID (SharePoint connection or Remote MCP Server) from ucm_connection_list',
26
26
  minLength: 36,
27
27
  maxLength: 36
28
28
  },
29
29
  toolName: {
30
30
  type: 'string',
31
- description: 'Name of the tool to call (see ucm_access_connection for available tools)',
31
+ description: 'Name of the tool to call (see ucm_connection_access for available tools)',
32
32
  minLength: 1
33
33
  },
34
34
  args: {
@@ -4,7 +4,7 @@ export class DeleteArtifactTool extends BaseToolController {
4
4
  super(ucmClient, logger, publishingAuthorId);
5
5
  }
6
6
  get name() {
7
- return 'ucm_delete_artifact';
7
+ return 'ucm_artifact_delete';
8
8
  }
9
9
  get description() {
10
10
  return 'Delete a UCM artifact by path and version. This action cannot be undone. Only the latest or specified version is deleted.';
@@ -13,7 +13,7 @@ export class DeleteArtifactTool extends BaseToolController {
13
13
  return {
14
14
  type: 'object',
15
15
  properties: {
16
- author: {
16
+ workspace: {
17
17
  type: 'string',
18
18
  description: `Author name (e.g., ${this.publishingAuthorId || '01234567890'})`,
19
19
  minLength: 1,
@@ -44,11 +44,12 @@ export class DeleteArtifactTool extends BaseToolController {
44
44
  maxLength: 150
45
45
  }
46
46
  },
47
- required: ['author', 'repository', 'category', 'subcategory', 'filename']
47
+ required: ['workspace', 'repository', 'category', 'subcategory', 'filename']
48
48
  };
49
49
  }
50
50
  async handleExecute(params) {
51
- const { author, repository, category, subcategory, filename } = params;
51
+ const { workspace, repository, category, subcategory, filename } = params;
52
+ const author = workspace;
52
53
  this.logger.debug('DeleteArtifactTool', `Deleting artifact: ${author}/${repository}/${category}/${subcategory}/${filename}`);
53
54
  try {
54
55
  // Parse filename to extract version if present
@@ -6,7 +6,7 @@ export class EditArtifactMetadataTool extends BaseToolController {
6
6
  super(ucmClient, logger, publishingAuthorId);
7
7
  }
8
8
  get name() {
9
- return 'ucm_edit_artifact_metadata';
9
+ return 'ucm_artifact_edit_metadata';
10
10
  }
11
11
  get description() {
12
12
  return 'Edit artifact metadata and move artifacts. Supports updating description, namespace, filename, MIME type, technology, and tags. Move operations affect all versions while metadata-only updates apply to latest version only.';
@@ -8,7 +8,7 @@ export class GetArtifactTool extends BaseToolController {
8
8
  this.trustedAuthors = trustedAuthors;
9
9
  }
10
10
  get name() {
11
- return 'ucm_get_artifact';
11
+ return 'ucm_artifact_get';
12
12
  }
13
13
  get description() {
14
14
  return 'Retrieve UCM artifact content with metadata. Large files are automatically chunked.';
@@ -5,7 +5,7 @@ export class GetArtifactVersionsTool extends BaseToolController {
5
5
  super(ucmClient, logger, publishingAuthorId);
6
6
  }
7
7
  get name() {
8
- return 'ucm_get_artifact_versions';
8
+ return 'ucm_artifact_get_versions';
9
9
  }
10
10
  get description() {
11
11
  return 'Get all available versions of a specific UCM artifact';
@@ -6,7 +6,7 @@ export class GetChunkTool extends BaseToolController {
6
6
  super(ucmClient, logger, publishingAuthorId);
7
7
  }
8
8
  get name() {
9
- return 'ucm_get_chunk';
9
+ return 'ucm_artifact_get_chunk';
10
10
  }
11
11
  get description() {
12
12
  return 'Retrieve the next chunk of a large UCM artifact response';
@@ -5,7 +5,7 @@ export class ListArtifactsTool extends BaseToolController {
5
5
  super(ucmClient, logger, publishingAuthorId);
6
6
  }
7
7
  get name() {
8
- return 'ucm_list_artifacts';
8
+ return 'ucm_artifact_list';
9
9
  }
10
10
  get description() {
11
11
  return `List artifacts with exploratory browsing support. Can list authors, repositories, categories, subcategories, or artifacts depending on path depth. ${this.publishingAuthorId ? "Your author value is '" + this.publishingAuthorId + "'" : ''}`;
@@ -6,7 +6,7 @@ export class MoveArtifactTool extends BaseToolController {
6
6
  super(ucmClient, logger, publishingAuthorId);
7
7
  }
8
8
  get name() {
9
- return 'ucm_move_artifact';
9
+ return 'ucm_artifact_move';
10
10
  }
11
11
  get description() {
12
12
  return 'Move an artifact from one namespace location to another. All versions are moved. Requires read access on source and write access on destination.';
@@ -8,7 +8,7 @@ export class PublishArtifactFromFileTool extends BaseToolController {
8
8
  super(ucmClient, logger, publishingAuthorId);
9
9
  }
10
10
  get name() {
11
- return 'ucm_publish_artifact_fromfile';
11
+ return 'ucm_artifact_publish_from_file';
12
12
  }
13
13
  get description() {
14
14
  return 'Create or update UCM artifacts from a file URI. Supports versioning. PREFERRED METHOD: Use this tool for file-based content as it is much faster and more efficient. Pass the local file path as a file:// URI (e.g., "file:///path/to/file.txt").';
@@ -6,10 +6,10 @@ export class PublishArtifactTool extends BaseToolController {
6
6
  super(ucmClient, logger, publishingAuthorId);
7
7
  }
8
8
  get name() {
9
- return 'ucm_publish_artifact';
9
+ return 'ucm_artifact_publish';
10
10
  }
11
11
  get description() {
12
- return 'Create or update UCM artifacts with content and metadata. Supports versioning and automatic conflict detection. The API automatically detects whether to create or update based on existing artifacts. NOTE: Only use this tool for small data - use ucm_publish_artifact_fromfile for files as it is much faster and more efficient.';
12
+ return 'Create or update UCM artifacts with content and metadata. Supports versioning and automatic conflict detection. The API automatically detects whether to create or update based on existing artifacts. NOTE: Only use this tool for small data - use ucm_artifact_publish_from_file for files as it is much faster and more efficient.';
13
13
  }
14
14
  get inputSchema() {
15
15
  return {
@@ -4,10 +4,10 @@ export class SearchArtifactsTool extends BaseToolController {
4
4
  super(ucmClient, logger, publishingAuthorId);
5
5
  }
6
6
  get name() {
7
- return 'ucm_search_artifacts';
7
+ return 'ucm_artifact_search';
8
8
  }
9
9
  get description() {
10
- return `Search artifacts by text across multiple metadata fields with privacy filtering. Searches namespace, filename, description, and tags fields. ${this.publishingAuthorId ? "Your author value is '" + this.publishingAuthorId + "'" : ''}`;
10
+ return `Search your workspaces by text across multiple metadata fields. Searches namespace, filename, description, and tags fields. ${this.publishingAuthorId ? "Your workspace value is '" + this.publishingAuthorId + "'" : ''}`;
11
11
  }
12
12
  get inputSchema() {
13
13
  return {
@@ -21,12 +21,12 @@ export class SearchArtifactsTool extends BaseToolController {
21
21
  },
22
22
  namespace: {
23
23
  type: 'string',
24
- description: 'Optional namespace filter (e.g., "utaba/main/commands/user")',
24
+ description: 'Optional namespace filter (e.g., "main/commands/user")',
25
25
  maxLength: 200
26
26
  },
27
- author: {
27
+ workspace: {
28
28
  type: 'string',
29
- description: `Optional. Leave empty to search your own author and public authors. '(e.g., "' + this.publishingAuthorId + '")' : ''}`,
29
+ description: `Optional workspace filter. Leave empty to search your workspaces. ${this.publishingAuthorId ? '(e.g., "' + this.publishingAuthorId + '")' : ''}`,
30
30
  maxLength: 50
31
31
  },
32
32
  repository: {
@@ -70,7 +70,8 @@ export class SearchArtifactsTool extends BaseToolController {
70
70
  };
71
71
  }
72
72
  async handleExecute(params) {
73
- const { searchText, namespace, author, repository, category, subcategory, filename, tags, offset, limit } = params;
73
+ const { searchText, namespace, workspace, repository, category, subcategory, filename, tags, offset, limit } = params;
74
+ const author = workspace;
74
75
  this.logger.debug('SearchArtifactsTool', `Searching with filters`, '', {
75
76
  searchText,
76
77
  namespace,
@@ -0,0 +1,11 @@
1
+ import { BaseToolController } from '../base/BaseToolController.js';
2
+ import { UcmLocalApiClient } from '../../clients/UcmLocalApiClient.js';
3
+ import { ILogger } from '../../interfaces/ILogger.js';
4
+ export declare class GraphCreateEntitiesTool extends BaseToolController {
5
+ constructor(ucmClient: UcmLocalApiClient, logger: ILogger, publishingAuthorId?: string);
6
+ get name(): string;
7
+ get description(): string;
8
+ get inputSchema(): any;
9
+ protected handleExecute(params: any): Promise<any>;
10
+ }
11
+ //# sourceMappingURL=GraphCreateEntitiesTool.d.ts.map
@@ -0,0 +1,56 @@
1
+ import { BaseToolController } from '../base/BaseToolController.js';
2
+ import { McpError, McpErrorCode } from '../../utils/McpErrorHandler.js';
3
+ export class GraphCreateEntitiesTool extends BaseToolController {
4
+ constructor(ucmClient, logger, publishingAuthorId) {
5
+ super(ucmClient, logger, publishingAuthorId);
6
+ }
7
+ get name() { return 'ucm_graph_create_entities'; }
8
+ get description() {
9
+ return 'Create one or more entities in a Memory Graph. Each entity requires a type (from vocabulary) and label. Properties are validated against the vocabulary schema. Pass a single item in the array for single operations.';
10
+ }
11
+ get inputSchema() {
12
+ return {
13
+ type: 'object',
14
+ properties: {
15
+ memoryGraphId: {
16
+ type: 'string',
17
+ description: 'The Memory Graph ID'
18
+ },
19
+ entities: {
20
+ type: 'array',
21
+ description: 'Array of entities to create',
22
+ items: {
23
+ type: 'object',
24
+ properties: {
25
+ entityType: { type: 'string', description: 'Entity type (must exist in vocabulary)' },
26
+ label: { type: 'string', description: 'Human-readable label for the entity' },
27
+ summary: { type: 'string', description: 'Brief summary/description' },
28
+ properties: { type: 'object', description: 'Entity properties (validated against vocabulary schema)' },
29
+ data: { type: ['string', 'object'], description: 'Optional freeform data attached to the entity' }
30
+ },
31
+ required: ['entityType', 'label']
32
+ }
33
+ }
34
+ },
35
+ required: ['memoryGraphId', 'entities']
36
+ };
37
+ }
38
+ async handleExecute(params) {
39
+ const { memoryGraphId, entities } = params;
40
+ this.logger.info('GraphCreateEntitiesTool', `Creating ${entities.length} entities in graph: ${memoryGraphId}`);
41
+ try {
42
+ const result = await this.ucmClient.graphCreateEntities(memoryGraphId, entities);
43
+ return JSON.stringify(result);
44
+ }
45
+ catch (error) {
46
+ if (error.response?.status === 400) {
47
+ throw new McpError(McpErrorCode.InvalidParams, error.response.data?.message || 'Validation error');
48
+ }
49
+ if (error.response?.status === 404) {
50
+ throw new McpError(McpErrorCode.InvalidParams, `Memory Graph not found`);
51
+ }
52
+ throw new McpError(McpErrorCode.InternalError, `Failed to create entities: ${error.message}`);
53
+ }
54
+ }
55
+ }
56
+ //# sourceMappingURL=GraphCreateEntitiesTool.js.map
@@ -0,0 +1,11 @@
1
+ import { BaseToolController } from '../base/BaseToolController.js';
2
+ import { UcmLocalApiClient } from '../../clients/UcmLocalApiClient.js';
3
+ import { ILogger } from '../../interfaces/ILogger.js';
4
+ export declare class GraphCreateRelationshipsTool extends BaseToolController {
5
+ constructor(ucmClient: UcmLocalApiClient, logger: ILogger, publishingAuthorId?: string);
6
+ get name(): string;
7
+ get description(): string;
8
+ get inputSchema(): any;
9
+ protected handleExecute(params: any): Promise<any>;
10
+ }
11
+ //# sourceMappingURL=GraphCreateRelationshipsTool.d.ts.map