@rudderhq/cli 0.4.6-canary.1 → 0.4.6-canary.3
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/index.js +360 -341
- package/dist/index.js.map +3 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1207,230 +1207,300 @@ var init_organization_intelligence_profile = __esm({
|
|
|
1207
1207
|
}
|
|
1208
1208
|
});
|
|
1209
1209
|
|
|
1210
|
-
// ../packages/shared/dist/
|
|
1210
|
+
// ../packages/shared/dist/organization-issue-key.js
|
|
1211
|
+
var ORGANIZATION_ISSUE_KEY_MAX_LENGTH, ORGANIZATION_ISSUE_KEY_PATTERN;
|
|
1212
|
+
var init_organization_issue_key = __esm({
|
|
1213
|
+
"../packages/shared/dist/organization-issue-key.js"() {
|
|
1214
|
+
"use strict";
|
|
1215
|
+
ORGANIZATION_ISSUE_KEY_MAX_LENGTH = 12;
|
|
1216
|
+
ORGANIZATION_ISSUE_KEY_PATTERN = /^[A-Z][A-Z0-9]*$/;
|
|
1217
|
+
}
|
|
1218
|
+
});
|
|
1219
|
+
|
|
1220
|
+
// ../packages/shared/dist/validators/organization.js
|
|
1211
1221
|
import { z as z9 } from "zod";
|
|
1222
|
+
var logoAssetIdSchema, brandColorSchema, organizationIssueKeySchema, createOrganizationSchema, updateOrganizationSchema, updateOrganizationBrandingSchema, updateOrganizationWorkspaceFileSchema, createOrganizationWorkspaceFileSchema, createOrganizationWorkspaceDirectorySchema, renameOrganizationWorkspaceEntrySchema, moveOrganizationWorkspaceEntrySchema, copyOrganizationWorkspaceEntrySchema;
|
|
1223
|
+
var init_organization = __esm({
|
|
1224
|
+
"../packages/shared/dist/validators/organization.js"() {
|
|
1225
|
+
"use strict";
|
|
1226
|
+
init_constants();
|
|
1227
|
+
init_organization_issue_key();
|
|
1228
|
+
logoAssetIdSchema = z9.string().uuid().nullable().optional();
|
|
1229
|
+
brandColorSchema = z9.string().regex(/^#[0-9a-fA-F]{6}$/).nullable().optional();
|
|
1230
|
+
organizationIssueKeySchema = z9.string().trim().min(1).max(ORGANIZATION_ISSUE_KEY_MAX_LENGTH).transform((value) => value.toUpperCase()).refine((value) => ORGANIZATION_ISSUE_KEY_PATTERN.test(value), {
|
|
1231
|
+
message: "Issue key must start with a letter and contain only letters and numbers"
|
|
1232
|
+
});
|
|
1233
|
+
createOrganizationSchema = z9.object({
|
|
1234
|
+
name: z9.string().min(1),
|
|
1235
|
+
issuePrefix: organizationIssueKeySchema.optional(),
|
|
1236
|
+
description: z9.string().optional().nullable(),
|
|
1237
|
+
budgetMonthlyCents: z9.number().int().nonnegative().optional().default(0),
|
|
1238
|
+
defaultChatIssueCreationMode: z9.enum(CHAT_ISSUE_CREATION_MODES).optional().default("manual_approval"),
|
|
1239
|
+
brandColor: brandColorSchema,
|
|
1240
|
+
requireBoardApprovalForNewAgents: z9.boolean().optional()
|
|
1241
|
+
});
|
|
1242
|
+
updateOrganizationSchema = createOrganizationSchema.partial().extend({
|
|
1243
|
+
status: z9.enum(ORGANIZATION_STATUSES).optional(),
|
|
1244
|
+
spentMonthlyCents: z9.number().int().nonnegative().optional(),
|
|
1245
|
+
requireBoardApprovalForNewAgents: z9.boolean().optional(),
|
|
1246
|
+
defaultChatIssueCreationMode: z9.enum(CHAT_ISSUE_CREATION_MODES).optional(),
|
|
1247
|
+
brandColor: brandColorSchema,
|
|
1248
|
+
logoAssetId: logoAssetIdSchema
|
|
1249
|
+
});
|
|
1250
|
+
updateOrganizationBrandingSchema = z9.object({
|
|
1251
|
+
name: z9.string().min(1).optional(),
|
|
1252
|
+
description: z9.string().nullable().optional(),
|
|
1253
|
+
brandColor: brandColorSchema,
|
|
1254
|
+
logoAssetId: logoAssetIdSchema
|
|
1255
|
+
}).strict().refine((value) => value.name !== void 0 || value.description !== void 0 || value.brandColor !== void 0 || value.logoAssetId !== void 0, "At least one branding field must be provided");
|
|
1256
|
+
updateOrganizationWorkspaceFileSchema = z9.object({
|
|
1257
|
+
content: z9.string()
|
|
1258
|
+
});
|
|
1259
|
+
createOrganizationWorkspaceFileSchema = z9.object({
|
|
1260
|
+
filePath: z9.string().trim().min(1).max(1e3),
|
|
1261
|
+
content: z9.string().optional().default("")
|
|
1262
|
+
});
|
|
1263
|
+
createOrganizationWorkspaceDirectorySchema = z9.object({
|
|
1264
|
+
directoryPath: z9.string().trim().min(1).max(1e3)
|
|
1265
|
+
});
|
|
1266
|
+
renameOrganizationWorkspaceEntrySchema = z9.object({
|
|
1267
|
+
name: z9.string().trim().min(1).max(255)
|
|
1268
|
+
});
|
|
1269
|
+
moveOrganizationWorkspaceEntrySchema = z9.object({
|
|
1270
|
+
destinationDirectoryPath: z9.string().trim().max(1e3).default("")
|
|
1271
|
+
});
|
|
1272
|
+
copyOrganizationWorkspaceEntrySchema = z9.object({
|
|
1273
|
+
destinationDirectoryPath: z9.string().trim().max(1e3).optional()
|
|
1274
|
+
});
|
|
1275
|
+
}
|
|
1276
|
+
});
|
|
1277
|
+
|
|
1278
|
+
// ../packages/shared/dist/validators/organization-portability.js
|
|
1279
|
+
import { z as z10 } from "zod";
|
|
1212
1280
|
var portabilityIncludeSchema, portabilityEnvInputSchema, portabilityFileEntrySchema, portabilityOrganizationManifestEntrySchema, portabilitySidebarOrderSchema, portabilityAgentManifestEntrySchema, portabilitySkillManifestEntrySchema, portabilityProjectManifestEntrySchema, portabilityIssueAutomationTriggerManifestEntrySchema, portabilityIssueAutomationManifestEntrySchema, portabilityIssueManifestEntrySchema, portabilityManifestSchema, portabilitySourceSchema, portabilityTargetSchema, portabilityAgentSelectionSchema, portabilityCollisionStrategySchema, organizationPortabilityExportSchema, organizationPortabilityPreviewSchema, portabilityAdapterOverrideSchema, organizationPortabilityImportSchema;
|
|
1213
1281
|
var init_organization_portability = __esm({
|
|
1214
1282
|
"../packages/shared/dist/validators/organization-portability.js"() {
|
|
1215
1283
|
"use strict";
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1284
|
+
init_organization();
|
|
1285
|
+
portabilityIncludeSchema = z10.object({
|
|
1286
|
+
organization: z10.boolean().optional(),
|
|
1287
|
+
agents: z10.boolean().optional(),
|
|
1288
|
+
projects: z10.boolean().optional(),
|
|
1289
|
+
issues: z10.boolean().optional(),
|
|
1290
|
+
skills: z10.boolean().optional()
|
|
1222
1291
|
}).partial();
|
|
1223
|
-
portabilityEnvInputSchema =
|
|
1224
|
-
key:
|
|
1225
|
-
description:
|
|
1226
|
-
agentSlug:
|
|
1227
|
-
kind:
|
|
1228
|
-
requirement:
|
|
1229
|
-
defaultValue:
|
|
1230
|
-
portability:
|
|
1292
|
+
portabilityEnvInputSchema = z10.object({
|
|
1293
|
+
key: z10.string().min(1),
|
|
1294
|
+
description: z10.string().nullable(),
|
|
1295
|
+
agentSlug: z10.string().min(1).nullable(),
|
|
1296
|
+
kind: z10.enum(["secret", "plain"]),
|
|
1297
|
+
requirement: z10.enum(["required", "optional"]),
|
|
1298
|
+
defaultValue: z10.string().nullable(),
|
|
1299
|
+
portability: z10.enum(["portable", "system_dependent"])
|
|
1231
1300
|
});
|
|
1232
|
-
portabilityFileEntrySchema =
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
encoding:
|
|
1236
|
-
data:
|
|
1237
|
-
contentType:
|
|
1301
|
+
portabilityFileEntrySchema = z10.union([
|
|
1302
|
+
z10.string(),
|
|
1303
|
+
z10.object({
|
|
1304
|
+
encoding: z10.literal("base64"),
|
|
1305
|
+
data: z10.string(),
|
|
1306
|
+
contentType: z10.string().min(1).optional().nullable()
|
|
1238
1307
|
})
|
|
1239
1308
|
]);
|
|
1240
|
-
portabilityOrganizationManifestEntrySchema =
|
|
1241
|
-
path:
|
|
1242
|
-
name:
|
|
1243
|
-
description:
|
|
1244
|
-
brandColor:
|
|
1245
|
-
logoPath:
|
|
1246
|
-
requireBoardApprovalForNewAgents:
|
|
1309
|
+
portabilityOrganizationManifestEntrySchema = z10.object({
|
|
1310
|
+
path: z10.string().min(1),
|
|
1311
|
+
name: z10.string().min(1),
|
|
1312
|
+
description: z10.string().nullable(),
|
|
1313
|
+
brandColor: z10.string().nullable(),
|
|
1314
|
+
logoPath: z10.string().nullable(),
|
|
1315
|
+
requireBoardApprovalForNewAgents: z10.boolean()
|
|
1247
1316
|
});
|
|
1248
|
-
portabilitySidebarOrderSchema =
|
|
1249
|
-
agents:
|
|
1250
|
-
projects:
|
|
1317
|
+
portabilitySidebarOrderSchema = z10.object({
|
|
1318
|
+
agents: z10.array(z10.string().min(1)).default([]),
|
|
1319
|
+
projects: z10.array(z10.string().min(1)).default([])
|
|
1251
1320
|
});
|
|
1252
|
-
portabilityAgentManifestEntrySchema =
|
|
1253
|
-
slug:
|
|
1254
|
-
name:
|
|
1255
|
-
path:
|
|
1256
|
-
skills:
|
|
1257
|
-
role:
|
|
1258
|
-
title:
|
|
1259
|
-
icon:
|
|
1260
|
-
capabilities:
|
|
1261
|
-
reportsToSlug:
|
|
1262
|
-
agentRuntimeType:
|
|
1263
|
-
agentRuntimeConfig:
|
|
1264
|
-
runtimeConfig:
|
|
1265
|
-
permissions:
|
|
1266
|
-
budgetMonthlyCents:
|
|
1267
|
-
metadata:
|
|
1321
|
+
portabilityAgentManifestEntrySchema = z10.object({
|
|
1322
|
+
slug: z10.string().min(1),
|
|
1323
|
+
name: z10.string().min(1),
|
|
1324
|
+
path: z10.string().min(1),
|
|
1325
|
+
skills: z10.array(z10.string().min(1)).default([]),
|
|
1326
|
+
role: z10.string().min(1),
|
|
1327
|
+
title: z10.string().nullable(),
|
|
1328
|
+
icon: z10.string().nullable(),
|
|
1329
|
+
capabilities: z10.string().nullable(),
|
|
1330
|
+
reportsToSlug: z10.string().min(1).nullable(),
|
|
1331
|
+
agentRuntimeType: z10.string().min(1),
|
|
1332
|
+
agentRuntimeConfig: z10.record(z10.unknown()),
|
|
1333
|
+
runtimeConfig: z10.record(z10.unknown()),
|
|
1334
|
+
permissions: z10.record(z10.unknown()),
|
|
1335
|
+
budgetMonthlyCents: z10.number().int().nonnegative(),
|
|
1336
|
+
metadata: z10.record(z10.unknown()).nullable()
|
|
1268
1337
|
});
|
|
1269
|
-
portabilitySkillManifestEntrySchema =
|
|
1270
|
-
key:
|
|
1271
|
-
slug:
|
|
1272
|
-
name:
|
|
1273
|
-
path:
|
|
1274
|
-
description:
|
|
1275
|
-
sourceType:
|
|
1276
|
-
sourceLocator:
|
|
1277
|
-
sourceRef:
|
|
1278
|
-
trustLevel:
|
|
1279
|
-
compatibility:
|
|
1280
|
-
metadata:
|
|
1281
|
-
fileInventory:
|
|
1282
|
-
path:
|
|
1283
|
-
kind:
|
|
1338
|
+
portabilitySkillManifestEntrySchema = z10.object({
|
|
1339
|
+
key: z10.string().min(1),
|
|
1340
|
+
slug: z10.string().min(1),
|
|
1341
|
+
name: z10.string().min(1),
|
|
1342
|
+
path: z10.string().min(1),
|
|
1343
|
+
description: z10.string().nullable(),
|
|
1344
|
+
sourceType: z10.string().min(1),
|
|
1345
|
+
sourceLocator: z10.string().nullable(),
|
|
1346
|
+
sourceRef: z10.string().nullable(),
|
|
1347
|
+
trustLevel: z10.string().nullable(),
|
|
1348
|
+
compatibility: z10.string().nullable(),
|
|
1349
|
+
metadata: z10.record(z10.unknown()).nullable(),
|
|
1350
|
+
fileInventory: z10.array(z10.object({
|
|
1351
|
+
path: z10.string().min(1),
|
|
1352
|
+
kind: z10.string().min(1)
|
|
1284
1353
|
})).default([])
|
|
1285
1354
|
});
|
|
1286
|
-
portabilityProjectManifestEntrySchema =
|
|
1287
|
-
slug:
|
|
1288
|
-
name:
|
|
1289
|
-
path:
|
|
1290
|
-
description:
|
|
1291
|
-
ownerAgentSlug:
|
|
1292
|
-
leadAgentSlug:
|
|
1293
|
-
targetDate:
|
|
1294
|
-
color:
|
|
1295
|
-
status:
|
|
1296
|
-
executionWorkspacePolicy:
|
|
1297
|
-
workspaces:
|
|
1298
|
-
key:
|
|
1299
|
-
name:
|
|
1300
|
-
sourceType:
|
|
1301
|
-
repoUrl:
|
|
1302
|
-
repoRef:
|
|
1303
|
-
defaultRef:
|
|
1304
|
-
visibility:
|
|
1305
|
-
setupCommand:
|
|
1306
|
-
cleanupCommand:
|
|
1307
|
-
metadata:
|
|
1308
|
-
isPrimary:
|
|
1355
|
+
portabilityProjectManifestEntrySchema = z10.object({
|
|
1356
|
+
slug: z10.string().min(1),
|
|
1357
|
+
name: z10.string().min(1),
|
|
1358
|
+
path: z10.string().min(1),
|
|
1359
|
+
description: z10.string().nullable(),
|
|
1360
|
+
ownerAgentSlug: z10.string().min(1).nullable(),
|
|
1361
|
+
leadAgentSlug: z10.string().min(1).nullable(),
|
|
1362
|
+
targetDate: z10.string().nullable(),
|
|
1363
|
+
color: z10.string().nullable(),
|
|
1364
|
+
status: z10.string().nullable(),
|
|
1365
|
+
executionWorkspacePolicy: z10.record(z10.unknown()).nullable(),
|
|
1366
|
+
workspaces: z10.array(z10.object({
|
|
1367
|
+
key: z10.string().min(1),
|
|
1368
|
+
name: z10.string().min(1),
|
|
1369
|
+
sourceType: z10.string().nullable(),
|
|
1370
|
+
repoUrl: z10.string().nullable(),
|
|
1371
|
+
repoRef: z10.string().nullable(),
|
|
1372
|
+
defaultRef: z10.string().nullable(),
|
|
1373
|
+
visibility: z10.string().nullable(),
|
|
1374
|
+
setupCommand: z10.string().nullable(),
|
|
1375
|
+
cleanupCommand: z10.string().nullable(),
|
|
1376
|
+
metadata: z10.record(z10.unknown()).nullable(),
|
|
1377
|
+
isPrimary: z10.boolean()
|
|
1309
1378
|
})).default([]),
|
|
1310
|
-
metadata:
|
|
1379
|
+
metadata: z10.record(z10.unknown()).nullable()
|
|
1311
1380
|
});
|
|
1312
|
-
portabilityIssueAutomationTriggerManifestEntrySchema =
|
|
1313
|
-
kind:
|
|
1314
|
-
label:
|
|
1315
|
-
enabled:
|
|
1316
|
-
cronExpression:
|
|
1317
|
-
timezone:
|
|
1318
|
-
signingMode:
|
|
1319
|
-
replayWindowSec:
|
|
1381
|
+
portabilityIssueAutomationTriggerManifestEntrySchema = z10.object({
|
|
1382
|
+
kind: z10.string().min(1),
|
|
1383
|
+
label: z10.string().nullable(),
|
|
1384
|
+
enabled: z10.boolean(),
|
|
1385
|
+
cronExpression: z10.string().nullable(),
|
|
1386
|
+
timezone: z10.string().nullable(),
|
|
1387
|
+
signingMode: z10.string().nullable(),
|
|
1388
|
+
replayWindowSec: z10.number().int().nullable()
|
|
1320
1389
|
});
|
|
1321
|
-
portabilityIssueAutomationManifestEntrySchema =
|
|
1322
|
-
concurrencyPolicy:
|
|
1323
|
-
catchUpPolicy:
|
|
1324
|
-
triggers:
|
|
1390
|
+
portabilityIssueAutomationManifestEntrySchema = z10.object({
|
|
1391
|
+
concurrencyPolicy: z10.string().nullable(),
|
|
1392
|
+
catchUpPolicy: z10.string().nullable(),
|
|
1393
|
+
triggers: z10.array(portabilityIssueAutomationTriggerManifestEntrySchema).default([])
|
|
1325
1394
|
});
|
|
1326
|
-
portabilityIssueManifestEntrySchema =
|
|
1327
|
-
slug:
|
|
1328
|
-
identifier:
|
|
1329
|
-
title:
|
|
1330
|
-
path:
|
|
1331
|
-
projectSlug:
|
|
1332
|
-
projectWorkspaceKey:
|
|
1333
|
-
assigneeAgentSlug:
|
|
1334
|
-
description:
|
|
1335
|
-
recurring:
|
|
1395
|
+
portabilityIssueManifestEntrySchema = z10.object({
|
|
1396
|
+
slug: z10.string().min(1),
|
|
1397
|
+
identifier: z10.string().min(1).nullable(),
|
|
1398
|
+
title: z10.string().min(1),
|
|
1399
|
+
path: z10.string().min(1),
|
|
1400
|
+
projectSlug: z10.string().min(1).nullable(),
|
|
1401
|
+
projectWorkspaceKey: z10.string().min(1).nullable(),
|
|
1402
|
+
assigneeAgentSlug: z10.string().min(1).nullable(),
|
|
1403
|
+
description: z10.string().nullable(),
|
|
1404
|
+
recurring: z10.boolean().default(false),
|
|
1336
1405
|
automation: portabilityIssueAutomationManifestEntrySchema.nullable(),
|
|
1337
|
-
legacyRecurrence:
|
|
1338
|
-
status:
|
|
1339
|
-
priority:
|
|
1340
|
-
labelIds:
|
|
1341
|
-
billingCode:
|
|
1342
|
-
executionWorkspaceSettings:
|
|
1343
|
-
assigneeAgentRuntimeOverrides:
|
|
1344
|
-
metadata:
|
|
1406
|
+
legacyRecurrence: z10.record(z10.unknown()).nullable(),
|
|
1407
|
+
status: z10.string().nullable(),
|
|
1408
|
+
priority: z10.string().nullable(),
|
|
1409
|
+
labelIds: z10.array(z10.string().min(1)).default([]),
|
|
1410
|
+
billingCode: z10.string().nullable(),
|
|
1411
|
+
executionWorkspaceSettings: z10.record(z10.unknown()).nullable(),
|
|
1412
|
+
assigneeAgentRuntimeOverrides: z10.record(z10.unknown()).nullable(),
|
|
1413
|
+
metadata: z10.record(z10.unknown()).nullable()
|
|
1345
1414
|
});
|
|
1346
|
-
portabilityManifestSchema =
|
|
1347
|
-
schemaVersion:
|
|
1348
|
-
generatedAt:
|
|
1349
|
-
source:
|
|
1350
|
-
orgId:
|
|
1351
|
-
organizationName:
|
|
1415
|
+
portabilityManifestSchema = z10.object({
|
|
1416
|
+
schemaVersion: z10.number().int().positive(),
|
|
1417
|
+
generatedAt: z10.string().datetime(),
|
|
1418
|
+
source: z10.object({
|
|
1419
|
+
orgId: z10.string().uuid(),
|
|
1420
|
+
organizationName: z10.string().min(1)
|
|
1352
1421
|
}).nullable(),
|
|
1353
|
-
includes:
|
|
1354
|
-
organization:
|
|
1355
|
-
agents:
|
|
1356
|
-
projects:
|
|
1357
|
-
issues:
|
|
1358
|
-
skills:
|
|
1422
|
+
includes: z10.object({
|
|
1423
|
+
organization: z10.boolean(),
|
|
1424
|
+
agents: z10.boolean(),
|
|
1425
|
+
projects: z10.boolean(),
|
|
1426
|
+
issues: z10.boolean(),
|
|
1427
|
+
skills: z10.boolean()
|
|
1359
1428
|
}),
|
|
1360
1429
|
organization: portabilityOrganizationManifestEntrySchema.nullable(),
|
|
1361
1430
|
sidebar: portabilitySidebarOrderSchema.nullable(),
|
|
1362
|
-
agents:
|
|
1363
|
-
skills:
|
|
1364
|
-
projects:
|
|
1365
|
-
issues:
|
|
1366
|
-
envInputs:
|
|
1431
|
+
agents: z10.array(portabilityAgentManifestEntrySchema),
|
|
1432
|
+
skills: z10.array(portabilitySkillManifestEntrySchema).default([]),
|
|
1433
|
+
projects: z10.array(portabilityProjectManifestEntrySchema).default([]),
|
|
1434
|
+
issues: z10.array(portabilityIssueManifestEntrySchema).default([]),
|
|
1435
|
+
envInputs: z10.array(portabilityEnvInputSchema).default([])
|
|
1367
1436
|
});
|
|
1368
|
-
portabilitySourceSchema =
|
|
1369
|
-
|
|
1370
|
-
type:
|
|
1371
|
-
rootPath:
|
|
1372
|
-
files:
|
|
1437
|
+
portabilitySourceSchema = z10.discriminatedUnion("type", [
|
|
1438
|
+
z10.object({
|
|
1439
|
+
type: z10.literal("inline"),
|
|
1440
|
+
rootPath: z10.string().min(1).optional().nullable(),
|
|
1441
|
+
files: z10.record(portabilityFileEntrySchema)
|
|
1373
1442
|
}),
|
|
1374
|
-
|
|
1375
|
-
type:
|
|
1376
|
-
url:
|
|
1443
|
+
z10.object({
|
|
1444
|
+
type: z10.literal("github"),
|
|
1445
|
+
url: z10.string().url()
|
|
1377
1446
|
})
|
|
1378
1447
|
]);
|
|
1379
|
-
portabilityTargetSchema =
|
|
1380
|
-
|
|
1381
|
-
mode:
|
|
1382
|
-
newOrganizationName:
|
|
1448
|
+
portabilityTargetSchema = z10.discriminatedUnion("mode", [
|
|
1449
|
+
z10.object({
|
|
1450
|
+
mode: z10.literal("new_organization"),
|
|
1451
|
+
newOrganizationName: z10.string().min(1).optional().nullable(),
|
|
1452
|
+
newOrganizationIssueKey: organizationIssueKeySchema.optional().nullable()
|
|
1383
1453
|
}),
|
|
1384
|
-
|
|
1385
|
-
mode:
|
|
1386
|
-
orgId:
|
|
1454
|
+
z10.object({
|
|
1455
|
+
mode: z10.literal("existing_organization"),
|
|
1456
|
+
orgId: z10.string().uuid()
|
|
1387
1457
|
})
|
|
1388
1458
|
]);
|
|
1389
|
-
portabilityAgentSelectionSchema =
|
|
1390
|
-
|
|
1391
|
-
|
|
1459
|
+
portabilityAgentSelectionSchema = z10.union([
|
|
1460
|
+
z10.literal("all"),
|
|
1461
|
+
z10.array(z10.string().min(1))
|
|
1392
1462
|
]);
|
|
1393
|
-
portabilityCollisionStrategySchema =
|
|
1394
|
-
organizationPortabilityExportSchema =
|
|
1463
|
+
portabilityCollisionStrategySchema = z10.enum(["rename", "skip", "replace"]);
|
|
1464
|
+
organizationPortabilityExportSchema = z10.object({
|
|
1395
1465
|
include: portabilityIncludeSchema.optional(),
|
|
1396
|
-
agents:
|
|
1397
|
-
skills:
|
|
1398
|
-
projects:
|
|
1399
|
-
issues:
|
|
1400
|
-
projectIssues:
|
|
1401
|
-
selectedFiles:
|
|
1402
|
-
expandReferencedSkills:
|
|
1466
|
+
agents: z10.array(z10.string().min(1)).optional(),
|
|
1467
|
+
skills: z10.array(z10.string().min(1)).optional(),
|
|
1468
|
+
projects: z10.array(z10.string().min(1)).optional(),
|
|
1469
|
+
issues: z10.array(z10.string().min(1)).optional(),
|
|
1470
|
+
projectIssues: z10.array(z10.string().min(1)).optional(),
|
|
1471
|
+
selectedFiles: z10.array(z10.string().min(1)).optional(),
|
|
1472
|
+
expandReferencedSkills: z10.boolean().optional(),
|
|
1403
1473
|
sidebarOrder: portabilitySidebarOrderSchema.partial().optional()
|
|
1404
1474
|
});
|
|
1405
|
-
organizationPortabilityPreviewSchema =
|
|
1475
|
+
organizationPortabilityPreviewSchema = z10.object({
|
|
1406
1476
|
source: portabilitySourceSchema,
|
|
1407
1477
|
include: portabilityIncludeSchema.optional(),
|
|
1408
1478
|
target: portabilityTargetSchema,
|
|
1409
1479
|
agents: portabilityAgentSelectionSchema.optional(),
|
|
1410
1480
|
collisionStrategy: portabilityCollisionStrategySchema.optional(),
|
|
1411
|
-
nameOverrides:
|
|
1412
|
-
selectedFiles:
|
|
1481
|
+
nameOverrides: z10.record(z10.string().min(1), z10.string().min(1)).optional(),
|
|
1482
|
+
selectedFiles: z10.array(z10.string().min(1)).optional()
|
|
1413
1483
|
});
|
|
1414
|
-
portabilityAdapterOverrideSchema =
|
|
1415
|
-
agentRuntimeType:
|
|
1416
|
-
agentRuntimeConfig:
|
|
1484
|
+
portabilityAdapterOverrideSchema = z10.object({
|
|
1485
|
+
agentRuntimeType: z10.string().min(1),
|
|
1486
|
+
agentRuntimeConfig: z10.record(z10.unknown()).optional()
|
|
1417
1487
|
});
|
|
1418
1488
|
organizationPortabilityImportSchema = organizationPortabilityPreviewSchema.extend({
|
|
1419
|
-
agentRuntimeOverrides:
|
|
1489
|
+
agentRuntimeOverrides: z10.record(z10.string().min(1), portabilityAdapterOverrideSchema).optional()
|
|
1420
1490
|
});
|
|
1421
1491
|
}
|
|
1422
1492
|
});
|
|
1423
1493
|
|
|
1424
1494
|
// ../packages/shared/dist/validators/organization-skill.js
|
|
1425
|
-
import { z as
|
|
1495
|
+
import { z as z11 } from "zod";
|
|
1426
1496
|
var organizationSkillSourceTypeSchema, organizationSkillTrustLevelSchema, organizationSkillCompatibilitySchema, organizationSkillSourceBadgeSchema, organizationSkillFileInventoryEntrySchema, organizationSkillSchema, organizationSkillListItemSchema, organizationSkillUsageAgentSchema, organizationSkillDetailSchema, organizationSkillUpdateStatusSchema, organizationSkillImportSchema, organizationSkillProjectScanRequestSchema, organizationSkillProjectScanSkippedSchema, organizationSkillProjectScanConflictSchema, organizationSkillProjectScanResultSchema, organizationSkillLocalScanRequestSchema, organizationSkillLocalScanSkippedSchema, organizationSkillLocalScanConflictSchema, organizationSkillLocalScanResultSchema, organizationSkillCreateSchema, organizationSkillFileDetailSchema, organizationSkillFileUpdateSchema;
|
|
1427
1497
|
var init_organization_skill = __esm({
|
|
1428
1498
|
"../packages/shared/dist/validators/organization-skill.js"() {
|
|
1429
1499
|
"use strict";
|
|
1430
|
-
organizationSkillSourceTypeSchema =
|
|
1431
|
-
organizationSkillTrustLevelSchema =
|
|
1432
|
-
organizationSkillCompatibilitySchema =
|
|
1433
|
-
organizationSkillSourceBadgeSchema =
|
|
1500
|
+
organizationSkillSourceTypeSchema = z11.enum(["local_path", "github", "url", "catalog", "skills_sh"]);
|
|
1501
|
+
organizationSkillTrustLevelSchema = z11.enum(["markdown_only", "assets", "scripts_executables"]);
|
|
1502
|
+
organizationSkillCompatibilitySchema = z11.enum(["compatible", "unknown", "invalid"]);
|
|
1503
|
+
organizationSkillSourceBadgeSchema = z11.enum([
|
|
1434
1504
|
"rudder",
|
|
1435
1505
|
"community",
|
|
1436
1506
|
"github",
|
|
@@ -1439,199 +1509,146 @@ var init_organization_skill = __esm({
|
|
|
1439
1509
|
"catalog",
|
|
1440
1510
|
"skills_sh"
|
|
1441
1511
|
]);
|
|
1442
|
-
organizationSkillFileInventoryEntrySchema =
|
|
1443
|
-
path:
|
|
1444
|
-
kind:
|
|
1512
|
+
organizationSkillFileInventoryEntrySchema = z11.object({
|
|
1513
|
+
path: z11.string().min(1),
|
|
1514
|
+
kind: z11.enum(["skill", "markdown", "reference", "script", "asset", "other"])
|
|
1445
1515
|
});
|
|
1446
|
-
organizationSkillSchema =
|
|
1447
|
-
id:
|
|
1448
|
-
orgId:
|
|
1449
|
-
key:
|
|
1450
|
-
slug:
|
|
1451
|
-
name:
|
|
1452
|
-
description:
|
|
1453
|
-
markdown:
|
|
1516
|
+
organizationSkillSchema = z11.object({
|
|
1517
|
+
id: z11.string().uuid(),
|
|
1518
|
+
orgId: z11.string().uuid(),
|
|
1519
|
+
key: z11.string().min(1),
|
|
1520
|
+
slug: z11.string().min(1),
|
|
1521
|
+
name: z11.string().min(1),
|
|
1522
|
+
description: z11.string().nullable(),
|
|
1523
|
+
markdown: z11.string(),
|
|
1454
1524
|
sourceType: organizationSkillSourceTypeSchema,
|
|
1455
|
-
sourceLocator:
|
|
1456
|
-
sourceRef:
|
|
1525
|
+
sourceLocator: z11.string().nullable(),
|
|
1526
|
+
sourceRef: z11.string().nullable(),
|
|
1457
1527
|
trustLevel: organizationSkillTrustLevelSchema,
|
|
1458
1528
|
compatibility: organizationSkillCompatibilitySchema,
|
|
1459
|
-
fileInventory:
|
|
1460
|
-
metadata:
|
|
1461
|
-
createdAt:
|
|
1462
|
-
updatedAt:
|
|
1529
|
+
fileInventory: z11.array(organizationSkillFileInventoryEntrySchema).default([]),
|
|
1530
|
+
metadata: z11.record(z11.unknown()).nullable(),
|
|
1531
|
+
createdAt: z11.coerce.date(),
|
|
1532
|
+
updatedAt: z11.coerce.date()
|
|
1463
1533
|
});
|
|
1464
1534
|
organizationSkillListItemSchema = organizationSkillSchema.extend({
|
|
1465
|
-
attachedAgentCount:
|
|
1466
|
-
editable:
|
|
1467
|
-
editableReason:
|
|
1468
|
-
sourceLabel:
|
|
1535
|
+
attachedAgentCount: z11.number().int().nonnegative(),
|
|
1536
|
+
editable: z11.boolean(),
|
|
1537
|
+
editableReason: z11.string().nullable(),
|
|
1538
|
+
sourceLabel: z11.string().nullable(),
|
|
1469
1539
|
sourceBadge: organizationSkillSourceBadgeSchema,
|
|
1470
|
-
sourcePath:
|
|
1471
|
-
workspaceEditPath:
|
|
1540
|
+
sourcePath: z11.string().nullable(),
|
|
1541
|
+
workspaceEditPath: z11.string().nullable()
|
|
1472
1542
|
});
|
|
1473
|
-
organizationSkillUsageAgentSchema =
|
|
1474
|
-
id:
|
|
1475
|
-
name:
|
|
1476
|
-
urlKey:
|
|
1477
|
-
agentRuntimeType:
|
|
1478
|
-
desired:
|
|
1479
|
-
actualState:
|
|
1543
|
+
organizationSkillUsageAgentSchema = z11.object({
|
|
1544
|
+
id: z11.string().uuid(),
|
|
1545
|
+
name: z11.string().min(1),
|
|
1546
|
+
urlKey: z11.string().min(1),
|
|
1547
|
+
agentRuntimeType: z11.string().min(1),
|
|
1548
|
+
desired: z11.boolean(),
|
|
1549
|
+
actualState: z11.string().nullable()
|
|
1480
1550
|
});
|
|
1481
1551
|
organizationSkillDetailSchema = organizationSkillSchema.extend({
|
|
1482
|
-
attachedAgentCount:
|
|
1483
|
-
usedByAgents:
|
|
1484
|
-
editable:
|
|
1485
|
-
editableReason:
|
|
1486
|
-
sourceLabel:
|
|
1552
|
+
attachedAgentCount: z11.number().int().nonnegative(),
|
|
1553
|
+
usedByAgents: z11.array(organizationSkillUsageAgentSchema).default([]),
|
|
1554
|
+
editable: z11.boolean(),
|
|
1555
|
+
editableReason: z11.string().nullable(),
|
|
1556
|
+
sourceLabel: z11.string().nullable(),
|
|
1487
1557
|
sourceBadge: organizationSkillSourceBadgeSchema,
|
|
1488
|
-
sourcePath:
|
|
1489
|
-
workspaceEditPath:
|
|
1490
|
-
});
|
|
1491
|
-
organizationSkillUpdateStatusSchema = z10.object({
|
|
1492
|
-
supported: z10.boolean(),
|
|
1493
|
-
reason: z10.string().nullable(),
|
|
1494
|
-
trackingRef: z10.string().nullable(),
|
|
1495
|
-
currentRef: z10.string().nullable(),
|
|
1496
|
-
latestRef: z10.string().nullable(),
|
|
1497
|
-
hasUpdate: z10.boolean()
|
|
1558
|
+
sourcePath: z11.string().nullable(),
|
|
1559
|
+
workspaceEditPath: z11.string().nullable()
|
|
1498
1560
|
});
|
|
1499
|
-
|
|
1500
|
-
|
|
1561
|
+
organizationSkillUpdateStatusSchema = z11.object({
|
|
1562
|
+
supported: z11.boolean(),
|
|
1563
|
+
reason: z11.string().nullable(),
|
|
1564
|
+
trackingRef: z11.string().nullable(),
|
|
1565
|
+
currentRef: z11.string().nullable(),
|
|
1566
|
+
latestRef: z11.string().nullable(),
|
|
1567
|
+
hasUpdate: z11.boolean()
|
|
1501
1568
|
});
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
workspaceIds: z10.array(z10.string().uuid()).optional()
|
|
1569
|
+
organizationSkillImportSchema = z11.object({
|
|
1570
|
+
source: z11.string().min(1)
|
|
1505
1571
|
});
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
workspaceId: z10.string().uuid().nullable(),
|
|
1510
|
-
workspaceName: z10.string().nullable(),
|
|
1511
|
-
path: z10.string().nullable(),
|
|
1512
|
-
reason: z10.string().min(1)
|
|
1572
|
+
organizationSkillProjectScanRequestSchema = z11.object({
|
|
1573
|
+
projectIds: z11.array(z11.string().uuid()).optional(),
|
|
1574
|
+
workspaceIds: z11.array(z11.string().uuid()).optional()
|
|
1513
1575
|
});
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
path: z10.string().min(1),
|
|
1522
|
-
existingSkillId: z10.string().uuid(),
|
|
1523
|
-
existingSkillKey: z10.string().min(1),
|
|
1524
|
-
existingSourceLocator: z10.string().nullable(),
|
|
1525
|
-
reason: z10.string().min(1)
|
|
1576
|
+
organizationSkillProjectScanSkippedSchema = z11.object({
|
|
1577
|
+
projectId: z11.string().uuid(),
|
|
1578
|
+
projectName: z11.string().min(1),
|
|
1579
|
+
workspaceId: z11.string().uuid().nullable(),
|
|
1580
|
+
workspaceName: z11.string().nullable(),
|
|
1581
|
+
path: z11.string().nullable(),
|
|
1582
|
+
reason: z11.string().min(1)
|
|
1526
1583
|
});
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1584
|
+
organizationSkillProjectScanConflictSchema = z11.object({
|
|
1585
|
+
slug: z11.string().min(1),
|
|
1586
|
+
key: z11.string().min(1),
|
|
1587
|
+
projectId: z11.string().uuid(),
|
|
1588
|
+
projectName: z11.string().min(1),
|
|
1589
|
+
workspaceId: z11.string().uuid(),
|
|
1590
|
+
workspaceName: z11.string().min(1),
|
|
1591
|
+
path: z11.string().min(1),
|
|
1592
|
+
existingSkillId: z11.string().uuid(),
|
|
1593
|
+
existingSkillKey: z11.string().min(1),
|
|
1594
|
+
existingSourceLocator: z11.string().nullable(),
|
|
1595
|
+
reason: z11.string().min(1)
|
|
1536
1596
|
});
|
|
1537
|
-
|
|
1538
|
-
|
|
1597
|
+
organizationSkillProjectScanResultSchema = z11.object({
|
|
1598
|
+
scannedProjects: z11.number().int().nonnegative(),
|
|
1599
|
+
scannedWorkspaces: z11.number().int().nonnegative(),
|
|
1600
|
+
discovered: z11.number().int().nonnegative(),
|
|
1601
|
+
imported: z11.array(organizationSkillSchema),
|
|
1602
|
+
updated: z11.array(organizationSkillSchema),
|
|
1603
|
+
skipped: z11.array(organizationSkillProjectScanSkippedSchema),
|
|
1604
|
+
conflicts: z11.array(organizationSkillProjectScanConflictSchema),
|
|
1605
|
+
warnings: z11.array(z11.string())
|
|
1539
1606
|
});
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
path: z10.string().nullable(),
|
|
1543
|
-
reason: z10.string().min(1)
|
|
1607
|
+
organizationSkillLocalScanRequestSchema = z11.object({
|
|
1608
|
+
roots: z11.array(z11.string().min(1)).optional()
|
|
1544
1609
|
});
|
|
1545
|
-
|
|
1546
|
-
root:
|
|
1547
|
-
path:
|
|
1548
|
-
|
|
1549
|
-
key: z10.string().min(1),
|
|
1550
|
-
existingSkillId: z10.string().uuid(),
|
|
1551
|
-
existingSkillKey: z10.string().min(1),
|
|
1552
|
-
existingSourceLocator: z10.string().nullable(),
|
|
1553
|
-
reason: z10.string().min(1)
|
|
1610
|
+
organizationSkillLocalScanSkippedSchema = z11.object({
|
|
1611
|
+
root: z11.string().min(1),
|
|
1612
|
+
path: z11.string().nullable(),
|
|
1613
|
+
reason: z11.string().min(1)
|
|
1554
1614
|
});
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1615
|
+
organizationSkillLocalScanConflictSchema = z11.object({
|
|
1616
|
+
root: z11.string().min(1),
|
|
1617
|
+
path: z11.string().min(1),
|
|
1618
|
+
slug: z11.string().min(1),
|
|
1619
|
+
key: z11.string().min(1),
|
|
1620
|
+
existingSkillId: z11.string().uuid(),
|
|
1621
|
+
existingSkillKey: z11.string().min(1),
|
|
1622
|
+
existingSourceLocator: z11.string().nullable(),
|
|
1623
|
+
reason: z11.string().min(1)
|
|
1563
1624
|
});
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1625
|
+
organizationSkillLocalScanResultSchema = z11.object({
|
|
1626
|
+
scannedRoots: z11.number().int().nonnegative(),
|
|
1627
|
+
discovered: z11.number().int().nonnegative(),
|
|
1628
|
+
imported: z11.array(organizationSkillSchema),
|
|
1629
|
+
updated: z11.array(organizationSkillSchema),
|
|
1630
|
+
skipped: z11.array(organizationSkillLocalScanSkippedSchema),
|
|
1631
|
+
conflicts: z11.array(organizationSkillLocalScanConflictSchema),
|
|
1632
|
+
warnings: z11.array(z11.string())
|
|
1569
1633
|
});
|
|
1570
|
-
|
|
1571
|
-
skillId: z10.string().uuid(),
|
|
1572
|
-
path: z10.string().min(1),
|
|
1573
|
-
kind: z10.enum(["skill", "markdown", "reference", "script", "asset", "other"]),
|
|
1574
|
-
content: z10.string(),
|
|
1575
|
-
language: z10.string().nullable(),
|
|
1576
|
-
markdown: z10.boolean(),
|
|
1577
|
-
editable: z10.boolean()
|
|
1578
|
-
});
|
|
1579
|
-
organizationSkillFileUpdateSchema = z10.object({
|
|
1580
|
-
path: z10.string().min(1),
|
|
1581
|
-
content: z10.string()
|
|
1582
|
-
});
|
|
1583
|
-
}
|
|
1584
|
-
});
|
|
1585
|
-
|
|
1586
|
-
// ../packages/shared/dist/validators/organization.js
|
|
1587
|
-
import { z as z11 } from "zod";
|
|
1588
|
-
var logoAssetIdSchema, brandColorSchema, createOrganizationSchema, updateOrganizationSchema, updateOrganizationBrandingSchema, updateOrganizationWorkspaceFileSchema, createOrganizationWorkspaceFileSchema, createOrganizationWorkspaceDirectorySchema, renameOrganizationWorkspaceEntrySchema, moveOrganizationWorkspaceEntrySchema, copyOrganizationWorkspaceEntrySchema;
|
|
1589
|
-
var init_organization = __esm({
|
|
1590
|
-
"../packages/shared/dist/validators/organization.js"() {
|
|
1591
|
-
"use strict";
|
|
1592
|
-
init_constants();
|
|
1593
|
-
logoAssetIdSchema = z11.string().uuid().nullable().optional();
|
|
1594
|
-
brandColorSchema = z11.string().regex(/^#[0-9a-fA-F]{6}$/).nullable().optional();
|
|
1595
|
-
createOrganizationSchema = z11.object({
|
|
1634
|
+
organizationSkillCreateSchema = z11.object({
|
|
1596
1635
|
name: z11.string().min(1),
|
|
1597
|
-
|
|
1598
|
-
budgetMonthlyCents: z11.number().int().nonnegative().optional().default(0),
|
|
1599
|
-
defaultChatIssueCreationMode: z11.enum(CHAT_ISSUE_CREATION_MODES).optional().default("manual_approval"),
|
|
1600
|
-
brandColor: brandColorSchema,
|
|
1601
|
-
requireBoardApprovalForNewAgents: z11.boolean().optional()
|
|
1602
|
-
});
|
|
1603
|
-
updateOrganizationSchema = createOrganizationSchema.partial().extend({
|
|
1604
|
-
status: z11.enum(ORGANIZATION_STATUSES).optional(),
|
|
1605
|
-
spentMonthlyCents: z11.number().int().nonnegative().optional(),
|
|
1606
|
-
requireBoardApprovalForNewAgents: z11.boolean().optional(),
|
|
1607
|
-
defaultChatIssueCreationMode: z11.enum(CHAT_ISSUE_CREATION_MODES).optional(),
|
|
1608
|
-
brandColor: brandColorSchema,
|
|
1609
|
-
logoAssetId: logoAssetIdSchema
|
|
1610
|
-
});
|
|
1611
|
-
updateOrganizationBrandingSchema = z11.object({
|
|
1612
|
-
name: z11.string().min(1).optional(),
|
|
1636
|
+
slug: z11.string().min(1).nullable().optional(),
|
|
1613
1637
|
description: z11.string().nullable().optional(),
|
|
1614
|
-
|
|
1615
|
-
logoAssetId: logoAssetIdSchema
|
|
1616
|
-
}).strict().refine((value) => value.name !== void 0 || value.description !== void 0 || value.brandColor !== void 0 || value.logoAssetId !== void 0, "At least one branding field must be provided");
|
|
1617
|
-
updateOrganizationWorkspaceFileSchema = z11.object({
|
|
1618
|
-
content: z11.string()
|
|
1619
|
-
});
|
|
1620
|
-
createOrganizationWorkspaceFileSchema = z11.object({
|
|
1621
|
-
filePath: z11.string().trim().min(1).max(1e3),
|
|
1622
|
-
content: z11.string().optional().default("")
|
|
1638
|
+
markdown: z11.string().nullable().optional()
|
|
1623
1639
|
});
|
|
1624
|
-
|
|
1625
|
-
|
|
1640
|
+
organizationSkillFileDetailSchema = z11.object({
|
|
1641
|
+
skillId: z11.string().uuid(),
|
|
1642
|
+
path: z11.string().min(1),
|
|
1643
|
+
kind: z11.enum(["skill", "markdown", "reference", "script", "asset", "other"]),
|
|
1644
|
+
content: z11.string(),
|
|
1645
|
+
language: z11.string().nullable(),
|
|
1646
|
+
markdown: z11.boolean(),
|
|
1647
|
+
editable: z11.boolean()
|
|
1626
1648
|
});
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
moveOrganizationWorkspaceEntrySchema = z11.object({
|
|
1631
|
-
destinationDirectoryPath: z11.string().trim().max(1e3).default("")
|
|
1632
|
-
});
|
|
1633
|
-
copyOrganizationWorkspaceEntrySchema = z11.object({
|
|
1634
|
-
destinationDirectoryPath: z11.string().trim().max(1e3).optional()
|
|
1649
|
+
organizationSkillFileUpdateSchema = z11.object({
|
|
1650
|
+
path: z11.string().min(1),
|
|
1651
|
+
content: z11.string()
|
|
1635
1652
|
});
|
|
1636
1653
|
}
|
|
1637
1654
|
});
|
|
@@ -3328,6 +3345,7 @@ var init_dist = __esm({
|
|
|
3328
3345
|
init_agent_url_key();
|
|
3329
3346
|
init_api();
|
|
3330
3347
|
init_messenger_preview();
|
|
3348
|
+
init_organization_issue_key();
|
|
3331
3349
|
init_organization_skill_reference();
|
|
3332
3350
|
init_organization_url_key();
|
|
3333
3351
|
init_project_mentions();
|
|
@@ -12739,7 +12757,7 @@ function registerCompanyCommands(program) {
|
|
|
12739
12757
|
})
|
|
12740
12758
|
);
|
|
12741
12759
|
addCommonClientOptions(
|
|
12742
|
-
company.command("import").description("Import a portable markdown organization package from local path, URL, or GitHub").argument("<fromPathOrUrl>", "Source path or URL").option("--include <values>", "Comma-separated include set: organization,agents,projects,issues,tasks,skills").option("--target <mode>", "Target mode: new | existing").option("-O, --org-id <id>", "Existing target organization ID").option("--new-organization-name <name>", "Name override for --target new").option("--agents <list>", "Comma-separated agent slugs to import, or all", "all").option("--collision <mode>", "Collision strategy: rename | skip | replace", "rename").option("--ref <value>", "Git ref to use for GitHub imports (branch, tag, or commit)").option("--rudder-url <url>", "Alias for --api-base on this command").option("--yes", "Accept default selection and skip the pre-import confirmation prompt", false).option("--dry-run", "Run preview only without applying", false).action(async (fromPathOrUrl, opts) => {
|
|
12760
|
+
company.command("import").description("Import a portable markdown organization package from local path, URL, or GitHub").argument("<fromPathOrUrl>", "Source path or URL").option("--include <values>", "Comma-separated include set: organization,agents,projects,issues,tasks,skills").option("--target <mode>", "Target mode: new | existing").option("-O, --org-id <id>", "Existing target organization ID").option("--new-organization-name <name>", "Name override for --target new").option("--new-organization-issue-key <key>", "Issue Key override for --target new").option("--agents <list>", "Comma-separated agent slugs to import, or all", "all").option("--collision <mode>", "Collision strategy: rename | skip | replace", "rename").option("--ref <value>", "Git ref to use for GitHub imports (branch, tag, or commit)").option("--rudder-url <url>", "Alias for --api-base on this command").option("--yes", "Accept default selection and skip the pre-import confirmation prompt", false).option("--dry-run", "Run preview only without applying", false).action(async (fromPathOrUrl, opts) => {
|
|
12743
12761
|
try {
|
|
12744
12762
|
if (!opts.apiBase?.trim() && opts.rudderUrl?.trim()) {
|
|
12745
12763
|
opts.apiBase = opts.rudderUrl.trim();
|
|
@@ -12767,7 +12785,8 @@ function registerCompanyCommands(program) {
|
|
|
12767
12785
|
orgId: existingTargetOrganizationId
|
|
12768
12786
|
} : {
|
|
12769
12787
|
mode: "new_organization",
|
|
12770
|
-
newOrganizationName: opts.newOrganizationName?.trim() || null
|
|
12788
|
+
newOrganizationName: opts.newOrganizationName?.trim() || null,
|
|
12789
|
+
newOrganizationIssueKey: opts.newOrganizationIssueKey?.trim() || null
|
|
12771
12790
|
};
|
|
12772
12791
|
if (targetPayload.mode === "existing_organization" && !targetPayload.orgId) {
|
|
12773
12792
|
throw new Error("Target existing organization requires --org-id (or context default orgId).");
|