chainlesschain 0.145.0 → 0.156.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 +52 -3
- package/package.json +1 -1
- package/src/commands/a2a.js +201 -0
- package/src/commands/activitypub.js +207 -0
- package/src/commands/agent-network.js +217 -0
- package/src/commands/agent.js +1250 -0
- package/src/commands/automation.js +201 -0
- package/src/commands/bi.js +203 -0
- package/src/commands/browse.js +213 -0
- package/src/commands/chat.js +605 -0
- package/src/commands/cli-anything.js +426 -0
- package/src/commands/codegen.js +207 -0
- package/src/commands/collab.js +211 -0
- package/src/commands/compliance.js +822 -0
- package/src/commands/config.js +213 -0
- package/src/commands/cowork.js +1666 -0
- package/src/commands/crosschain.js +203 -0
- package/src/commands/dao.js +203 -0
- package/src/commands/dbevo.js +227 -0
- package/src/commands/dev.js +207 -0
- package/src/commands/did-v2.js +217 -0
- package/src/commands/did.js +221 -0
- package/src/commands/dlp.js +213 -0
- package/src/commands/economy.js +199 -0
- package/src/commands/encrypt.js +201 -0
- package/src/commands/evolution.js +199 -0
- package/src/commands/evomap.js +830 -0
- package/src/commands/export.js +213 -0
- package/src/commands/federation.js +209 -0
- package/src/commands/fusion.js +205 -0
- package/src/commands/governance.js +209 -0
- package/src/commands/hmemory.js +203 -0
- package/src/commands/hook.js +209 -0
- package/src/commands/import.js +209 -0
- package/src/commands/inference.js +207 -0
- package/src/commands/infra.js +203 -0
- package/src/commands/instinct.js +209 -0
- package/src/commands/ipfs.js +207 -0
- package/src/commands/kg.js +195 -0
- package/src/commands/llm.js +426 -0
- package/src/commands/matrix.js +207 -0
- package/src/commands/mcp.js +217 -0
- package/src/commands/memory.js +412 -0
- package/src/commands/multimodal.js +203 -0
- package/src/commands/nlprog.js +225 -0
- package/src/commands/nostr.js +209 -0
- package/src/commands/note.js +205 -0
- package/src/commands/ops.js +219 -0
- package/src/commands/orchestrate.js +406 -0
- package/src/commands/org.js +209 -0
- package/src/commands/p2p.js +209 -0
- package/src/commands/perception.js +209 -0
- package/src/commands/permmem.js +203 -0
- package/src/commands/pipeline.js +199 -0
- package/src/commands/planmode.js +426 -0
- package/src/commands/plugin-ecosystem.js +209 -0
- package/src/commands/plugin.js +209 -0
- package/src/commands/pqc.js +213 -0
- package/src/commands/quantization.js +207 -0
- package/src/commands/rcache.js +205 -0
- package/src/commands/recommend.js +233 -0
- package/src/commands/runtime.js +205 -0
- package/src/commands/scim.js +209 -0
- package/src/commands/services.js +207 -0
- package/src/commands/session.js +209 -0
- package/src/commands/setup.js +205 -0
- package/src/commands/skill.js +414 -0
- package/src/commands/social.js +201 -0
- package/src/commands/sso.js +209 -0
- package/src/commands/start.js +209 -0
- package/src/commands/stream.js +213 -0
- package/src/commands/sync.js +209 -0
- package/src/commands/tech.js +209 -0
- package/src/commands/tenant.js +217 -0
- package/src/commands/tokens.js +209 -0
- package/src/commands/trust.js +217 -0
- package/src/commands/ui.js +225 -0
- package/src/commands/wallet.js +209 -0
- package/src/commands/workflow.js +412 -0
- package/src/index.js +252 -0
- package/src/lib/a2a-protocol.js +332 -0
- package/src/lib/activitypub-bridge.js +334 -0
- package/src/lib/agent-coordinator.js +334 -0
- package/src/lib/agent-economy.js +334 -0
- package/src/lib/agent-network.js +341 -0
- package/src/lib/agent-router.js +333 -0
- package/src/lib/aiops.js +346 -0
- package/src/lib/automation-engine.js +335 -0
- package/src/lib/autonomous-agent.js +332 -0
- package/src/lib/autonomous-developer.js +332 -0
- package/src/lib/bi-engine.js +333 -0
- package/src/lib/browser-automation.js +334 -0
- package/src/lib/chat-core.js +335 -0
- package/src/lib/cli-anything-bridge.js +341 -0
- package/src/lib/cli-context-engineering.js +351 -0
- package/src/lib/code-agent.js +339 -0
- package/src/lib/collaboration-governance.js +334 -0
- package/src/lib/community-governance.js +346 -0
- package/src/lib/compliance-manager.js +334 -0
- package/src/lib/content-recommendation.js +351 -0
- package/src/lib/cowork-adapter.js +336 -0
- package/src/lib/cowork-evomap-adapter.js +341 -0
- package/src/lib/cowork-mcp-tools.js +341 -0
- package/src/lib/cowork-observe-html.js +341 -0
- package/src/lib/cowork-observe.js +341 -0
- package/src/lib/cowork-share.js +338 -0
- package/src/lib/cowork-task-templates.js +342 -1
- package/src/lib/cowork-template-marketplace.js +340 -0
- package/src/lib/cross-chain.js +339 -0
- package/src/lib/crypto-manager.js +334 -0
- package/src/lib/dao-governance.js +339 -0
- package/src/lib/dbevo.js +351 -0
- package/src/lib/decentral-infra.js +330 -0
- package/src/lib/did-manager.js +341 -0
- package/src/lib/did-v2-manager.js +341 -0
- package/src/lib/dlp-engine.js +339 -0
- package/src/lib/downloader.js +334 -0
- package/src/lib/evolution-system.js +334 -0
- package/src/lib/evomap-client.js +342 -0
- package/src/lib/evomap-federation.js +338 -0
- package/src/lib/evomap-governance.js +334 -0
- package/src/lib/evomap-manager.js +330 -0
- package/src/lib/execution-backend.js +330 -0
- package/src/lib/federation-hardening.js +340 -0
- package/src/lib/hashline.js +338 -0
- package/src/lib/hierarchical-memory.js +334 -0
- package/src/lib/hook-manager.js +341 -0
- package/src/lib/inference-network.js +341 -0
- package/src/lib/instinct-manager.js +346 -0
- package/src/lib/interaction-adapter.js +330 -0
- package/src/lib/interactive-planner.js +354 -0
- package/src/lib/ipfs-storage.js +334 -0
- package/src/lib/knowledge-exporter.js +341 -0
- package/src/lib/knowledge-graph.js +331 -0
- package/src/lib/knowledge-importer.js +341 -0
- package/src/lib/llm-providers.js +346 -0
- package/src/lib/matrix-bridge.js +339 -0
- package/src/lib/mcp-registry.js +346 -0
- package/src/lib/memory-manager.js +336 -0
- package/src/lib/multimodal.js +330 -0
- package/src/lib/nl-programming.js +341 -0
- package/src/lib/nostr-bridge.js +336 -0
- package/src/lib/note-versioning.js +339 -0
- package/src/lib/org-manager.js +336 -0
- package/src/lib/p2p-manager.js +341 -0
- package/src/lib/perception.js +346 -0
- package/src/lib/permanent-memory.js +327 -0
- package/src/lib/pipeline-orchestrator.js +332 -0
- package/src/lib/plan-mode.js +336 -0
- package/src/lib/plugin-autodiscovery.js +334 -0
- package/src/lib/plugin-ecosystem.js +346 -0
- package/src/lib/pqc-manager.js +346 -0
- package/src/lib/process-manager.js +336 -0
- package/src/lib/protocol-fusion.js +338 -0
- package/src/lib/provider-options.js +346 -0
- package/src/lib/provider-stream.js +348 -0
- package/src/lib/quantization.js +337 -0
- package/src/lib/response-cache.js +333 -0
- package/src/lib/scim-manager.js +346 -0
- package/src/lib/service-manager.js +337 -0
- package/src/lib/session-core-singletons.js +341 -0
- package/src/lib/session-manager.js +334 -0
- package/src/lib/skill-loader.js +334 -0
- package/src/lib/skill-mcp.js +336 -0
- package/src/lib/social-manager.js +330 -0
- package/src/lib/sso-manager.js +340 -0
- package/src/lib/stix-parser.js +346 -0
- package/src/lib/sub-agent-context.js +343 -0
- package/src/lib/sub-agent-profiles.js +335 -0
- package/src/lib/sub-agent-registry.js +336 -0
- package/src/lib/sync-manager.js +336 -0
- package/src/lib/tech-learning-engine.js +341 -0
- package/src/lib/tenant-saas.js +341 -0
- package/src/lib/threat-intel.js +330 -0
- package/src/lib/todo-manager.js +336 -0
- package/src/lib/token-tracker.js +336 -0
- package/src/lib/trust-security.js +343 -0
- package/src/lib/ueba.js +340 -0
- package/src/lib/universal-runtime.js +330 -0
- package/src/lib/wallet-manager.js +336 -0
- package/src/lib/web-ui-server.js +348 -0
- package/src/lib/workflow-engine.js +330 -0
- package/src/lib/workflow-expr.js +346 -0
- package/src/lib/ws-chat-handler.js +337 -0
|
@@ -2260,3 +2260,825 @@ export function registerCmgrV2Commands(program) {
|
|
|
2260
2260
|
);
|
|
2261
2261
|
});
|
|
2262
2262
|
}
|
|
2263
|
+
|
|
2264
|
+
// === Iter24 V2 governance overlay ===
|
|
2265
|
+
export function registerTigovV2Commands(program) {
|
|
2266
|
+
const parent = program.commands.find((c) => c.name() === "compliance");
|
|
2267
|
+
if (!parent) return;
|
|
2268
|
+
const L = async () => await import("../lib/threat-intel.js");
|
|
2269
|
+
parent
|
|
2270
|
+
.command("tigov-enums-v2")
|
|
2271
|
+
.description("Show V2 enums")
|
|
2272
|
+
.action(async () => {
|
|
2273
|
+
const m = await L();
|
|
2274
|
+
console.log(
|
|
2275
|
+
JSON.stringify(
|
|
2276
|
+
{
|
|
2277
|
+
profileMaturity: m.TIGOV_PROFILE_MATURITY_V2,
|
|
2278
|
+
feedLifecycle: m.TIGOV_FEED_LIFECYCLE_V2,
|
|
2279
|
+
},
|
|
2280
|
+
null,
|
|
2281
|
+
2,
|
|
2282
|
+
),
|
|
2283
|
+
);
|
|
2284
|
+
});
|
|
2285
|
+
parent
|
|
2286
|
+
.command("tigov-config-v2")
|
|
2287
|
+
.description("Show V2 config")
|
|
2288
|
+
.action(async () => {
|
|
2289
|
+
const m = await L();
|
|
2290
|
+
console.log(
|
|
2291
|
+
JSON.stringify(
|
|
2292
|
+
{
|
|
2293
|
+
maxActive: m.getMaxActiveTigovProfilesPerOwnerV2(),
|
|
2294
|
+
maxPending: m.getMaxPendingTigovFeedsPerProfileV2(),
|
|
2295
|
+
idleMs: m.getTigovProfileIdleMsV2(),
|
|
2296
|
+
stuckMs: m.getTigovFeedStuckMsV2(),
|
|
2297
|
+
},
|
|
2298
|
+
null,
|
|
2299
|
+
2,
|
|
2300
|
+
),
|
|
2301
|
+
);
|
|
2302
|
+
});
|
|
2303
|
+
parent
|
|
2304
|
+
.command("tigov-set-max-active-v2 <n>")
|
|
2305
|
+
.description("Set max active")
|
|
2306
|
+
.action(async (n) => {
|
|
2307
|
+
(await L()).setMaxActiveTigovProfilesPerOwnerV2(Number(n));
|
|
2308
|
+
console.log("ok");
|
|
2309
|
+
});
|
|
2310
|
+
parent
|
|
2311
|
+
.command("tigov-set-max-pending-v2 <n>")
|
|
2312
|
+
.description("Set max pending")
|
|
2313
|
+
.action(async (n) => {
|
|
2314
|
+
(await L()).setMaxPendingTigovFeedsPerProfileV2(Number(n));
|
|
2315
|
+
console.log("ok");
|
|
2316
|
+
});
|
|
2317
|
+
parent
|
|
2318
|
+
.command("tigov-set-idle-ms-v2 <n>")
|
|
2319
|
+
.description("Set idle threshold ms")
|
|
2320
|
+
.action(async (n) => {
|
|
2321
|
+
(await L()).setTigovProfileIdleMsV2(Number(n));
|
|
2322
|
+
console.log("ok");
|
|
2323
|
+
});
|
|
2324
|
+
parent
|
|
2325
|
+
.command("tigov-set-stuck-ms-v2 <n>")
|
|
2326
|
+
.description("Set stuck threshold ms")
|
|
2327
|
+
.action(async (n) => {
|
|
2328
|
+
(await L()).setTigovFeedStuckMsV2(Number(n));
|
|
2329
|
+
console.log("ok");
|
|
2330
|
+
});
|
|
2331
|
+
parent
|
|
2332
|
+
.command("tigov-register-v2 <id> <owner>")
|
|
2333
|
+
.description("Register V2 profile")
|
|
2334
|
+
.option("--source <v>", "source")
|
|
2335
|
+
.action(async (id, owner, o) => {
|
|
2336
|
+
const m = await L();
|
|
2337
|
+
console.log(
|
|
2338
|
+
JSON.stringify(
|
|
2339
|
+
m.registerTigovProfileV2({ id, owner, source: o.source }),
|
|
2340
|
+
null,
|
|
2341
|
+
2,
|
|
2342
|
+
),
|
|
2343
|
+
);
|
|
2344
|
+
});
|
|
2345
|
+
parent
|
|
2346
|
+
.command("tigov-activate-v2 <id>")
|
|
2347
|
+
.description("Activate profile")
|
|
2348
|
+
.action(async (id) => {
|
|
2349
|
+
console.log(
|
|
2350
|
+
JSON.stringify((await L()).activateTigovProfileV2(id), null, 2),
|
|
2351
|
+
);
|
|
2352
|
+
});
|
|
2353
|
+
parent
|
|
2354
|
+
.command("tigov-stale-v2 <id>")
|
|
2355
|
+
.description("Stale profile")
|
|
2356
|
+
.action(async (id) => {
|
|
2357
|
+
console.log(JSON.stringify((await L()).staleTigovProfileV2(id), null, 2));
|
|
2358
|
+
});
|
|
2359
|
+
parent
|
|
2360
|
+
.command("tigov-archive-v2 <id>")
|
|
2361
|
+
.description("Archive profile")
|
|
2362
|
+
.action(async (id) => {
|
|
2363
|
+
console.log(
|
|
2364
|
+
JSON.stringify((await L()).archiveTigovProfileV2(id), null, 2),
|
|
2365
|
+
);
|
|
2366
|
+
});
|
|
2367
|
+
parent
|
|
2368
|
+
.command("tigov-touch-v2 <id>")
|
|
2369
|
+
.description("Touch profile")
|
|
2370
|
+
.action(async (id) => {
|
|
2371
|
+
console.log(JSON.stringify((await L()).touchTigovProfileV2(id), null, 2));
|
|
2372
|
+
});
|
|
2373
|
+
parent
|
|
2374
|
+
.command("tigov-get-v2 <id>")
|
|
2375
|
+
.description("Get profile")
|
|
2376
|
+
.action(async (id) => {
|
|
2377
|
+
console.log(JSON.stringify((await L()).getTigovProfileV2(id), null, 2));
|
|
2378
|
+
});
|
|
2379
|
+
parent
|
|
2380
|
+
.command("tigov-list-v2")
|
|
2381
|
+
.description("List profiles")
|
|
2382
|
+
.action(async () => {
|
|
2383
|
+
console.log(JSON.stringify((await L()).listTigovProfilesV2(), null, 2));
|
|
2384
|
+
});
|
|
2385
|
+
parent
|
|
2386
|
+
.command("tigov-create-feed-v2 <id> <profileId>")
|
|
2387
|
+
.description("Create feed")
|
|
2388
|
+
.option("--indicator <v>", "indicator")
|
|
2389
|
+
.action(async (id, profileId, o) => {
|
|
2390
|
+
const m = await L();
|
|
2391
|
+
console.log(
|
|
2392
|
+
JSON.stringify(
|
|
2393
|
+
m.createTigovFeedV2({ id, profileId, indicator: o.indicator }),
|
|
2394
|
+
null,
|
|
2395
|
+
2,
|
|
2396
|
+
),
|
|
2397
|
+
);
|
|
2398
|
+
});
|
|
2399
|
+
parent
|
|
2400
|
+
.command("tigov-ingesting-feed-v2 <id>")
|
|
2401
|
+
.description("Mark feed as ingesting")
|
|
2402
|
+
.action(async (id) => {
|
|
2403
|
+
console.log(
|
|
2404
|
+
JSON.stringify((await L()).ingestingTigovFeedV2(id), null, 2),
|
|
2405
|
+
);
|
|
2406
|
+
});
|
|
2407
|
+
parent
|
|
2408
|
+
.command("tigov-complete-feed-v2 <id>")
|
|
2409
|
+
.description("Complete feed")
|
|
2410
|
+
.action(async (id) => {
|
|
2411
|
+
console.log(JSON.stringify((await L()).completeFeedTigovV2(id), null, 2));
|
|
2412
|
+
});
|
|
2413
|
+
parent
|
|
2414
|
+
.command("tigov-fail-feed-v2 <id> [reason]")
|
|
2415
|
+
.description("Fail feed")
|
|
2416
|
+
.action(async (id, reason) => {
|
|
2417
|
+
console.log(
|
|
2418
|
+
JSON.stringify((await L()).failTigovFeedV2(id, reason), null, 2),
|
|
2419
|
+
);
|
|
2420
|
+
});
|
|
2421
|
+
parent
|
|
2422
|
+
.command("tigov-cancel-feed-v2 <id> [reason]")
|
|
2423
|
+
.description("Cancel feed")
|
|
2424
|
+
.action(async (id, reason) => {
|
|
2425
|
+
console.log(
|
|
2426
|
+
JSON.stringify((await L()).cancelTigovFeedV2(id, reason), null, 2),
|
|
2427
|
+
);
|
|
2428
|
+
});
|
|
2429
|
+
parent
|
|
2430
|
+
.command("tigov-get-feed-v2 <id>")
|
|
2431
|
+
.description("Get feed")
|
|
2432
|
+
.action(async (id) => {
|
|
2433
|
+
console.log(JSON.stringify((await L()).getTigovFeedV2(id), null, 2));
|
|
2434
|
+
});
|
|
2435
|
+
parent
|
|
2436
|
+
.command("tigov-list-feeds-v2")
|
|
2437
|
+
.description("List feeds")
|
|
2438
|
+
.action(async () => {
|
|
2439
|
+
console.log(JSON.stringify((await L()).listTigovFeedsV2(), null, 2));
|
|
2440
|
+
});
|
|
2441
|
+
parent
|
|
2442
|
+
.command("tigov-auto-stale-idle-v2")
|
|
2443
|
+
.description("Auto-stale idle")
|
|
2444
|
+
.action(async () => {
|
|
2445
|
+
console.log(
|
|
2446
|
+
JSON.stringify((await L()).autoStaleIdleTigovProfilesV2(), null, 2),
|
|
2447
|
+
);
|
|
2448
|
+
});
|
|
2449
|
+
parent
|
|
2450
|
+
.command("tigov-auto-fail-stuck-v2")
|
|
2451
|
+
.description("Auto-fail stuck feeds")
|
|
2452
|
+
.action(async () => {
|
|
2453
|
+
console.log(
|
|
2454
|
+
JSON.stringify((await L()).autoFailStuckTigovFeedsV2(), null, 2),
|
|
2455
|
+
);
|
|
2456
|
+
});
|
|
2457
|
+
parent
|
|
2458
|
+
.command("tigov-gov-stats-v2")
|
|
2459
|
+
.description("V2 gov stats")
|
|
2460
|
+
.action(async () => {
|
|
2461
|
+
console.log(
|
|
2462
|
+
JSON.stringify((await L()).getThreatIntelGovStatsV2(), null, 2),
|
|
2463
|
+
);
|
|
2464
|
+
});
|
|
2465
|
+
}
|
|
2466
|
+
|
|
2467
|
+
// === Iter24 V2 governance overlay ===
|
|
2468
|
+
export function registerUebgovV2Commands(program) {
|
|
2469
|
+
const parent = program.commands.find((c) => c.name() === "compliance");
|
|
2470
|
+
if (!parent) return;
|
|
2471
|
+
const L = async () => await import("../lib/ueba.js");
|
|
2472
|
+
parent
|
|
2473
|
+
.command("uebgov-enums-v2")
|
|
2474
|
+
.description("Show V2 enums")
|
|
2475
|
+
.action(async () => {
|
|
2476
|
+
const m = await L();
|
|
2477
|
+
console.log(
|
|
2478
|
+
JSON.stringify(
|
|
2479
|
+
{
|
|
2480
|
+
profileMaturity: m.UEBGOV_PROFILE_MATURITY_V2,
|
|
2481
|
+
alertLifecycle: m.UEBGOV_ALERT_LIFECYCLE_V2,
|
|
2482
|
+
},
|
|
2483
|
+
null,
|
|
2484
|
+
2,
|
|
2485
|
+
),
|
|
2486
|
+
);
|
|
2487
|
+
});
|
|
2488
|
+
parent
|
|
2489
|
+
.command("uebgov-config-v2")
|
|
2490
|
+
.description("Show V2 config")
|
|
2491
|
+
.action(async () => {
|
|
2492
|
+
const m = await L();
|
|
2493
|
+
console.log(
|
|
2494
|
+
JSON.stringify(
|
|
2495
|
+
{
|
|
2496
|
+
maxActive: m.getMaxActiveUebgovProfilesPerOwnerV2(),
|
|
2497
|
+
maxPending: m.getMaxPendingUebgovAlertsPerProfileV2(),
|
|
2498
|
+
idleMs: m.getUebgovProfileIdleMsV2(),
|
|
2499
|
+
stuckMs: m.getUebgovAlertStuckMsV2(),
|
|
2500
|
+
},
|
|
2501
|
+
null,
|
|
2502
|
+
2,
|
|
2503
|
+
),
|
|
2504
|
+
);
|
|
2505
|
+
});
|
|
2506
|
+
parent
|
|
2507
|
+
.command("uebgov-set-max-active-v2 <n>")
|
|
2508
|
+
.description("Set max active")
|
|
2509
|
+
.action(async (n) => {
|
|
2510
|
+
(await L()).setMaxActiveUebgovProfilesPerOwnerV2(Number(n));
|
|
2511
|
+
console.log("ok");
|
|
2512
|
+
});
|
|
2513
|
+
parent
|
|
2514
|
+
.command("uebgov-set-max-pending-v2 <n>")
|
|
2515
|
+
.description("Set max pending")
|
|
2516
|
+
.action(async (n) => {
|
|
2517
|
+
(await L()).setMaxPendingUebgovAlertsPerProfileV2(Number(n));
|
|
2518
|
+
console.log("ok");
|
|
2519
|
+
});
|
|
2520
|
+
parent
|
|
2521
|
+
.command("uebgov-set-idle-ms-v2 <n>")
|
|
2522
|
+
.description("Set idle threshold ms")
|
|
2523
|
+
.action(async (n) => {
|
|
2524
|
+
(await L()).setUebgovProfileIdleMsV2(Number(n));
|
|
2525
|
+
console.log("ok");
|
|
2526
|
+
});
|
|
2527
|
+
parent
|
|
2528
|
+
.command("uebgov-set-stuck-ms-v2 <n>")
|
|
2529
|
+
.description("Set stuck threshold ms")
|
|
2530
|
+
.action(async (n) => {
|
|
2531
|
+
(await L()).setUebgovAlertStuckMsV2(Number(n));
|
|
2532
|
+
console.log("ok");
|
|
2533
|
+
});
|
|
2534
|
+
parent
|
|
2535
|
+
.command("uebgov-register-v2 <id> <owner>")
|
|
2536
|
+
.description("Register V2 profile")
|
|
2537
|
+
.option("--entity <v>", "entity")
|
|
2538
|
+
.action(async (id, owner, o) => {
|
|
2539
|
+
const m = await L();
|
|
2540
|
+
console.log(
|
|
2541
|
+
JSON.stringify(
|
|
2542
|
+
m.registerUebgovProfileV2({ id, owner, entity: o.entity }),
|
|
2543
|
+
null,
|
|
2544
|
+
2,
|
|
2545
|
+
),
|
|
2546
|
+
);
|
|
2547
|
+
});
|
|
2548
|
+
parent
|
|
2549
|
+
.command("uebgov-activate-v2 <id>")
|
|
2550
|
+
.description("Activate profile")
|
|
2551
|
+
.action(async (id) => {
|
|
2552
|
+
console.log(
|
|
2553
|
+
JSON.stringify((await L()).activateUebgovProfileV2(id), null, 2),
|
|
2554
|
+
);
|
|
2555
|
+
});
|
|
2556
|
+
parent
|
|
2557
|
+
.command("uebgov-suppress-v2 <id>")
|
|
2558
|
+
.description("Suppress profile")
|
|
2559
|
+
.action(async (id) => {
|
|
2560
|
+
console.log(
|
|
2561
|
+
JSON.stringify((await L()).suppressUebgovProfileV2(id), null, 2),
|
|
2562
|
+
);
|
|
2563
|
+
});
|
|
2564
|
+
parent
|
|
2565
|
+
.command("uebgov-archive-v2 <id>")
|
|
2566
|
+
.description("Archive profile")
|
|
2567
|
+
.action(async (id) => {
|
|
2568
|
+
console.log(
|
|
2569
|
+
JSON.stringify((await L()).archiveUebgovProfileV2(id), null, 2),
|
|
2570
|
+
);
|
|
2571
|
+
});
|
|
2572
|
+
parent
|
|
2573
|
+
.command("uebgov-touch-v2 <id>")
|
|
2574
|
+
.description("Touch profile")
|
|
2575
|
+
.action(async (id) => {
|
|
2576
|
+
console.log(
|
|
2577
|
+
JSON.stringify((await L()).touchUebgovProfileV2(id), null, 2),
|
|
2578
|
+
);
|
|
2579
|
+
});
|
|
2580
|
+
parent
|
|
2581
|
+
.command("uebgov-get-v2 <id>")
|
|
2582
|
+
.description("Get profile")
|
|
2583
|
+
.action(async (id) => {
|
|
2584
|
+
console.log(JSON.stringify((await L()).getUebgovProfileV2(id), null, 2));
|
|
2585
|
+
});
|
|
2586
|
+
parent
|
|
2587
|
+
.command("uebgov-list-v2")
|
|
2588
|
+
.description("List profiles")
|
|
2589
|
+
.action(async () => {
|
|
2590
|
+
console.log(JSON.stringify((await L()).listUebgovProfilesV2(), null, 2));
|
|
2591
|
+
});
|
|
2592
|
+
parent
|
|
2593
|
+
.command("uebgov-create-alert-v2 <id> <profileId>")
|
|
2594
|
+
.description("Create alert")
|
|
2595
|
+
.option("--behavior <v>", "behavior")
|
|
2596
|
+
.action(async (id, profileId, o) => {
|
|
2597
|
+
const m = await L();
|
|
2598
|
+
console.log(
|
|
2599
|
+
JSON.stringify(
|
|
2600
|
+
m.createUebgovAlertV2({ id, profileId, behavior: o.behavior }),
|
|
2601
|
+
null,
|
|
2602
|
+
2,
|
|
2603
|
+
),
|
|
2604
|
+
);
|
|
2605
|
+
});
|
|
2606
|
+
parent
|
|
2607
|
+
.command("uebgov-analyzing-alert-v2 <id>")
|
|
2608
|
+
.description("Mark alert as analyzing")
|
|
2609
|
+
.action(async (id) => {
|
|
2610
|
+
console.log(
|
|
2611
|
+
JSON.stringify((await L()).analyzingUebgovAlertV2(id), null, 2),
|
|
2612
|
+
);
|
|
2613
|
+
});
|
|
2614
|
+
parent
|
|
2615
|
+
.command("uebgov-complete-alert-v2 <id>")
|
|
2616
|
+
.description("Complete alert")
|
|
2617
|
+
.action(async (id) => {
|
|
2618
|
+
console.log(
|
|
2619
|
+
JSON.stringify((await L()).completeAlertUebgovV2(id), null, 2),
|
|
2620
|
+
);
|
|
2621
|
+
});
|
|
2622
|
+
parent
|
|
2623
|
+
.command("uebgov-fail-alert-v2 <id> [reason]")
|
|
2624
|
+
.description("Fail alert")
|
|
2625
|
+
.action(async (id, reason) => {
|
|
2626
|
+
console.log(
|
|
2627
|
+
JSON.stringify((await L()).failUebgovAlertV2(id, reason), null, 2),
|
|
2628
|
+
);
|
|
2629
|
+
});
|
|
2630
|
+
parent
|
|
2631
|
+
.command("uebgov-cancel-alert-v2 <id> [reason]")
|
|
2632
|
+
.description("Cancel alert")
|
|
2633
|
+
.action(async (id, reason) => {
|
|
2634
|
+
console.log(
|
|
2635
|
+
JSON.stringify((await L()).cancelUebgovAlertV2(id, reason), null, 2),
|
|
2636
|
+
);
|
|
2637
|
+
});
|
|
2638
|
+
parent
|
|
2639
|
+
.command("uebgov-get-alert-v2 <id>")
|
|
2640
|
+
.description("Get alert")
|
|
2641
|
+
.action(async (id) => {
|
|
2642
|
+
console.log(JSON.stringify((await L()).getUebgovAlertV2(id), null, 2));
|
|
2643
|
+
});
|
|
2644
|
+
parent
|
|
2645
|
+
.command("uebgov-list-alerts-v2")
|
|
2646
|
+
.description("List alerts")
|
|
2647
|
+
.action(async () => {
|
|
2648
|
+
console.log(JSON.stringify((await L()).listUebgovAlertsV2(), null, 2));
|
|
2649
|
+
});
|
|
2650
|
+
parent
|
|
2651
|
+
.command("uebgov-auto-suppress-idle-v2")
|
|
2652
|
+
.description("Auto-suppress idle")
|
|
2653
|
+
.action(async () => {
|
|
2654
|
+
console.log(
|
|
2655
|
+
JSON.stringify((await L()).autoSuppressIdleUebgovProfilesV2(), null, 2),
|
|
2656
|
+
);
|
|
2657
|
+
});
|
|
2658
|
+
parent
|
|
2659
|
+
.command("uebgov-auto-fail-stuck-v2")
|
|
2660
|
+
.description("Auto-fail stuck alerts")
|
|
2661
|
+
.action(async () => {
|
|
2662
|
+
console.log(
|
|
2663
|
+
JSON.stringify((await L()).autoFailStuckUebgovAlertsV2(), null, 2),
|
|
2664
|
+
);
|
|
2665
|
+
});
|
|
2666
|
+
parent
|
|
2667
|
+
.command("uebgov-gov-stats-v2")
|
|
2668
|
+
.description("V2 gov stats")
|
|
2669
|
+
.action(async () => {
|
|
2670
|
+
console.log(JSON.stringify((await L()).getUebaGovStatsV2(), null, 2));
|
|
2671
|
+
});
|
|
2672
|
+
}
|
|
2673
|
+
|
|
2674
|
+
// === Iter27 V2 governance overlay ===
|
|
2675
|
+
export function registerStixgovV2Commands(program) {
|
|
2676
|
+
const parent = program.commands.find((c) => c.name() === "compliance");
|
|
2677
|
+
if (!parent) return;
|
|
2678
|
+
const L = async () => await import("../lib/stix-parser.js");
|
|
2679
|
+
parent
|
|
2680
|
+
.command("stixgov-enums-v2")
|
|
2681
|
+
.description("Show V2 enums")
|
|
2682
|
+
.action(async () => {
|
|
2683
|
+
const m = await L();
|
|
2684
|
+
console.log(
|
|
2685
|
+
JSON.stringify(
|
|
2686
|
+
{
|
|
2687
|
+
profileMaturity: m.STIXGOV_PROFILE_MATURITY_V2,
|
|
2688
|
+
parseLifecycle: m.STIXGOV_PARSE_LIFECYCLE_V2,
|
|
2689
|
+
},
|
|
2690
|
+
null,
|
|
2691
|
+
2,
|
|
2692
|
+
),
|
|
2693
|
+
);
|
|
2694
|
+
});
|
|
2695
|
+
parent
|
|
2696
|
+
.command("stixgov-config-v2")
|
|
2697
|
+
.description("Show V2 config")
|
|
2698
|
+
.action(async () => {
|
|
2699
|
+
const m = await L();
|
|
2700
|
+
console.log(
|
|
2701
|
+
JSON.stringify(
|
|
2702
|
+
{
|
|
2703
|
+
maxActive: m.getMaxActiveStixgovProfilesPerOwnerV2(),
|
|
2704
|
+
maxPending: m.getMaxPendingStixgovParsesPerProfileV2(),
|
|
2705
|
+
idleMs: m.getStixgovProfileIdleMsV2(),
|
|
2706
|
+
stuckMs: m.getStixgovParseStuckMsV2(),
|
|
2707
|
+
},
|
|
2708
|
+
null,
|
|
2709
|
+
2,
|
|
2710
|
+
),
|
|
2711
|
+
);
|
|
2712
|
+
});
|
|
2713
|
+
parent
|
|
2714
|
+
.command("stixgov-set-max-active-v2 <n>")
|
|
2715
|
+
.description("Set max active")
|
|
2716
|
+
.action(async (n) => {
|
|
2717
|
+
(await L()).setMaxActiveStixgovProfilesPerOwnerV2(Number(n));
|
|
2718
|
+
console.log("ok");
|
|
2719
|
+
});
|
|
2720
|
+
parent
|
|
2721
|
+
.command("stixgov-set-max-pending-v2 <n>")
|
|
2722
|
+
.description("Set max pending")
|
|
2723
|
+
.action(async (n) => {
|
|
2724
|
+
(await L()).setMaxPendingStixgovParsesPerProfileV2(Number(n));
|
|
2725
|
+
console.log("ok");
|
|
2726
|
+
});
|
|
2727
|
+
parent
|
|
2728
|
+
.command("stixgov-set-idle-ms-v2 <n>")
|
|
2729
|
+
.description("Set idle threshold ms")
|
|
2730
|
+
.action(async (n) => {
|
|
2731
|
+
(await L()).setStixgovProfileIdleMsV2(Number(n));
|
|
2732
|
+
console.log("ok");
|
|
2733
|
+
});
|
|
2734
|
+
parent
|
|
2735
|
+
.command("stixgov-set-stuck-ms-v2 <n>")
|
|
2736
|
+
.description("Set stuck threshold ms")
|
|
2737
|
+
.action(async (n) => {
|
|
2738
|
+
(await L()).setStixgovParseStuckMsV2(Number(n));
|
|
2739
|
+
console.log("ok");
|
|
2740
|
+
});
|
|
2741
|
+
parent
|
|
2742
|
+
.command("stixgov-register-v2 <id> <owner>")
|
|
2743
|
+
.description("Register V2 profile")
|
|
2744
|
+
.option("--stixVersion <v>", "stixVersion")
|
|
2745
|
+
.action(async (id, owner, o) => {
|
|
2746
|
+
const m = await L();
|
|
2747
|
+
console.log(
|
|
2748
|
+
JSON.stringify(
|
|
2749
|
+
m.registerStixgovProfileV2({ id, owner, stixVersion: o.stixVersion }),
|
|
2750
|
+
null,
|
|
2751
|
+
2,
|
|
2752
|
+
),
|
|
2753
|
+
);
|
|
2754
|
+
});
|
|
2755
|
+
parent
|
|
2756
|
+
.command("stixgov-activate-v2 <id>")
|
|
2757
|
+
.description("Activate profile")
|
|
2758
|
+
.action(async (id) => {
|
|
2759
|
+
console.log(
|
|
2760
|
+
JSON.stringify((await L()).activateStixgovProfileV2(id), null, 2),
|
|
2761
|
+
);
|
|
2762
|
+
});
|
|
2763
|
+
parent
|
|
2764
|
+
.command("stixgov-stale-v2 <id>")
|
|
2765
|
+
.description("Stale profile")
|
|
2766
|
+
.action(async (id) => {
|
|
2767
|
+
console.log(
|
|
2768
|
+
JSON.stringify((await L()).staleStixgovProfileV2(id), null, 2),
|
|
2769
|
+
);
|
|
2770
|
+
});
|
|
2771
|
+
parent
|
|
2772
|
+
.command("stixgov-archive-v2 <id>")
|
|
2773
|
+
.description("Archive profile")
|
|
2774
|
+
.action(async (id) => {
|
|
2775
|
+
console.log(
|
|
2776
|
+
JSON.stringify((await L()).archiveStixgovProfileV2(id), null, 2),
|
|
2777
|
+
);
|
|
2778
|
+
});
|
|
2779
|
+
parent
|
|
2780
|
+
.command("stixgov-touch-v2 <id>")
|
|
2781
|
+
.description("Touch profile")
|
|
2782
|
+
.action(async (id) => {
|
|
2783
|
+
console.log(
|
|
2784
|
+
JSON.stringify((await L()).touchStixgovProfileV2(id), null, 2),
|
|
2785
|
+
);
|
|
2786
|
+
});
|
|
2787
|
+
parent
|
|
2788
|
+
.command("stixgov-get-v2 <id>")
|
|
2789
|
+
.description("Get profile")
|
|
2790
|
+
.action(async (id) => {
|
|
2791
|
+
console.log(JSON.stringify((await L()).getStixgovProfileV2(id), null, 2));
|
|
2792
|
+
});
|
|
2793
|
+
parent
|
|
2794
|
+
.command("stixgov-list-v2")
|
|
2795
|
+
.description("List profiles")
|
|
2796
|
+
.action(async () => {
|
|
2797
|
+
console.log(JSON.stringify((await L()).listStixgovProfilesV2(), null, 2));
|
|
2798
|
+
});
|
|
2799
|
+
parent
|
|
2800
|
+
.command("stixgov-create-parse-v2 <id> <profileId>")
|
|
2801
|
+
.description("Create parse")
|
|
2802
|
+
.option("--bundleId <v>", "bundleId")
|
|
2803
|
+
.action(async (id, profileId, o) => {
|
|
2804
|
+
const m = await L();
|
|
2805
|
+
console.log(
|
|
2806
|
+
JSON.stringify(
|
|
2807
|
+
m.createStixgovParseV2({ id, profileId, bundleId: o.bundleId }),
|
|
2808
|
+
null,
|
|
2809
|
+
2,
|
|
2810
|
+
),
|
|
2811
|
+
);
|
|
2812
|
+
});
|
|
2813
|
+
parent
|
|
2814
|
+
.command("stixgov-parsing-parse-v2 <id>")
|
|
2815
|
+
.description("Mark parse as parsing")
|
|
2816
|
+
.action(async (id) => {
|
|
2817
|
+
console.log(
|
|
2818
|
+
JSON.stringify((await L()).parsingStixgovParseV2(id), null, 2),
|
|
2819
|
+
);
|
|
2820
|
+
});
|
|
2821
|
+
parent
|
|
2822
|
+
.command("stixgov-complete-parse-v2 <id>")
|
|
2823
|
+
.description("Complete parse")
|
|
2824
|
+
.action(async (id) => {
|
|
2825
|
+
console.log(
|
|
2826
|
+
JSON.stringify((await L()).completeParseStixgovV2(id), null, 2),
|
|
2827
|
+
);
|
|
2828
|
+
});
|
|
2829
|
+
parent
|
|
2830
|
+
.command("stixgov-fail-parse-v2 <id> [reason]")
|
|
2831
|
+
.description("Fail parse")
|
|
2832
|
+
.action(async (id, reason) => {
|
|
2833
|
+
console.log(
|
|
2834
|
+
JSON.stringify((await L()).failStixgovParseV2(id, reason), null, 2),
|
|
2835
|
+
);
|
|
2836
|
+
});
|
|
2837
|
+
parent
|
|
2838
|
+
.command("stixgov-cancel-parse-v2 <id> [reason]")
|
|
2839
|
+
.description("Cancel parse")
|
|
2840
|
+
.action(async (id, reason) => {
|
|
2841
|
+
console.log(
|
|
2842
|
+
JSON.stringify((await L()).cancelStixgovParseV2(id, reason), null, 2),
|
|
2843
|
+
);
|
|
2844
|
+
});
|
|
2845
|
+
parent
|
|
2846
|
+
.command("stixgov-get-parse-v2 <id>")
|
|
2847
|
+
.description("Get parse")
|
|
2848
|
+
.action(async (id) => {
|
|
2849
|
+
console.log(JSON.stringify((await L()).getStixgovParseV2(id), null, 2));
|
|
2850
|
+
});
|
|
2851
|
+
parent
|
|
2852
|
+
.command("stixgov-list-parses-v2")
|
|
2853
|
+
.description("List parses")
|
|
2854
|
+
.action(async () => {
|
|
2855
|
+
console.log(JSON.stringify((await L()).listStixgovParsesV2(), null, 2));
|
|
2856
|
+
});
|
|
2857
|
+
parent
|
|
2858
|
+
.command("stixgov-auto-stale-idle-v2")
|
|
2859
|
+
.description("Auto-stale idle")
|
|
2860
|
+
.action(async () => {
|
|
2861
|
+
console.log(
|
|
2862
|
+
JSON.stringify((await L()).autoStaleIdleStixgovProfilesV2(), null, 2),
|
|
2863
|
+
);
|
|
2864
|
+
});
|
|
2865
|
+
parent
|
|
2866
|
+
.command("stixgov-auto-fail-stuck-v2")
|
|
2867
|
+
.description("Auto-fail stuck parses")
|
|
2868
|
+
.action(async () => {
|
|
2869
|
+
console.log(
|
|
2870
|
+
JSON.stringify((await L()).autoFailStuckStixgovParsesV2(), null, 2),
|
|
2871
|
+
);
|
|
2872
|
+
});
|
|
2873
|
+
parent
|
|
2874
|
+
.command("stixgov-gov-stats-v2")
|
|
2875
|
+
.description("V2 gov stats")
|
|
2876
|
+
.action(async () => {
|
|
2877
|
+
console.log(
|
|
2878
|
+
JSON.stringify((await L()).getStixParserGovStatsV2(), null, 2),
|
|
2879
|
+
);
|
|
2880
|
+
});
|
|
2881
|
+
}
|
|
2882
|
+
|
|
2883
|
+
// === Iter28 V2 governance overlay: Cmpmgov ===
|
|
2884
|
+
export function registerCmpmV2Commands(program) {
|
|
2885
|
+
const parent = program.commands.find((c) => c.name() === "compliance");
|
|
2886
|
+
if (!parent) return;
|
|
2887
|
+
const L = async () => await import("../lib/compliance-manager.js");
|
|
2888
|
+
parent
|
|
2889
|
+
.command("cmpmgov-enums-v2")
|
|
2890
|
+
.description("Show V2 enums")
|
|
2891
|
+
.action(async () => {
|
|
2892
|
+
const m = await L();
|
|
2893
|
+
console.log(
|
|
2894
|
+
JSON.stringify(
|
|
2895
|
+
{
|
|
2896
|
+
profileMaturity: m.CMPMGOV_PROFILE_MATURITY_V2,
|
|
2897
|
+
reportLifecycle: m.CMPMGOV_REPORT_LIFECYCLE_V2,
|
|
2898
|
+
},
|
|
2899
|
+
null,
|
|
2900
|
+
2,
|
|
2901
|
+
),
|
|
2902
|
+
);
|
|
2903
|
+
});
|
|
2904
|
+
parent
|
|
2905
|
+
.command("cmpmgov-config-v2")
|
|
2906
|
+
.description("Show V2 config")
|
|
2907
|
+
.action(async () => {
|
|
2908
|
+
const m = await L();
|
|
2909
|
+
console.log(
|
|
2910
|
+
JSON.stringify(
|
|
2911
|
+
{
|
|
2912
|
+
maxActive: m.getMaxActiveCmpmProfilesPerOwnerV2(),
|
|
2913
|
+
maxPending: m.getMaxPendingCmpmReportsPerProfileV2(),
|
|
2914
|
+
idleMs: m.getCmpmProfileIdleMsV2(),
|
|
2915
|
+
stuckMs: m.getCmpmReportStuckMsV2(),
|
|
2916
|
+
},
|
|
2917
|
+
null,
|
|
2918
|
+
2,
|
|
2919
|
+
),
|
|
2920
|
+
);
|
|
2921
|
+
});
|
|
2922
|
+
parent
|
|
2923
|
+
.command("cmpmgov-set-max-active-v2 <n>")
|
|
2924
|
+
.description("Set max active")
|
|
2925
|
+
.action(async (n) => {
|
|
2926
|
+
(await L()).setMaxActiveCmpmProfilesPerOwnerV2(Number(n));
|
|
2927
|
+
console.log("ok");
|
|
2928
|
+
});
|
|
2929
|
+
parent
|
|
2930
|
+
.command("cmpmgov-set-max-pending-v2 <n>")
|
|
2931
|
+
.description("Set max pending")
|
|
2932
|
+
.action(async (n) => {
|
|
2933
|
+
(await L()).setMaxPendingCmpmReportsPerProfileV2(Number(n));
|
|
2934
|
+
console.log("ok");
|
|
2935
|
+
});
|
|
2936
|
+
parent
|
|
2937
|
+
.command("cmpmgov-set-idle-ms-v2 <n>")
|
|
2938
|
+
.description("Set idle threshold ms")
|
|
2939
|
+
.action(async (n) => {
|
|
2940
|
+
(await L()).setCmpmProfileIdleMsV2(Number(n));
|
|
2941
|
+
console.log("ok");
|
|
2942
|
+
});
|
|
2943
|
+
parent
|
|
2944
|
+
.command("cmpmgov-set-stuck-ms-v2 <n>")
|
|
2945
|
+
.description("Set stuck threshold ms")
|
|
2946
|
+
.action(async (n) => {
|
|
2947
|
+
(await L()).setCmpmReportStuckMsV2(Number(n));
|
|
2948
|
+
console.log("ok");
|
|
2949
|
+
});
|
|
2950
|
+
parent
|
|
2951
|
+
.command("cmpmgov-register-v2 <id> <owner>")
|
|
2952
|
+
.description("Register V2 profile")
|
|
2953
|
+
.option("--framework <v>", "framework")
|
|
2954
|
+
.action(async (id, owner, o) => {
|
|
2955
|
+
const m = await L();
|
|
2956
|
+
console.log(
|
|
2957
|
+
JSON.stringify(
|
|
2958
|
+
m.registerCmpmProfileV2({ id, owner, framework: o.framework }),
|
|
2959
|
+
null,
|
|
2960
|
+
2,
|
|
2961
|
+
),
|
|
2962
|
+
);
|
|
2963
|
+
});
|
|
2964
|
+
parent
|
|
2965
|
+
.command("cmpmgov-activate-v2 <id>")
|
|
2966
|
+
.description("Activate profile")
|
|
2967
|
+
.action(async (id) => {
|
|
2968
|
+
console.log(
|
|
2969
|
+
JSON.stringify((await L()).activateCmpmProfileV2(id), null, 2),
|
|
2970
|
+
);
|
|
2971
|
+
});
|
|
2972
|
+
parent
|
|
2973
|
+
.command("cmpmgov-stale-v2 <id>")
|
|
2974
|
+
.description("Stale profile")
|
|
2975
|
+
.action(async (id) => {
|
|
2976
|
+
console.log(JSON.stringify((await L()).staleCmpmProfileV2(id), null, 2));
|
|
2977
|
+
});
|
|
2978
|
+
parent
|
|
2979
|
+
.command("cmpmgov-archive-v2 <id>")
|
|
2980
|
+
.description("Archive profile")
|
|
2981
|
+
.action(async (id) => {
|
|
2982
|
+
console.log(
|
|
2983
|
+
JSON.stringify((await L()).archiveCmpmProfileV2(id), null, 2),
|
|
2984
|
+
);
|
|
2985
|
+
});
|
|
2986
|
+
parent
|
|
2987
|
+
.command("cmpmgov-touch-v2 <id>")
|
|
2988
|
+
.description("Touch profile")
|
|
2989
|
+
.action(async (id) => {
|
|
2990
|
+
console.log(JSON.stringify((await L()).touchCmpmProfileV2(id), null, 2));
|
|
2991
|
+
});
|
|
2992
|
+
parent
|
|
2993
|
+
.command("cmpmgov-get-v2 <id>")
|
|
2994
|
+
.description("Get profile")
|
|
2995
|
+
.action(async (id) => {
|
|
2996
|
+
console.log(JSON.stringify((await L()).getCmpmProfileV2(id), null, 2));
|
|
2997
|
+
});
|
|
2998
|
+
parent
|
|
2999
|
+
.command("cmpmgov-list-v2")
|
|
3000
|
+
.description("List profiles")
|
|
3001
|
+
.action(async () => {
|
|
3002
|
+
console.log(JSON.stringify((await L()).listCmpmProfilesV2(), null, 2));
|
|
3003
|
+
});
|
|
3004
|
+
parent
|
|
3005
|
+
.command("cmpmgov-create-report-v2 <id> <profileId>")
|
|
3006
|
+
.description("Create report")
|
|
3007
|
+
.option("--reportId <v>", "reportId")
|
|
3008
|
+
.action(async (id, profileId, o) => {
|
|
3009
|
+
const m = await L();
|
|
3010
|
+
console.log(
|
|
3011
|
+
JSON.stringify(
|
|
3012
|
+
m.createCmpmReportV2({ id, profileId, reportId: o.reportId }),
|
|
3013
|
+
null,
|
|
3014
|
+
2,
|
|
3015
|
+
),
|
|
3016
|
+
);
|
|
3017
|
+
});
|
|
3018
|
+
parent
|
|
3019
|
+
.command("cmpmgov-reporting-report-v2 <id>")
|
|
3020
|
+
.description("Mark report as reporting")
|
|
3021
|
+
.action(async (id) => {
|
|
3022
|
+
console.log(
|
|
3023
|
+
JSON.stringify((await L()).reportingCmpmReportV2(id), null, 2),
|
|
3024
|
+
);
|
|
3025
|
+
});
|
|
3026
|
+
parent
|
|
3027
|
+
.command("cmpmgov-complete-report-v2 <id>")
|
|
3028
|
+
.description("Complete report")
|
|
3029
|
+
.action(async (id) => {
|
|
3030
|
+
console.log(
|
|
3031
|
+
JSON.stringify((await L()).completeReportCmpmV2(id), null, 2),
|
|
3032
|
+
);
|
|
3033
|
+
});
|
|
3034
|
+
parent
|
|
3035
|
+
.command("cmpmgov-fail-report-v2 <id> [reason]")
|
|
3036
|
+
.description("Fail report")
|
|
3037
|
+
.action(async (id, reason) => {
|
|
3038
|
+
console.log(
|
|
3039
|
+
JSON.stringify((await L()).failCmpmReportV2(id, reason), null, 2),
|
|
3040
|
+
);
|
|
3041
|
+
});
|
|
3042
|
+
parent
|
|
3043
|
+
.command("cmpmgov-cancel-report-v2 <id> [reason]")
|
|
3044
|
+
.description("Cancel report")
|
|
3045
|
+
.action(async (id, reason) => {
|
|
3046
|
+
console.log(
|
|
3047
|
+
JSON.stringify((await L()).cancelCmpmReportV2(id, reason), null, 2),
|
|
3048
|
+
);
|
|
3049
|
+
});
|
|
3050
|
+
parent
|
|
3051
|
+
.command("cmpmgov-get-report-v2 <id>")
|
|
3052
|
+
.description("Get report")
|
|
3053
|
+
.action(async (id) => {
|
|
3054
|
+
console.log(JSON.stringify((await L()).getCmpmReportV2(id), null, 2));
|
|
3055
|
+
});
|
|
3056
|
+
parent
|
|
3057
|
+
.command("cmpmgov-list-reports-v2")
|
|
3058
|
+
.description("List reports")
|
|
3059
|
+
.action(async () => {
|
|
3060
|
+
console.log(JSON.stringify((await L()).listCmpmReportsV2(), null, 2));
|
|
3061
|
+
});
|
|
3062
|
+
parent
|
|
3063
|
+
.command("cmpmgov-auto-stale-idle-v2")
|
|
3064
|
+
.description("Auto-stale idle")
|
|
3065
|
+
.action(async () => {
|
|
3066
|
+
console.log(
|
|
3067
|
+
JSON.stringify((await L()).autoStaleIdleCmpmProfilesV2(), null, 2),
|
|
3068
|
+
);
|
|
3069
|
+
});
|
|
3070
|
+
parent
|
|
3071
|
+
.command("cmpmgov-auto-fail-stuck-v2")
|
|
3072
|
+
.description("Auto-fail stuck reports")
|
|
3073
|
+
.action(async () => {
|
|
3074
|
+
console.log(
|
|
3075
|
+
JSON.stringify((await L()).autoFailStuckCmpmReportsV2(), null, 2),
|
|
3076
|
+
);
|
|
3077
|
+
});
|
|
3078
|
+
parent
|
|
3079
|
+
.command("cmpmgov-gov-stats-v2")
|
|
3080
|
+
.description("V2 gov stats")
|
|
3081
|
+
.action(async () => {
|
|
3082
|
+
console.log(JSON.stringify((await L()).getCmpmgovStatsV2(), null, 2));
|
|
3083
|
+
});
|
|
3084
|
+
}
|