@umbraco-cms/mcp-dev 18.0.1 → 18.0.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/dist/{chunk-KKNLEZQN.js → chunk-WQUG24BZ.js} +2061 -1701
- package/dist/chunk-WQUG24BZ.js.map +1 -0
- package/dist/{chunk-MVY77GF3.cjs → chunk-ZZQVLZLS.cjs} +873 -513
- package/dist/chunk-ZZQVLZLS.cjs.map +1 -0
- package/dist/collections.cjs +2 -2
- package/dist/collections.cjs.map +1 -1
- package/dist/collections.js +1 -1
- package/dist/collections.js.map +1 -1
- package/dist/index.cjs +103 -93
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +17 -7
- package/dist/index.js.map +1 -1
- package/dist/tool-types.d.ts +181 -0
- package/package.json +5 -1
- package/dist/chunk-KKNLEZQN.js.map +0 -1
- package/dist/chunk-MVY77GF3.cjs.map +0 -1
package/dist/tool-types.d.ts
CHANGED
|
@@ -1412,6 +1412,10 @@ export interface UpdateDocumentInput {
|
|
|
1412
1412
|
name: string;
|
|
1413
1413
|
}[];
|
|
1414
1414
|
};
|
|
1415
|
+
/**
|
|
1416
|
+
* Must be set to true to proceed when 'data.values' is an empty array and the document currently has property values. Without this, the call is rejected to prevent accidentally wiping every property value - the exact mistake that motivated this guard. Not needed if the document has no existing values, or if 'data.values' is non-empty.
|
|
1417
|
+
*/
|
|
1418
|
+
confirmClearValues?: boolean;
|
|
1415
1419
|
}
|
|
1416
1420
|
|
|
1417
1421
|
export interface UpdateDocumentPropertiesInput {
|
|
@@ -1477,6 +1481,35 @@ export interface UpdateDocumentPropertiesOutput {
|
|
|
1477
1481
|
};
|
|
1478
1482
|
}
|
|
1479
1483
|
|
|
1484
|
+
export interface UpdateDocumentNameInput {
|
|
1485
|
+
/**
|
|
1486
|
+
* The unique identifier of the document to rename
|
|
1487
|
+
*/
|
|
1488
|
+
id: string;
|
|
1489
|
+
/**
|
|
1490
|
+
* The new name for the document (or the document variant matching the given culture)
|
|
1491
|
+
*/
|
|
1492
|
+
name: string;
|
|
1493
|
+
/**
|
|
1494
|
+
* Optional culture code identifying which variant to rename (e.g., 'en-US'). Required when the document varies by culture and has more than one variant; omit for invariant documents.
|
|
1495
|
+
*/
|
|
1496
|
+
culture?: string | null;
|
|
1497
|
+
}
|
|
1498
|
+
|
|
1499
|
+
export interface UpdateDocumentNameOutput {
|
|
1500
|
+
success: boolean;
|
|
1501
|
+
message: string;
|
|
1502
|
+
previousName: string;
|
|
1503
|
+
name: string;
|
|
1504
|
+
culture: string | null;
|
|
1505
|
+
/**
|
|
1506
|
+
* The updated document object
|
|
1507
|
+
*/
|
|
1508
|
+
document: {
|
|
1509
|
+
[k: string]: unknown;
|
|
1510
|
+
};
|
|
1511
|
+
}
|
|
1512
|
+
|
|
1480
1513
|
export interface UpdateBlockPropertyInput {
|
|
1481
1514
|
/**
|
|
1482
1515
|
* The document containing the block
|
|
@@ -4226,6 +4259,152 @@ export interface UpdateElementPropertiesOutput {
|
|
|
4226
4259
|
};
|
|
4227
4260
|
}
|
|
4228
4261
|
|
|
4262
|
+
export interface UpdateElementBlockPropertyInput {
|
|
4263
|
+
/**
|
|
4264
|
+
* The element containing the block
|
|
4265
|
+
*/
|
|
4266
|
+
elementId: string;
|
|
4267
|
+
/**
|
|
4268
|
+
* Element property alias containing BlockList/BlockGrid
|
|
4269
|
+
*/
|
|
4270
|
+
propertyAlias: string;
|
|
4271
|
+
/**
|
|
4272
|
+
* Optional culture for variant element properties
|
|
4273
|
+
*/
|
|
4274
|
+
culture?: string | null;
|
|
4275
|
+
/**
|
|
4276
|
+
* Optional segment for variant element properties
|
|
4277
|
+
*/
|
|
4278
|
+
segment?: string | null;
|
|
4279
|
+
/**
|
|
4280
|
+
* Array of block updates
|
|
4281
|
+
*
|
|
4282
|
+
* @minItems 1
|
|
4283
|
+
*/
|
|
4284
|
+
updates: [
|
|
4285
|
+
{
|
|
4286
|
+
/**
|
|
4287
|
+
* The unique key (UUID) identifying the block
|
|
4288
|
+
*/
|
|
4289
|
+
contentKey: string;
|
|
4290
|
+
/**
|
|
4291
|
+
* 'content' for contentData, 'settings' for settingsData
|
|
4292
|
+
*/
|
|
4293
|
+
blockType: "content" | "settings";
|
|
4294
|
+
/**
|
|
4295
|
+
* Properties to update within this block
|
|
4296
|
+
*
|
|
4297
|
+
* @minItems 1
|
|
4298
|
+
*/
|
|
4299
|
+
properties: [
|
|
4300
|
+
{
|
|
4301
|
+
/**
|
|
4302
|
+
* The property alias within the block to update
|
|
4303
|
+
*/
|
|
4304
|
+
alias: string;
|
|
4305
|
+
/**
|
|
4306
|
+
* The new value for the property
|
|
4307
|
+
*/
|
|
4308
|
+
value?: unknown | null;
|
|
4309
|
+
/**
|
|
4310
|
+
* Optional culture code for variant block properties
|
|
4311
|
+
*/
|
|
4312
|
+
culture?: string | null;
|
|
4313
|
+
/**
|
|
4314
|
+
* Optional segment identifier for variant block properties
|
|
4315
|
+
*/
|
|
4316
|
+
segment?: string | null;
|
|
4317
|
+
},
|
|
4318
|
+
...{
|
|
4319
|
+
/**
|
|
4320
|
+
* The property alias within the block to update
|
|
4321
|
+
*/
|
|
4322
|
+
alias: string;
|
|
4323
|
+
/**
|
|
4324
|
+
* The new value for the property
|
|
4325
|
+
*/
|
|
4326
|
+
value?: unknown | null;
|
|
4327
|
+
/**
|
|
4328
|
+
* Optional culture code for variant block properties
|
|
4329
|
+
*/
|
|
4330
|
+
culture?: string | null;
|
|
4331
|
+
/**
|
|
4332
|
+
* Optional segment identifier for variant block properties
|
|
4333
|
+
*/
|
|
4334
|
+
segment?: string | null;
|
|
4335
|
+
}[]
|
|
4336
|
+
];
|
|
4337
|
+
},
|
|
4338
|
+
...{
|
|
4339
|
+
/**
|
|
4340
|
+
* The unique key (UUID) identifying the block
|
|
4341
|
+
*/
|
|
4342
|
+
contentKey: string;
|
|
4343
|
+
/**
|
|
4344
|
+
* 'content' for contentData, 'settings' for settingsData
|
|
4345
|
+
*/
|
|
4346
|
+
blockType: "content" | "settings";
|
|
4347
|
+
/**
|
|
4348
|
+
* Properties to update within this block
|
|
4349
|
+
*
|
|
4350
|
+
* @minItems 1
|
|
4351
|
+
*/
|
|
4352
|
+
properties: [
|
|
4353
|
+
{
|
|
4354
|
+
/**
|
|
4355
|
+
* The property alias within the block to update
|
|
4356
|
+
*/
|
|
4357
|
+
alias: string;
|
|
4358
|
+
/**
|
|
4359
|
+
* The new value for the property
|
|
4360
|
+
*/
|
|
4361
|
+
value?: unknown | null;
|
|
4362
|
+
/**
|
|
4363
|
+
* Optional culture code for variant block properties
|
|
4364
|
+
*/
|
|
4365
|
+
culture?: string | null;
|
|
4366
|
+
/**
|
|
4367
|
+
* Optional segment identifier for variant block properties
|
|
4368
|
+
*/
|
|
4369
|
+
segment?: string | null;
|
|
4370
|
+
},
|
|
4371
|
+
...{
|
|
4372
|
+
/**
|
|
4373
|
+
* The property alias within the block to update
|
|
4374
|
+
*/
|
|
4375
|
+
alias: string;
|
|
4376
|
+
/**
|
|
4377
|
+
* The new value for the property
|
|
4378
|
+
*/
|
|
4379
|
+
value?: unknown | null;
|
|
4380
|
+
/**
|
|
4381
|
+
* Optional culture code for variant block properties
|
|
4382
|
+
*/
|
|
4383
|
+
culture?: string | null;
|
|
4384
|
+
/**
|
|
4385
|
+
* Optional segment identifier for variant block properties
|
|
4386
|
+
*/
|
|
4387
|
+
segment?: string | null;
|
|
4388
|
+
}[]
|
|
4389
|
+
];
|
|
4390
|
+
}[]
|
|
4391
|
+
];
|
|
4392
|
+
}
|
|
4393
|
+
|
|
4394
|
+
export interface UpdateElementBlockPropertyOutput {
|
|
4395
|
+
success: boolean;
|
|
4396
|
+
message: string;
|
|
4397
|
+
results: {
|
|
4398
|
+
success: boolean;
|
|
4399
|
+
contentKey: string;
|
|
4400
|
+
message: string;
|
|
4401
|
+
updatedCount?: number;
|
|
4402
|
+
addedCount?: number;
|
|
4403
|
+
warnings?: string[];
|
|
4404
|
+
errors?: string[];
|
|
4405
|
+
}[];
|
|
4406
|
+
}
|
|
4407
|
+
|
|
4229
4408
|
export interface MoveElementInput {
|
|
4230
4409
|
id: string;
|
|
4231
4410
|
data: {
|
|
@@ -17805,6 +17984,7 @@ export interface CmsTools {
|
|
|
17805
17984
|
"unpublish-document": { input: UnpublishDocumentInput; output: unknown };
|
|
17806
17985
|
"update-document": { input: UpdateDocumentInput; output: unknown };
|
|
17807
17986
|
"update-document-properties": { input: UpdateDocumentPropertiesInput; output: UpdateDocumentPropertiesOutput };
|
|
17987
|
+
"update-document-name": { input: UpdateDocumentNameInput; output: UpdateDocumentNameOutput };
|
|
17808
17988
|
"update-block-property": { input: UpdateBlockPropertyInput; output: UpdateBlockPropertyOutput };
|
|
17809
17989
|
"put-document-domains": { input: PutDocumentDomainsInput; output: unknown };
|
|
17810
17990
|
"put-document-notifications": { input: PutDocumentNotificationsInput; output: unknown };
|
|
@@ -17888,6 +18068,7 @@ export interface CmsTools {
|
|
|
17888
18068
|
"rollback-element-version": { input: RollbackElementVersionInput; output: unknown };
|
|
17889
18069
|
"update-element": { input: UpdateElementInput; output: unknown };
|
|
17890
18070
|
"update-element-properties": { input: UpdateElementPropertiesInput; output: UpdateElementPropertiesOutput };
|
|
18071
|
+
"update-element-block-property": { input: UpdateElementBlockPropertyInput; output: UpdateElementBlockPropertyOutput };
|
|
17891
18072
|
"move-element": { input: MoveElementInput; output: unknown };
|
|
17892
18073
|
"move-element-to-recycle-bin": { input: MoveElementToRecycleBinInput; output: unknown };
|
|
17893
18074
|
"publish-element": { input: PublishElementInput; output: unknown };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umbraco-cms/mcp-dev",
|
|
3
|
-
"version": "18.0.
|
|
3
|
+
"version": "18.0.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A model context protocol (MCP) server for Umbraco CMS",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -27,6 +27,9 @@
|
|
|
27
27
|
"generate": "orval --config orval.config.ts",
|
|
28
28
|
"inspect": "npx @modelcontextprotocol/inspector node dist/index.js",
|
|
29
29
|
"test": "node --experimental-vm-modules node_modules/jest/bin/jest.js",
|
|
30
|
+
"test:all": "npm run build && npm run test && npm run test:evals",
|
|
31
|
+
"test:one": "node --experimental-vm-modules node_modules/jest/bin/jest.js --runInBand --forceExit",
|
|
32
|
+
"test:changed": "node scripts/test-changed.mjs",
|
|
30
33
|
"test:rerun-failures": "grep '^FAIL ' test-failures.log 2>/dev/null | sed 's/^FAIL //' | tr '\\n' ' ' | xargs -r node --experimental-vm-modules node_modules/jest/bin/jest.js --no-coverage || echo 'No failures to rerun (test-failures.log not found or empty)'",
|
|
31
34
|
"test:evals": "node --experimental-vm-modules node_modules/jest/bin/jest.js --no-coverage --config tests/evals/jest.config.ts",
|
|
32
35
|
"patch-publish-alpha": "npm version prerelease --preid=alpha && npm publish --tag alpha --access public",
|
|
@@ -36,6 +39,7 @@
|
|
|
36
39
|
"test:e2e": "npx playwright test --config tests/cms-hosted-e2e/playwright.config.ts",
|
|
37
40
|
"umbraco:bootstrap": "bash scripts/bootstrap-demo-site.sh",
|
|
38
41
|
"umbraco:start": "bash scripts/bootstrap-demo-site.sh && dotnet run --project demo-site",
|
|
42
|
+
"start:umbraco": "npm run umbraco:start",
|
|
39
43
|
"umbraco:stop": "lsof -ti :44391 | xargs kill 2>/dev/null; lsof -ti :56472 | xargs kill 2>/dev/null",
|
|
40
44
|
"dev:hosted": "wrangler dev"
|
|
41
45
|
},
|