@cplace/test-mcp-server 1.2.0 → 1.3.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.
- package/README.md +4 -18
- package/dist/api.d.ts +1 -0
- package/dist/api.d.ts.map +1 -1
- package/dist/api.js +50 -0
- package/dist/api.js.map +1 -1
- package/dist/conditional-registration.js +3 -3
- package/dist/conditional-registration.js.map +1 -1
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -1
- package/dist/profiles.js +2 -2
- package/dist/profiles.js.map +1 -1
- package/dist/searchConversion.js +1 -1
- package/dist/searchConversion.js.map +1 -1
- package/dist/searchSchema.d.ts.map +1 -1
- package/dist/searchSchema.js.map +1 -1
- package/dist/tool-metadata.js +3 -3
- package/dist/tool-metadata.js.map +1 -1
- package/dist/tools/board-widget.js +1 -1
- package/dist/tools/board-widget.js.map +1 -1
- package/dist/tools/common-schemas.d.ts +0 -227
- package/dist/tools/common-schemas.d.ts.map +1 -1
- package/dist/tools/common-schemas.js +0 -67
- package/dist/tools/common-schemas.js.map +1 -1
- package/dist/tools/layout-script.d.ts +166 -0
- package/dist/tools/layout-script.d.ts.map +1 -0
- package/dist/tools/layout-script.js +474 -0
- package/dist/tools/layout-script.js.map +1 -0
- package/dist/tools/type-layouts.d.ts +0 -11
- package/dist/tools/type-layouts.d.ts.map +1 -1
- package/dist/tools/type-layouts.js +0 -31
- package/dist/tools/type-layouts.js.map +1 -1
- package/dist/tools/type-management.d.ts +9 -3
- package/dist/tools/type-management.d.ts.map +1 -1
- package/dist/tools/type-management.js +12 -8
- package/dist/tools/type-management.js.map +1 -1
- package/dist/tools/widgets.d.ts +0 -161
- package/dist/tools/widgets.d.ts.map +1 -1
- package/dist/tools/widgets.js +0 -275
- package/dist/tools/widgets.js.map +1 -1
- package/dist/tools/workspace-admin.d.ts.map +1 -1
- package/dist/tools/workspace-admin.js +7 -11
- package/dist/tools/workspace-admin.js.map +1 -1
- package/dist/widget-specifications/cf.cplace.cboard.main.board/_implementation.md +1 -1
- package/dist/widget-specifications/cf.cplace.platform.attributesGroup/layout.md +1 -6
- package/dist/widget-specifications/cf.cplace.platform.connectedAttributesGroup/cf.cplace.platform.attributesGroup.layout.md +1 -6
- package/dist/widget-specifications/cf.cplace.visualizations.scriptingHighcharts/tableWidgetId.md +1 -1
- package/package.json +1 -1
- package/dist/tools/generic-layouts.d.ts +0 -400
- package/dist/tools/generic-layouts.d.ts.map +0 -1
- package/dist/tools/generic-layouts.js +0 -785
- package/dist/tools/generic-layouts.js.map +0 -1
|
@@ -0,0 +1,474 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { debugLogWithTag } from "../logger.js";
|
|
3
|
+
import { checkResponseSize } from "../utils.js";
|
|
4
|
+
export const LayoutContextSchema = z.union([
|
|
5
|
+
z.object({
|
|
6
|
+
type: z.literal("page"),
|
|
7
|
+
pageUID: z.string().describe("Page UID (e.g., 'page/abc123')")
|
|
8
|
+
}),
|
|
9
|
+
z.object({
|
|
10
|
+
type: z.literal("type"),
|
|
11
|
+
workspaceId: z.string().describe("Workspace ID (e.g., 'workspace123')"),
|
|
12
|
+
typeInternalName: z.string().describe("Type internal name (e.g., 'cf.example.myType')"),
|
|
13
|
+
alternativeLayoutName: z.string().optional().describe("Alternative layout name (optional)")
|
|
14
|
+
})
|
|
15
|
+
]).describe("Layout target - specify whether operating on page or type layout");
|
|
16
|
+
const TOOL_LAYOUT_SCRIPT = 'cplace_layout_script';
|
|
17
|
+
const TOOL_LAYOUT_GET_OVERVIEW = 'cplace_layout_get_overview';
|
|
18
|
+
const TOOL_LAYOUT_GET_WIDGET_DETAILS = 'cplace_layout_get_widget_details';
|
|
19
|
+
const TOOL_LAYOUT_GET_SCRIPT = 'cplace_layout_get_script';
|
|
20
|
+
export const LAYOUT_SCRIPT_TOOL_DEFINITIONS = {
|
|
21
|
+
[TOOL_LAYOUT_SCRIPT]: {
|
|
22
|
+
description: `Execute a JavaScript layout script to define a complete page or type layout atomically using layout.define().
|
|
23
|
+
|
|
24
|
+
WHEN TO USE:
|
|
25
|
+
- Use this tool when you know the full layout structure upfront
|
|
26
|
+
- Replaces the entire layout in a single atomic operation (no partial updates)
|
|
27
|
+
- More efficient than sequential add-row/add-widget calls for complete layouts
|
|
28
|
+
|
|
29
|
+
KEY BEHAVIORS:
|
|
30
|
+
- The script must call layout.define() exactly once
|
|
31
|
+
- The entire layout is atomically replaced — previous layout is fully overwritten
|
|
32
|
+
- Script timeout: 30 seconds
|
|
33
|
+
- Widget IDs: auto-generated if omitted; if provided without '_' prefix, '_' is prepended automatically
|
|
34
|
+
|
|
35
|
+
RESPONSE OUTCOMES:
|
|
36
|
+
- VALID_COMPLETE: Layout saved, all widgets fully configured
|
|
37
|
+
- VALID_INCOMPLETE: Layout saved, but some widgets have missing optional configuration (warnings returned)
|
|
38
|
+
- Validation errors: Layout NOT saved — structural or widget errors returned with details
|
|
39
|
+
- Generic errors: Entity not found, permission denied, script errors
|
|
40
|
+
|
|
41
|
+
VALIDATION FEEDBACK:
|
|
42
|
+
- Structural errors: invalid column proportions (must be 3-12 each, sum to 12 per row)
|
|
43
|
+
- Widget errors: unknown widget types, invalid configurations
|
|
44
|
+
- Warnings: widgets saved but missing optional configuration (e.g., search filter not set)
|
|
45
|
+
|
|
46
|
+
TIP: After a VALID_INCOMPLETE response, re-run layout.define() with corrected widget configuration to resolve warnings.`,
|
|
47
|
+
inputSchema: {
|
|
48
|
+
context: LayoutContextSchema,
|
|
49
|
+
script: z.string().describe(`JavaScript code that calls layout.define() exactly once to declare the complete layout structure.
|
|
50
|
+
|
|
51
|
+
LAYOUT SPECIFICATION FORMAT:
|
|
52
|
+
layout.define({
|
|
53
|
+
rows: [
|
|
54
|
+
{
|
|
55
|
+
columns: [
|
|
56
|
+
{
|
|
57
|
+
proportion: 6, // Column width: integer 3-12, all columns in a row must sum to 12
|
|
58
|
+
widgets: [
|
|
59
|
+
{
|
|
60
|
+
id: "myWidget", // Optional: explicit widget ID (auto-prefixed with '_' if missing prefix)
|
|
61
|
+
type: "cf.platform.wiki", // Required: widget type identifier
|
|
62
|
+
config: { // Optional: widget configuration key-value pairs
|
|
63
|
+
title: "My Wiki"
|
|
64
|
+
},
|
|
65
|
+
embeddedLayouts: { // Optional: nested layouts for container widgets
|
|
66
|
+
"widgetsLayout": { // key is the name of the layout attribute
|
|
67
|
+
rows: [ /* same recursive structure */ ]
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
]
|
|
72
|
+
}
|
|
73
|
+
]
|
|
74
|
+
}
|
|
75
|
+
]
|
|
76
|
+
});
|
|
77
|
+
|
|
78
|
+
COLUMN PROPORTION RULES:
|
|
79
|
+
- Each column proportion must be between 3 and 12
|
|
80
|
+
- All column proportions in a row must sum to exactly 12
|
|
81
|
+
- Common patterns: [12] (full width), [6,6] (two equal), [4,4,4] (three equal), [8,4] (main + sidebar), [3,9] (sidebar + main)
|
|
82
|
+
|
|
83
|
+
WIDGET FIELDS:
|
|
84
|
+
- id (optional): Explicit widget ID. Auto-prefixed with '_' if it doesn't start with '_'. Auto-generated if omitted.
|
|
85
|
+
- type (required): Widget type identifier (e.g., 'cf.platform.wiki', 'cf.platform.embeddedSearchAsTable', 'cf.platform.comments', 'cf.platform.files')
|
|
86
|
+
- config (optional): Key-value object of widget configuration. Keys are attribute names, values are strings, numbers, or booleans.
|
|
87
|
+
- embeddedLayouts (optional): Object mapping layout attribute names to nested layout specs. Used for container widgets (tab groups, attributes groups).
|
|
88
|
+
|
|
89
|
+
ADDITIONAL APIS:
|
|
90
|
+
Scripts have access to cplace low-code JavaScript APIs for dynamic layout generation:
|
|
91
|
+
- new Search() / Filters.* — Search for pages to build dynamic layouts
|
|
92
|
+
- cplace.utils() — Platform utilities
|
|
93
|
+
- Standard JavaScript (JSON, Array, etc.)
|
|
94
|
+
|
|
95
|
+
EXAMPLES:
|
|
96
|
+
|
|
97
|
+
Simple single-column layout:
|
|
98
|
+
layout.define({
|
|
99
|
+
rows: [
|
|
100
|
+
{ columns: [{ proportion: 12, widgets: [{ type: "cf.platform.wiki" }] }] }
|
|
101
|
+
]
|
|
102
|
+
});
|
|
103
|
+
|
|
104
|
+
Two-column layout with configured widgets:
|
|
105
|
+
layout.define({
|
|
106
|
+
rows: [
|
|
107
|
+
{
|
|
108
|
+
columns: [
|
|
109
|
+
{
|
|
110
|
+
proportion: 8,
|
|
111
|
+
widgets: [
|
|
112
|
+
{ type: "cf.platform.wiki" },
|
|
113
|
+
{ type: "cf.platform.embeddedSearchAsTable", config: { height: 600, search: '{"filters":[{"typeNames":["cf.project.Task"]}]}' } }
|
|
114
|
+
]
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
proportion: 4,
|
|
118
|
+
widgets: [
|
|
119
|
+
{ type: "cf.platform.comments" },
|
|
120
|
+
{ type: "cf.platform.files" }
|
|
121
|
+
]
|
|
122
|
+
}
|
|
123
|
+
]
|
|
124
|
+
}
|
|
125
|
+
]
|
|
126
|
+
});
|
|
127
|
+
|
|
128
|
+
Multi-row layout with explicit widget IDs:
|
|
129
|
+
layout.define({
|
|
130
|
+
rows: [
|
|
131
|
+
{ columns: [{ proportion: 12, widgets: [{ id: "header", type: "cf.platform.wiki", config: { title: "Project Overview" } }] }] },
|
|
132
|
+
{
|
|
133
|
+
columns: [
|
|
134
|
+
{ proportion: 6, widgets: [{ id: "tasks", type: "cf.platform.embeddedSearchAsTable", config: { height: 400, search: '{"filters":[{"typeNames":["cf.project.Task"]}]}' } }] },
|
|
135
|
+
{ proportion: 6, widgets: [{ id: "milestones", type: "cf.platform.embeddedSearchAsTable", config: { height: 400, search: '{"filters":[{"typeNames":["cf.project.Milestone"]}]}' } }] }
|
|
136
|
+
]
|
|
137
|
+
},
|
|
138
|
+
{ columns: [{ proportion: 12, widgets: [{ id: "comments", type: "cf.platform.comments" }] }] }
|
|
139
|
+
]
|
|
140
|
+
});
|
|
141
|
+
|
|
142
|
+
Widget with embedded layout (container widget):
|
|
143
|
+
layout.define({
|
|
144
|
+
rows: [
|
|
145
|
+
{
|
|
146
|
+
columns: [
|
|
147
|
+
{
|
|
148
|
+
proportion: 12,
|
|
149
|
+
widgets: [
|
|
150
|
+
{
|
|
151
|
+
type: "cf.platform.attributesGroup",
|
|
152
|
+
config: { title: "Details Section" },
|
|
153
|
+
embeddedLayouts: {
|
|
154
|
+
"widgetsLayout": {
|
|
155
|
+
rows: [
|
|
156
|
+
{
|
|
157
|
+
columns: [
|
|
158
|
+
{ proportion: 6, widgets: [{ type: "cf.platform.wiki" }] },
|
|
159
|
+
{ proportion: 6, widgets: [{ type: "cf.platform.files" }] }
|
|
160
|
+
]
|
|
161
|
+
}
|
|
162
|
+
]
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
]
|
|
167
|
+
}
|
|
168
|
+
]
|
|
169
|
+
}
|
|
170
|
+
]
|
|
171
|
+
});
|
|
172
|
+
|
|
173
|
+
Dynamic layout using search APIs:
|
|
174
|
+
var search = new Search();
|
|
175
|
+
search.add(Filters.type("cf.project.Dashboard"));
|
|
176
|
+
var count = search.getResultCount();
|
|
177
|
+
var widgets = [{ type: "cf.platform.wiki", config: { title: "Summary (" + count + " dashboards)" } }];
|
|
178
|
+
if (count > 0) {
|
|
179
|
+
widgets.push({ type: "cf.platform.embeddedSearchAsTable", config: { height: 400, search: '{"filters":[{"typeNames":["cf.project.Dashboard"]}]}' } });
|
|
180
|
+
}
|
|
181
|
+
layout.define({ rows: [{ columns: [{ proportion: 12, widgets: widgets }] }] });`)
|
|
182
|
+
},
|
|
183
|
+
annotations: { title: "Execute Layout Script" }
|
|
184
|
+
},
|
|
185
|
+
[TOOL_LAYOUT_GET_OVERVIEW]: {
|
|
186
|
+
description: "Get layout structure for page or type. Provides an overview of the layout grid including rows, columns, and widget summaries for both page and type layouts.",
|
|
187
|
+
inputSchema: {
|
|
188
|
+
context: LayoutContextSchema
|
|
189
|
+
},
|
|
190
|
+
annotations: { title: "Get Layout Overview" }
|
|
191
|
+
},
|
|
192
|
+
[TOOL_LAYOUT_GET_WIDGET_DETAILS]: {
|
|
193
|
+
description: "Get detailed widget configuration from page or type layout. Extracts specific widget information from the layout structure.",
|
|
194
|
+
inputSchema: {
|
|
195
|
+
context: LayoutContextSchema,
|
|
196
|
+
widgetId: z.string().describe("The unique widget identifier to get details for")
|
|
197
|
+
},
|
|
198
|
+
annotations: { title: "Get Widget Details from Layout" }
|
|
199
|
+
},
|
|
200
|
+
[TOOL_LAYOUT_GET_SCRIPT]: {
|
|
201
|
+
description: `Get the current layout as a layout.define() JavaScript script for a page or type layout.
|
|
202
|
+
|
|
203
|
+
WHEN TO USE:
|
|
204
|
+
- To read the current layout before modifying it (read-edit-write workflow)
|
|
205
|
+
- To inspect the full layout definition including widget configurations and embedded layouts
|
|
206
|
+
- To copy a layout from one page/type to another
|
|
207
|
+
|
|
208
|
+
RETURNS:
|
|
209
|
+
- The layout as a layout.define({...}) script string, ready to be modified and posted back via cplace_layout_script
|
|
210
|
+
- Widget config values are in the INPUT format accepted by cplace_layout_script (references as UID strings, rich strings as markup strings, localized strings as {locale: value} maps)
|
|
211
|
+
|
|
212
|
+
ROUND-TRIP WORKFLOW:
|
|
213
|
+
1. GET: Use this tool to retrieve the current layout script
|
|
214
|
+
2. EDIT: Modify the script as needed
|
|
215
|
+
3. POST: Use cplace_layout_script to apply the modified script`,
|
|
216
|
+
inputSchema: {
|
|
217
|
+
context: LayoutContextSchema
|
|
218
|
+
},
|
|
219
|
+
annotations: { title: "Get Layout Script" }
|
|
220
|
+
}
|
|
221
|
+
};
|
|
222
|
+
function determineApiEndpoint(context) {
|
|
223
|
+
return context.type === "page" ? "json/pageLayout" : "json/typeLayout";
|
|
224
|
+
}
|
|
225
|
+
function buildRequestParams(context) {
|
|
226
|
+
if (context.type === "page") {
|
|
227
|
+
return { pageUID: context.pageUID };
|
|
228
|
+
}
|
|
229
|
+
else {
|
|
230
|
+
return {
|
|
231
|
+
workspaceId: context.workspaceId,
|
|
232
|
+
typeInternalName: context.typeInternalName,
|
|
233
|
+
...(context.alternativeLayoutName && { alternativeLayoutName: context.alternativeLayoutName })
|
|
234
|
+
};
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
async function getLayoutOverview(client, context) {
|
|
238
|
+
const endpoint = determineApiEndpoint(context);
|
|
239
|
+
const requestParams = buildRequestParams(context);
|
|
240
|
+
debugLogWithTag('LAYOUT', `getOverview operation on ${context.type} layout via ${endpoint}`);
|
|
241
|
+
return await client.makeApiRequest(endpoint, 'GET', requestParams);
|
|
242
|
+
}
|
|
243
|
+
export function registerLayoutScriptTools(server, client) {
|
|
244
|
+
server.registerTool(TOOL_LAYOUT_SCRIPT, LAYOUT_SCRIPT_TOOL_DEFINITIONS[TOOL_LAYOUT_SCRIPT], async ({ context, script }) => {
|
|
245
|
+
debugLogWithTag('LAYOUT_SCRIPT', `Executing layout script for ${context.type} layout (${script.length} chars)`);
|
|
246
|
+
try {
|
|
247
|
+
const endpoint = context.type === "page"
|
|
248
|
+
? "json/page/layoutScript"
|
|
249
|
+
: "json/type/layoutScript";
|
|
250
|
+
let requestBody;
|
|
251
|
+
if (context.type === "page") {
|
|
252
|
+
requestBody = {
|
|
253
|
+
pageUID: context.pageUID,
|
|
254
|
+
script
|
|
255
|
+
};
|
|
256
|
+
}
|
|
257
|
+
else {
|
|
258
|
+
requestBody = {
|
|
259
|
+
workspaceId: context.workspaceId,
|
|
260
|
+
typeInternalName: context.typeInternalName,
|
|
261
|
+
...(context.alternativeLayoutName && { alternativeLayoutName: context.alternativeLayoutName }),
|
|
262
|
+
script
|
|
263
|
+
};
|
|
264
|
+
}
|
|
265
|
+
const rawResponse = await client.makeRawApiRequest(endpoint, 'POST', undefined, requestBody);
|
|
266
|
+
debugLogWithTag('LAYOUT_SCRIPT', `Raw response success: ${rawResponse.success}, status: ${rawResponse.status || 'N/A'}`);
|
|
267
|
+
let response;
|
|
268
|
+
if (rawResponse.success === true) {
|
|
269
|
+
response = {
|
|
270
|
+
operation: "LAYOUT_SCRIPT",
|
|
271
|
+
success: true,
|
|
272
|
+
status: rawResponse.status,
|
|
273
|
+
context,
|
|
274
|
+
result: rawResponse.result,
|
|
275
|
+
...(rawResponse.validationWarnings && { validationWarnings: rawResponse.validationWarnings })
|
|
276
|
+
};
|
|
277
|
+
}
|
|
278
|
+
else if (rawResponse.errors) {
|
|
279
|
+
response = {
|
|
280
|
+
operation: "LAYOUT_SCRIPT",
|
|
281
|
+
success: false,
|
|
282
|
+
status: "VALIDATION_ERROR",
|
|
283
|
+
context,
|
|
284
|
+
errors: rawResponse.errors
|
|
285
|
+
};
|
|
286
|
+
}
|
|
287
|
+
else {
|
|
288
|
+
response = {
|
|
289
|
+
operation: "LAYOUT_SCRIPT",
|
|
290
|
+
success: false,
|
|
291
|
+
status: "ERROR",
|
|
292
|
+
context,
|
|
293
|
+
errorMessage: rawResponse.errorMessage || "Unknown error"
|
|
294
|
+
};
|
|
295
|
+
}
|
|
296
|
+
const sizeCheck = checkResponseSize(response);
|
|
297
|
+
if (sizeCheck.tooLarge) {
|
|
298
|
+
if (response.result) {
|
|
299
|
+
delete response.result;
|
|
300
|
+
response.resultNote = "Layout was persisted successfully. Result omitted due to size. Use cplace_layout_get_overview to inspect.";
|
|
301
|
+
const sizeCheck2 = checkResponseSize(response);
|
|
302
|
+
if (sizeCheck2.tooLarge) {
|
|
303
|
+
debugLogWithTag('LAYOUT_SCRIPT', `Response still too large after stripping result: ${sizeCheck2.actualSize} chars`);
|
|
304
|
+
return {
|
|
305
|
+
content: [{
|
|
306
|
+
type: "text",
|
|
307
|
+
text: `Layout script response too large (${sizeCheck2.actualSize} characters) even after stripping result. Use cplace_layout_get_overview to inspect the layout.`
|
|
308
|
+
}],
|
|
309
|
+
isError: true
|
|
310
|
+
};
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
else {
|
|
314
|
+
debugLogWithTag('LAYOUT_SCRIPT', `Error response too large: ${sizeCheck.actualSize} chars`);
|
|
315
|
+
return {
|
|
316
|
+
content: [{
|
|
317
|
+
type: "text",
|
|
318
|
+
text: `Layout script response too large (${sizeCheck.actualSize} characters). Use cplace_layout_get_overview to inspect the layout.`
|
|
319
|
+
}],
|
|
320
|
+
isError: true
|
|
321
|
+
};
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
debugLogWithTag('LAYOUT_SCRIPT', `Returning response with success=${response.success}, status=${response.status}`);
|
|
325
|
+
return {
|
|
326
|
+
content: [{ type: "text", text: JSON.stringify(response, null, 2) }],
|
|
327
|
+
...(!response.success ? { isError: true } : {})
|
|
328
|
+
};
|
|
329
|
+
}
|
|
330
|
+
catch (error) {
|
|
331
|
+
debugLogWithTag('LAYOUT_SCRIPT', `Error: ${error instanceof Error ? error.message : String(error)}`);
|
|
332
|
+
return {
|
|
333
|
+
content: [{
|
|
334
|
+
type: "text",
|
|
335
|
+
text: `Error executing layout script: ${error instanceof Error ? error.message : String(error)}`
|
|
336
|
+
}],
|
|
337
|
+
isError: true
|
|
338
|
+
};
|
|
339
|
+
}
|
|
340
|
+
});
|
|
341
|
+
server.registerTool(TOOL_LAYOUT_GET_OVERVIEW, LAYOUT_SCRIPT_TOOL_DEFINITIONS[TOOL_LAYOUT_GET_OVERVIEW], async ({ context }) => {
|
|
342
|
+
debugLogWithTag('LAYOUT', `Starting layout overview request for ${context.type} layout`);
|
|
343
|
+
try {
|
|
344
|
+
const result = await getLayoutOverview(client, context);
|
|
345
|
+
const overview = {
|
|
346
|
+
context,
|
|
347
|
+
rows: result.rows?.map((row, rowIndex) => ({
|
|
348
|
+
rowIndex,
|
|
349
|
+
columns: row.columns?.map((column, colIndex) => ({
|
|
350
|
+
columnIndex: colIndex,
|
|
351
|
+
proportion: column.proportion,
|
|
352
|
+
widgets: column.widgets?.map((widget) => ({
|
|
353
|
+
id: widget.id,
|
|
354
|
+
widgetType: widget.widgetType,
|
|
355
|
+
configurationCount: widget.configuration?.length || 0,
|
|
356
|
+
validationStatus: widget.validationStatus || null
|
|
357
|
+
})) || []
|
|
358
|
+
})) || []
|
|
359
|
+
})) || []
|
|
360
|
+
};
|
|
361
|
+
debugLogWithTag('LAYOUT', `Retrieved ${context.type} layout overview successfully`);
|
|
362
|
+
return {
|
|
363
|
+
content: [{ type: "text", text: JSON.stringify(overview, null, 2) }]
|
|
364
|
+
};
|
|
365
|
+
}
|
|
366
|
+
catch (error) {
|
|
367
|
+
debugLogWithTag('LAYOUT', `Error getting layout overview: ${error instanceof Error ? error.message : String(error)}`);
|
|
368
|
+
return {
|
|
369
|
+
content: [{
|
|
370
|
+
type: "text",
|
|
371
|
+
text: `Error getting ${context.type} layout overview: ${error instanceof Error ? error.message : String(error)}`
|
|
372
|
+
}],
|
|
373
|
+
isError: true
|
|
374
|
+
};
|
|
375
|
+
}
|
|
376
|
+
});
|
|
377
|
+
server.registerTool(TOOL_LAYOUT_GET_WIDGET_DETAILS, LAYOUT_SCRIPT_TOOL_DEFINITIONS[TOOL_LAYOUT_GET_WIDGET_DETAILS], async ({ context, widgetId }) => {
|
|
378
|
+
debugLogWithTag('LAYOUT', `Getting widget details for ${widgetId} from ${context.type} layout`);
|
|
379
|
+
try {
|
|
380
|
+
const layoutResult = await getLayoutOverview(client, context);
|
|
381
|
+
let foundWidget = null;
|
|
382
|
+
const findWidget = (rows) => {
|
|
383
|
+
for (const row of rows || []) {
|
|
384
|
+
for (const column of row.columns || []) {
|
|
385
|
+
for (const widget of column.widgets || []) {
|
|
386
|
+
if (widget.id === widgetId) {
|
|
387
|
+
return widget;
|
|
388
|
+
}
|
|
389
|
+
if (widget.widgetsLayout?.rows) {
|
|
390
|
+
const nestedWidget = findWidget(widget.widgetsLayout.rows);
|
|
391
|
+
if (nestedWidget)
|
|
392
|
+
return nestedWidget;
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
}
|
|
397
|
+
return null;
|
|
398
|
+
};
|
|
399
|
+
foundWidget = findWidget(layoutResult.rows);
|
|
400
|
+
if (!foundWidget) {
|
|
401
|
+
return {
|
|
402
|
+
content: [{ type: "text", text: `Widget with ID ${widgetId} not found in ${context.type} layout` }]
|
|
403
|
+
};
|
|
404
|
+
}
|
|
405
|
+
debugLogWithTag('LAYOUT', `Retrieved widget details for: ${widgetId} from ${context.type} layout`);
|
|
406
|
+
const response = {
|
|
407
|
+
context,
|
|
408
|
+
widgetId,
|
|
409
|
+
widget: foundWidget,
|
|
410
|
+
validationStatus: foundWidget.validationStatus || null
|
|
411
|
+
};
|
|
412
|
+
return {
|
|
413
|
+
content: [{ type: "text", text: JSON.stringify(response, null, 2) }]
|
|
414
|
+
};
|
|
415
|
+
}
|
|
416
|
+
catch (error) {
|
|
417
|
+
debugLogWithTag('LAYOUT', `Error getting widget details: ${error instanceof Error ? error.message : String(error)}`);
|
|
418
|
+
return {
|
|
419
|
+
content: [{
|
|
420
|
+
type: "text",
|
|
421
|
+
text: `Error getting widget details from ${context.type} layout: ${error instanceof Error ? error.message : String(error)}`
|
|
422
|
+
}],
|
|
423
|
+
isError: true
|
|
424
|
+
};
|
|
425
|
+
}
|
|
426
|
+
});
|
|
427
|
+
server.registerTool(TOOL_LAYOUT_GET_SCRIPT, LAYOUT_SCRIPT_TOOL_DEFINITIONS[TOOL_LAYOUT_GET_SCRIPT], async ({ context }) => {
|
|
428
|
+
debugLogWithTag('LAYOUT', `Getting layout script for ${context.type} layout`);
|
|
429
|
+
try {
|
|
430
|
+
const endpoint = context.type === "page"
|
|
431
|
+
? "json/page/layoutScript"
|
|
432
|
+
: "json/type/layoutScript";
|
|
433
|
+
const params = buildRequestParams(context);
|
|
434
|
+
const rawResponse = await client.makeRawApiRequest(endpoint, 'GET', params);
|
|
435
|
+
if (rawResponse.success !== true) {
|
|
436
|
+
return {
|
|
437
|
+
content: [{
|
|
438
|
+
type: "text",
|
|
439
|
+
text: `Error getting ${context.type} layout script: ${rawResponse.errorMessage || "Unknown error"}`
|
|
440
|
+
}],
|
|
441
|
+
isError: true
|
|
442
|
+
};
|
|
443
|
+
}
|
|
444
|
+
const response = {
|
|
445
|
+
context,
|
|
446
|
+
script: rawResponse.script
|
|
447
|
+
};
|
|
448
|
+
const sizeCheck = checkResponseSize(response);
|
|
449
|
+
if (sizeCheck.tooLarge) {
|
|
450
|
+
return {
|
|
451
|
+
content: [{
|
|
452
|
+
type: "text",
|
|
453
|
+
text: `Layout script response too large (${sizeCheck.actualSize} characters). Use cplace_layout_get_overview to inspect the layout structure instead.`
|
|
454
|
+
}],
|
|
455
|
+
isError: true
|
|
456
|
+
};
|
|
457
|
+
}
|
|
458
|
+
return {
|
|
459
|
+
content: [{ type: "text", text: JSON.stringify(response, null, 2) }]
|
|
460
|
+
};
|
|
461
|
+
}
|
|
462
|
+
catch (error) {
|
|
463
|
+
debugLogWithTag('LAYOUT', `Error getting layout script: ${error instanceof Error ? error.message : String(error)}`);
|
|
464
|
+
return {
|
|
465
|
+
content: [{
|
|
466
|
+
type: "text",
|
|
467
|
+
text: `Error getting ${context.type} layout script: ${error instanceof Error ? error.message : String(error)}`
|
|
468
|
+
}],
|
|
469
|
+
isError: true
|
|
470
|
+
};
|
|
471
|
+
}
|
|
472
|
+
});
|
|
473
|
+
}
|
|
474
|
+
//# sourceMappingURL=layout-script.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"layout-script.js","sourceRoot":"","sources":["../../src/tools/layout-script.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAGhD,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC;IACzC,CAAC,CAAC,MAAM,CAAC;QACP,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC;QACvB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,gCAAgC,CAA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;oBACF,OAAO,EAAE,IAAI;iBACd,CAAC;YACJ,CAAC;YAED,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;aACrE,CAAC;QACJ,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAe,CAAC,QAAQ,EAAE,gCAAgC,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;YACpH,OAAO;gBACL,OAAO,EAAE,CAAC;wBACR,IAAI,EAAE,MAAM;wBACZ,IAAI,EAAE,iBAAiB,OAAO,CAAC,IAAI,mBAAmB,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE;qBAC/G,CAAC;gBACF,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
|
|
@@ -2,17 +2,6 @@ import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import { CplaceApiClient } from '../api.js';
|
|
4
4
|
export declare const TYPE_LAYOUT_TOOL_DEFINITIONS: {
|
|
5
|
-
readonly cplace_get_type_layout: {
|
|
6
|
-
readonly description: "Retrieves the widget layout structure of a specific type definition, including all widget configurations and layout definitions. This endpoint returns the effective layout used by the type, which can be either the default layout or an alternative layout.";
|
|
7
|
-
readonly inputSchema: {
|
|
8
|
-
readonly workspaceId: z.ZodString;
|
|
9
|
-
readonly typeInternalName: z.ZodString;
|
|
10
|
-
readonly alternativeLayoutName: z.ZodOptional<z.ZodString>;
|
|
11
|
-
};
|
|
12
|
-
readonly annotations: {
|
|
13
|
-
readonly title: "Get Type Layout";
|
|
14
|
-
};
|
|
15
|
-
};
|
|
16
5
|
readonly cplace_list_type_alternative_layouts: {
|
|
17
6
|
readonly description: "Retrieves a comprehensive list of all available layouts for a specific type definition, including the default layout and all alternative layouts, along with usage statistics.";
|
|
18
7
|
readonly inputSchema: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"type-layouts.d.ts","sourceRoot":"","sources":["../../src/tools/type-layouts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"type-layouts.d.ts","sourceRoot":"","sources":["../../src/tools/type-layouts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAQ5C,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;CAoB/B,CAAC;AAEX,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,eAAe,QA+DjF"}
|
|
@@ -1,18 +1,8 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
import { debugLogWithTag } from "../logger.js";
|
|
3
|
-
const TOOL_GET_TYPE_LAYOUT = 'cplace_get_type_layout';
|
|
4
3
|
const TOOL_LIST_TYPE_ALTERNATIVE_LAYOUTS = 'cplace_list_type_alternative_layouts';
|
|
5
4
|
const TOOL_CREATE_TYPE_ALTERNATIVE_LAYOUT = 'cplace_create_type_alternative_layout';
|
|
6
5
|
export const TYPE_LAYOUT_TOOL_DEFINITIONS = {
|
|
7
|
-
[TOOL_GET_TYPE_LAYOUT]: {
|
|
8
|
-
description: "Retrieves the widget layout structure of a specific type definition, including all widget configurations and layout definitions. This endpoint returns the effective layout used by the type, which can be either the default layout or an alternative layout.",
|
|
9
|
-
inputSchema: {
|
|
10
|
-
workspaceId: z.string().describe("The ID of the workspace containing the type definition"),
|
|
11
|
-
typeInternalName: z.string().describe("The internal name of the type definition"),
|
|
12
|
-
alternativeLayoutName: z.string().optional().describe("The name of the alternative layout to retrieve. If not provided, returns the default layout")
|
|
13
|
-
},
|
|
14
|
-
annotations: { title: "Get Type Layout" }
|
|
15
|
-
},
|
|
16
6
|
[TOOL_LIST_TYPE_ALTERNATIVE_LAYOUTS]: {
|
|
17
7
|
description: "Retrieves a comprehensive list of all available layouts for a specific type definition, including the default layout and all alternative layouts, along with usage statistics.",
|
|
18
8
|
inputSchema: {
|
|
@@ -34,27 +24,6 @@ export const TYPE_LAYOUT_TOOL_DEFINITIONS = {
|
|
|
34
24
|
}
|
|
35
25
|
};
|
|
36
26
|
export function registerTypeLayoutTools(server, client) {
|
|
37
|
-
server.registerTool(TOOL_GET_TYPE_LAYOUT, TYPE_LAYOUT_TOOL_DEFINITIONS[TOOL_GET_TYPE_LAYOUT], async ({ workspaceId, typeInternalName, alternativeLayoutName }) => {
|
|
38
|
-
debugLogWithTag('TYPE_LAYOUT', `Getting type layout for ${typeInternalName} in workspace ${workspaceId}${alternativeLayoutName ? ` (layout: ${alternativeLayoutName})` : ' (default)'}`);
|
|
39
|
-
try {
|
|
40
|
-
const params = { workspaceId, typeInternalName };
|
|
41
|
-
if (alternativeLayoutName) {
|
|
42
|
-
params.alternativeLayoutName = alternativeLayoutName;
|
|
43
|
-
}
|
|
44
|
-
const result = await client.makeApiRequest('json/typeLayout', 'GET', params);
|
|
45
|
-
debugLogWithTag('TYPE_LAYOUT', `Successfully retrieved type layout for ${typeInternalName}`);
|
|
46
|
-
return {
|
|
47
|
-
content: [{ type: "text", text: JSON.stringify(result, null, 2) }]
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
catch (error) {
|
|
51
|
-
debugLogWithTag('TYPE_LAYOUT', `Error retrieving type layout: ${error instanceof Error ? error.message : String(error)}`);
|
|
52
|
-
return {
|
|
53
|
-
content: [{ type: "text", text: `Error retrieving type layout: ${error instanceof Error ? error.message : String(error)}` }],
|
|
54
|
-
isError: true
|
|
55
|
-
};
|
|
56
|
-
}
|
|
57
|
-
});
|
|
58
27
|
server.registerTool(TOOL_LIST_TYPE_ALTERNATIVE_LAYOUTS, TYPE_LAYOUT_TOOL_DEFINITIONS[TOOL_LIST_TYPE_ALTERNATIVE_LAYOUTS], async ({ workspaceId, typeInternalName }) => {
|
|
59
28
|
debugLogWithTag('TYPE_LAYOUT', `Listing alternative layouts for type ${typeInternalName} in workspace ${workspaceId}`);
|
|
60
29
|
try {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"type-layouts.js","sourceRoot":"","sources":["../../src/tools/type-layouts.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"type-layouts.js","sourceRoot":"","sources":["../../src/tools/type-layouts.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAG/C,MAAM,kCAAkC,GAAG,sCAAsC,CAAC;AAClF,MAAM,mCAAmC,GAAG,uCAAuC,CAAC;AAGpF,MAAM,CAAC,MAAM,4BAA4B,GAAG;IAC1C,CAAC,kCAAkC,CAAC,EAAE;QACpC,WAAW,EAAE,gLAAgL;QAC7L,WAAW,EAAE;YACX,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,wDAAwD,CAAC;YAC1F,gBAAgB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,0CAA0C,CAAC;SAClF;QACD,WAAW,EAAE,EAAE,KAAK,EAAE,+BA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OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;aACnE,CAAC;QACJ,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAe,CAAC,aAAa,EAAE,sCAAsC,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;YAC/H,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,sCAAsC,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC;gBACjI,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CACF,CAAC;AAEJ,CAAC"}
|
|
@@ -44,7 +44,7 @@ export declare const TYPE_MANAGEMENT_TOOL_DEFINITIONS: {
|
|
|
44
44
|
readonly attributeName: z.ZodString;
|
|
45
45
|
readonly multiplicity: z.ZodOptional<z.ZodEnum<["exactlyOne", "maximalOne", "atLeastOne", "arbitrary"]>>;
|
|
46
46
|
readonly constraintConfig: z.ZodOptional<z.ZodObject<{
|
|
47
|
-
constraintType: z.ZodEnum<["string", "longString", "richString", "localizedString", "number", "boolean", "date", "color", "reference", "textEnumeration", "numberEnumeration", "dynamicEnumeration", "workflow"]>;
|
|
47
|
+
constraintType: z.ZodEnum<["string", "longString", "richString", "localizedString", "number", "boolean", "date", "color", "reference", "textEnumeration", "numberEnumeration", "dynamicEnumeration", "workflow", "linkedAttribute"]>;
|
|
48
48
|
pattern: z.ZodOptional<z.ZodString>;
|
|
49
49
|
patternErrorMessage: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
50
50
|
precision: z.ZodOptional<z.ZodNumber>;
|
|
@@ -72,8 +72,10 @@ export declare const TYPE_MANAGEMENT_TOOL_DEFINITIONS: {
|
|
|
72
72
|
}>, "many">>;
|
|
73
73
|
providerClass: z.ZodOptional<z.ZodString>;
|
|
74
74
|
providerSimpleName: z.ZodOptional<z.ZodString>;
|
|
75
|
+
linkedReferenceName: z.ZodOptional<z.ZodString>;
|
|
76
|
+
linkedPropertyName: z.ZodOptional<z.ZodString>;
|
|
75
77
|
}, "strip", z.ZodTypeAny, {
|
|
76
|
-
constraintType: "string" | "number" | "boolean" | "workflow" | "date" | "reference" | "textEnumeration" | "numberEnumeration" | "dynamicEnumeration" | "longString" | "richString" | "localizedString" | "color";
|
|
78
|
+
constraintType: "string" | "number" | "boolean" | "workflow" | "date" | "reference" | "textEnumeration" | "numberEnumeration" | "dynamicEnumeration" | "longString" | "richString" | "localizedString" | "color" | "linkedAttribute";
|
|
77
79
|
pattern?: string | undefined;
|
|
78
80
|
patternErrorMessage?: Record<string, string> | undefined;
|
|
79
81
|
precision?: number | undefined;
|
|
@@ -93,8 +95,10 @@ export declare const TYPE_MANAGEMENT_TOOL_DEFINITIONS: {
|
|
|
93
95
|
}[] | undefined;
|
|
94
96
|
providerClass?: string | undefined;
|
|
95
97
|
providerSimpleName?: string | undefined;
|
|
98
|
+
linkedReferenceName?: string | undefined;
|
|
99
|
+
linkedPropertyName?: string | undefined;
|
|
96
100
|
}, {
|
|
97
|
-
constraintType: "string" | "number" | "boolean" | "workflow" | "date" | "reference" | "textEnumeration" | "numberEnumeration" | "dynamicEnumeration" | "longString" | "richString" | "localizedString" | "color";
|
|
101
|
+
constraintType: "string" | "number" | "boolean" | "workflow" | "date" | "reference" | "textEnumeration" | "numberEnumeration" | "dynamicEnumeration" | "longString" | "richString" | "localizedString" | "color" | "linkedAttribute";
|
|
98
102
|
pattern?: string | undefined;
|
|
99
103
|
patternErrorMessage?: Record<string, string> | undefined;
|
|
100
104
|
precision?: number | undefined;
|
|
@@ -114,6 +118,8 @@ export declare const TYPE_MANAGEMENT_TOOL_DEFINITIONS: {
|
|
|
114
118
|
}[] | undefined;
|
|
115
119
|
providerClass?: string | undefined;
|
|
116
120
|
providerSimpleName?: string | undefined;
|
|
121
|
+
linkedReferenceName?: string | undefined;
|
|
122
|
+
linkedPropertyName?: string | undefined;
|
|
117
123
|
}>>;
|
|
118
124
|
readonly localizedNames: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
119
125
|
readonly localizedShortNames: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"type-management.d.ts","sourceRoot":"","sources":["../../src/tools/type-management.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAQ5C,eAAO,MAAM,gCAAgC
|
|
1
|
+
{"version":3,"file":"type-management.d.ts","sourceRoot":"","sources":["../../src/tools/type-management.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAQ5C,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8GnC,CAAC;AAEX,wBAAgB,2BAA2B,CAAC,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,eAAe,QAkNrF"}
|