snow-flow 4.5.29 → 4.5.31
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/CLAUDE.md
CHANGED
|
@@ -659,14 +659,16 @@ Snow-Flow now automatically sets its Update Set as the user's current Update Set
|
|
|
659
659
|
- `snow_get_flow_details` - Get detailed flow configuration
|
|
660
660
|
- `snow_import_flow_from_xml` - Import flows from XML (only programmatic creation method)
|
|
661
661
|
|
|
662
|
-
**Agent Workspace Tools:**
|
|
663
|
-
- `snow_create_workspace` - Create
|
|
664
|
-
- `snow_discover_workspaces` - Find all
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
- **
|
|
669
|
-
- **
|
|
662
|
+
**Configurable Agent Workspace Tools (UX App Architecture):**
|
|
663
|
+
- `snow_create_workspace` - Create Configurable Agent Workspaces using UX App architecture (sys_ux_app_route, sys_ux_screen_type, sys_ux_screen, sys_ux_macroponent)
|
|
664
|
+
- `snow_discover_workspaces` - Find all Configurable Workspaces
|
|
665
|
+
|
|
666
|
+
**🏗️ CONFIGURABLE WORKSPACE ARCHITECTURE:**
|
|
667
|
+
Based on ServiceNow's official Configurable Agent Workspace structure:
|
|
668
|
+
- **App Route** → `sys_ux_app_route` (top-level workspace routing)
|
|
669
|
+
- **Screen Collection** → `sys_ux_screen_type` (groups of related screens)
|
|
670
|
+
- **Individual Screens** → `sys_ux_screen` (specific workspace screens)
|
|
671
|
+
- **Screen Components** → `sys_ux_macroponent` (components within screens)
|
|
670
672
|
|
|
671
673
|
**Mobile App Tools:**
|
|
672
674
|
- `snow_configure_mobile_app` - Configure mobile applications
|
|
@@ -1229,79 +1229,87 @@ ${executionList}
|
|
|
1229
1229
|
async createWorkspace(args) {
|
|
1230
1230
|
try {
|
|
1231
1231
|
this.logger.info('Creating Agent Workspace...');
|
|
1232
|
-
//
|
|
1233
|
-
const tableCheck = await this.client.searchRecords('
|
|
1232
|
+
// Validate Configurable Workspace (UX App) table access
|
|
1233
|
+
const tableCheck = await this.client.searchRecords('sys_ux_app_route', '', 1);
|
|
1234
1234
|
if (!tableCheck.success) {
|
|
1235
1235
|
return {
|
|
1236
1236
|
success: false,
|
|
1237
|
-
error: 'Agent Workspace tables not accessible. This feature requires
|
|
1238
|
-
suggestion: '
|
|
1237
|
+
error: 'Configurable Agent Workspace (UX App) tables not accessible. This feature requires Now Experience Framework and Configurable Workspace licensing.',
|
|
1238
|
+
suggestion: 'Verify Now Experience Framework is licensed and Configurable Workspace is enabled in your ServiceNow instance.'
|
|
1239
1239
|
};
|
|
1240
1240
|
}
|
|
1241
|
-
//
|
|
1242
|
-
const
|
|
1243
|
-
|
|
1241
|
+
// CORRECTED: Use UX App architecture for Configurable Agent Workspaces
|
|
1242
|
+
const appRoute = this.generateWorkspaceUrl(args.name);
|
|
1243
|
+
// Step 1: Create UX App Route (top level)
|
|
1244
|
+
const appRouteData = {
|
|
1245
|
+
route: `/${appRoute}`,
|
|
1244
1246
|
name: args.name,
|
|
1247
|
+
title: args.name,
|
|
1245
1248
|
description: args.description || '',
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1249
|
+
application: 'global',
|
|
1250
|
+
active: true
|
|
1251
|
+
};
|
|
1252
|
+
const routeResponse = await this.client.createRecord('sys_ux_app_route', appRouteData);
|
|
1253
|
+
if (!routeResponse.success) {
|
|
1254
|
+
return {
|
|
1255
|
+
success: false,
|
|
1256
|
+
error: `Failed to create UX App Route: ${routeResponse.error}`,
|
|
1257
|
+
suggestion: 'Check Now Experience Framework permissions and UX App licensing.'
|
|
1258
|
+
};
|
|
1259
|
+
}
|
|
1260
|
+
// Step 2: Create Screen Type (collection)
|
|
1261
|
+
const screenTypeData = {
|
|
1262
|
+
name: `${args.name}_screens`,
|
|
1263
|
+
title: `${args.name} Screens`,
|
|
1264
|
+
description: `Screen collection for ${args.name} workspace`,
|
|
1265
|
+
app_route: routeResponse.data.sys_id,
|
|
1266
|
+
active: true
|
|
1264
1267
|
};
|
|
1268
|
+
const screenTypeResponse = await this.client.createRecord('sys_ux_screen_type', screenTypeData);
|
|
1269
|
+
if (!screenTypeResponse.success) {
|
|
1270
|
+
return {
|
|
1271
|
+
success: false,
|
|
1272
|
+
error: `Failed to create Screen Type: ${screenTypeResponse.error}`,
|
|
1273
|
+
suggestion: 'Check UX Screen Type permissions.'
|
|
1274
|
+
};
|
|
1275
|
+
}
|
|
1265
1276
|
this.logger.trackAPICall('CREATE', 'sys_aw_master_config', 1);
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
error: 'Invalid workspace configuration. Missing required fields detected.',
|
|
1280
|
-
suggestion: 'Verify all required fields: workspace_url, navigation_type, search settings.',
|
|
1281
|
-
remediation: 'Check ServiceNow Agent Workspace documentation for required field specifications'
|
|
1277
|
+
// Step 3: Create default screens for each table
|
|
1278
|
+
const createdScreens = [];
|
|
1279
|
+
if (args.tables && args.tables.length > 0) {
|
|
1280
|
+
for (let i = 0; i < args.tables.length; i++) {
|
|
1281
|
+
const table = args.tables[i];
|
|
1282
|
+
const screenData = {
|
|
1283
|
+
name: `${args.name}_${table}_screen`,
|
|
1284
|
+
title: `${table.charAt(0).toUpperCase() + table.slice(1)} Management`,
|
|
1285
|
+
description: `${table} management screen for ${args.name}`,
|
|
1286
|
+
screen_type: screenTypeResponse.data.sys_id,
|
|
1287
|
+
table: table,
|
|
1288
|
+
order: i * 100,
|
|
1289
|
+
active: true
|
|
1282
1290
|
};
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
global_search_data: searchConfig.data.sys_id
|
|
1299
|
-
});
|
|
1291
|
+
const screenResponse = await this.client.createRecord('sys_ux_screen', screenData);
|
|
1292
|
+
if (screenResponse.success) {
|
|
1293
|
+
createdScreens.push(screenResponse.data);
|
|
1294
|
+
// Create macroponent for each screen
|
|
1295
|
+
const macroponentData = {
|
|
1296
|
+
name: `${args.name}_${table}_macroponent`,
|
|
1297
|
+
title: `${table} Component`,
|
|
1298
|
+
description: `Macroponent for ${table} in ${args.name}`,
|
|
1299
|
+
screen: screenResponse.data.sys_id,
|
|
1300
|
+
component_type: 'table',
|
|
1301
|
+
table: table,
|
|
1302
|
+
active: true
|
|
1303
|
+
};
|
|
1304
|
+
await this.client.createRecord('sys_ux_macroponent', macroponentData);
|
|
1305
|
+
}
|
|
1300
1306
|
}
|
|
1301
1307
|
}
|
|
1302
|
-
|
|
1303
|
-
|
|
1308
|
+
if (!routeResponse.success) {
|
|
1309
|
+
throw new Error(`Failed to create configurable workspace: ${routeResponse.error}`);
|
|
1304
1310
|
}
|
|
1311
|
+
const workspaceId = routeResponse.data.sys_id;
|
|
1312
|
+
// Note: Search config handled by UX framework automatically for Configurable Workspaces
|
|
1305
1313
|
// UPDATED: Modern workspace tab creation guidance
|
|
1306
1314
|
let tabsCreated = 0;
|
|
1307
1315
|
let modernWorkspaceNote = '';
|
|
@@ -490,6 +490,8 @@ class SnowFlowMCPServer {
|
|
|
490
490
|
task.assignedAgent = availableAgent.id;
|
|
491
491
|
availableAgent.status = 'busy';
|
|
492
492
|
}
|
|
493
|
+
// Fix: Handle dependencies parameter safely
|
|
494
|
+
const dependencies = args.dependencies || [];
|
|
493
495
|
return {
|
|
494
496
|
content: [
|
|
495
497
|
{
|
|
@@ -499,9 +501,11 @@ class SnowFlowMCPServer {
|
|
|
499
501
|
task: task.description,
|
|
500
502
|
strategy: args.strategy || 'adaptive',
|
|
501
503
|
priority: args.priority || 'medium',
|
|
504
|
+
dependencies: dependencies,
|
|
505
|
+
dependency_count: dependencies.length,
|
|
502
506
|
status: 'orchestrating',
|
|
503
507
|
assignedAgent: task.assignedAgent,
|
|
504
|
-
message: 'Task orchestration initiated',
|
|
508
|
+
message: 'Task orchestration initiated with safe dependency handling',
|
|
505
509
|
}),
|
|
506
510
|
},
|
|
507
511
|
],
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "snow-flow",
|
|
3
|
-
"version": "4.5.
|
|
3
|
+
"version": "4.5.31",
|
|
4
4
|
"description": "Conversational ServiceNow development platform using Claude Code. Multi-agent orchestration with 20+ MCP servers providing 200+ ServiceNow tools for comprehensive platform development.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"type": "commonjs",
|