@mandujs/mcp 0.18.8 → 0.18.10

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.
@@ -25,6 +25,10 @@ import fs from "fs/promises";
25
25
  export const resourceToolDefinitions: Tool[] = [
26
26
  {
27
27
  name: "mandu.resource.create",
28
+ annotations: {
29
+ destructiveHint: true,
30
+ readOnlyHint: false,
31
+ },
28
32
  description:
29
33
  "Create a new resource with schema definition. " +
30
34
  "Generates schema file in spec/resources/{name}/schema.ts and creates " +
@@ -93,6 +97,9 @@ export const resourceToolDefinitions: Tool[] = [
93
97
  },
94
98
  {
95
99
  name: "mandu.resource.list",
100
+ annotations: {
101
+ readOnlyHint: true,
102
+ },
96
103
  description:
97
104
  "List all resources in the project. " +
98
105
  "Scans spec/resources/ directory and returns resource names with field summaries.",
@@ -104,6 +111,9 @@ export const resourceToolDefinitions: Tool[] = [
104
111
  },
105
112
  {
106
113
  name: "mandu.resource.get",
114
+ annotations: {
115
+ readOnlyHint: true,
116
+ },
107
117
  description:
108
118
  "Get detailed information about a specific resource. " +
109
119
  "Returns full schema definition including fields, types, and options.",
@@ -120,6 +130,9 @@ export const resourceToolDefinitions: Tool[] = [
120
130
  },
121
131
  {
122
132
  name: "mandu.resource.addField",
133
+ annotations: {
134
+ readOnlyHint: false,
135
+ },
123
136
  description:
124
137
  "Add a new field to an existing resource schema. " +
125
138
  "⚠️ IMPORTANT: Preserves custom slot logic by using force: false during regeneration. " +
@@ -168,6 +181,10 @@ export const resourceToolDefinitions: Tool[] = [
168
181
  },
169
182
  {
170
183
  name: "mandu.resource.removeField",
184
+ annotations: {
185
+ destructiveHint: true,
186
+ readOnlyHint: false,
187
+ },
171
188
  description:
172
189
  "Remove a field from an existing resource schema. " +
173
190
  "Updates schema file and regenerates artifacts with force: false to preserve slots.",
@@ -563,7 +580,7 @@ export function resourceTools(projectRoot: string) {
563
580
  message: `Field '${fieldName}' added to resource '${resourceName}'. ${force ? "⚠️ Slots overwritten!" : "Slots preserved."}`,
564
581
  tip: force
565
582
  ? "⚠️ Custom slot logic was overwritten because force: true was used"
566
- : "Custom slot logic preserved. Run mandu_generate to apply changes to all resources.",
583
+ : "Custom slot logic preserved. Run mandu.generate to apply changes to all resources.",
567
584
  };
568
585
  } catch (error) {
569
586
  return {
@@ -641,7 +658,7 @@ export function resourceTools(projectRoot: string) {
641
658
  slotsPreserved: result.skipped,
642
659
  remainingFields: Object.keys(definition.fields),
643
660
  message: `Field '${fieldName}' removed from resource '${resourceName}'. Slots preserved.`,
644
- tip: "Run mandu_generate to apply changes to all resources",
661
+ tip: "Run mandu.generate to apply changes to all resources",
645
662
  };
646
663
  } catch (error) {
647
664
  return {