@loxtep/sdk 0.11.1 → 0.13.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.
Files changed (69) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/dist/cli/commands/attach-cmd.d.ts +1 -1
  3. package/dist/cli/commands/attach-cmd.js +1 -1
  4. package/dist/cli/commands/delivery-cmd.d.ts +1 -0
  5. package/dist/cli/commands/delivery-cmd.d.ts.map +1 -1
  6. package/dist/cli/commands/delivery-cmd.js +60 -44
  7. package/dist/cli/commands/delivery-cmd.js.map +1 -1
  8. package/dist/cli/commands/ingest-cmd.d.ts +1 -0
  9. package/dist/cli/commands/ingest-cmd.d.ts.map +1 -1
  10. package/dist/cli/commands/ingest-cmd.js +37 -24
  11. package/dist/cli/commands/ingest-cmd.js.map +1 -1
  12. package/dist/cli/commands/start-cmd.d.ts +25 -0
  13. package/dist/cli/commands/start-cmd.d.ts.map +1 -0
  14. package/dist/cli/commands/start-cmd.js +145 -0
  15. package/dist/cli/commands/start-cmd.js.map +1 -0
  16. package/dist/cli/commands/transform-cmd.d.ts +1 -0
  17. package/dist/cli/commands/transform-cmd.d.ts.map +1 -1
  18. package/dist/cli/commands/transform-cmd.js +36 -23
  19. package/dist/cli/commands/transform-cmd.js.map +1 -1
  20. package/dist/cli/help.d.ts.map +1 -1
  21. package/dist/cli/help.js +9 -3
  22. package/dist/cli/help.js.map +1 -1
  23. package/dist/cli/index.d.ts.map +1 -1
  24. package/dist/cli/index.js +576 -515
  25. package/dist/cli/index.js.map +1 -1
  26. package/dist/cli/setup-prompt.d.ts +2 -0
  27. package/dist/cli/setup-prompt.d.ts.map +1 -0
  28. package/dist/cli/setup-prompt.js +3 -0
  29. package/dist/cli/setup-prompt.js.map +1 -0
  30. package/dist/client/data-products.d.ts +10 -8
  31. package/dist/client/data-products.d.ts.map +1 -1
  32. package/dist/client/data-products.js +142 -93
  33. package/dist/client/data-products.js.map +1 -1
  34. package/dist/client/flow-types.d.ts +16 -6
  35. package/dist/client/flow-types.d.ts.map +1 -1
  36. package/dist/client/flow-types.js +6 -1
  37. package/dist/client/flow-types.js.map +1 -1
  38. package/dist/client/index.d.ts +89 -88
  39. package/dist/client/index.d.ts.map +1 -1
  40. package/dist/client/index.js +13 -12
  41. package/dist/client/index.js.map +1 -1
  42. package/dist/client/projects-types.d.ts +1 -1
  43. package/dist/client/queues.d.ts +5 -3
  44. package/dist/client/queues.d.ts.map +1 -1
  45. package/dist/client/queues.js +26 -21
  46. package/dist/client/queues.js.map +1 -1
  47. package/dist/client/workflows.d.ts +7 -7
  48. package/dist/client/workflows.d.ts.map +1 -1
  49. package/dist/client/workflows.js +71 -63
  50. package/dist/client/workflows.js.map +1 -1
  51. package/dist/lib/sdk-ingest-bundle.d.ts +5 -1
  52. package/dist/lib/sdk-ingest-bundle.d.ts.map +1 -1
  53. package/dist/lib/sdk-ingest-bundle.js +38 -29
  54. package/dist/lib/sdk-ingest-bundle.js.map +1 -1
  55. package/dist/rstreams/event-bridge.d.ts +4 -4
  56. package/dist/rstreams/event-bridge.d.ts.map +1 -1
  57. package/dist/rstreams/event-bridge.js +23 -16
  58. package/dist/rstreams/event-bridge.js.map +1 -1
  59. package/docs/event-writer-transport-modes.md +47 -0
  60. package/docs/getting-started.md +19 -0
  61. package/docs/sdk-first-ingest.md +14 -12
  62. package/docs/sdk-mcp-mapping.md +8 -3
  63. package/package.json +1 -1
  64. package/schemas/entity-json-schemas/SCHEMA_SYNC.md +1 -1
  65. package/schemas/entity-json-schemas/SOURCE.json +5 -4
  66. package/schemas/entity-json-schemas/connection.json +35 -0
  67. package/schemas/entity-json-schemas/data-product.json +16 -0
  68. package/schemas/entity-json-schemas/grant.json +146 -0
  69. package/schemas/entity-json-schemas/transformation.json +19 -0
package/dist/cli/index.js CHANGED
@@ -7,54 +7,55 @@
7
7
  * Usage: loxtep <command> [options]
8
8
  * Help is grouped by customer-facing command areas — see ./help.ts
9
9
  */
10
- import { runLogin } from './commands/login.js';
11
- import { runLogout } from './commands/logout.js';
12
- import { runWhoami } from './commands/whoami.js';
13
- import { runAttach } from './commands/attach-cmd.js';
14
- import { runConfigList, runConfigPaths, runConfigSet, runConfigExportFromDataProduct, runConfigExportFromConnector, } from './commands/config-cmd.js';
15
- import { runInitCommand } from './commands/init-cmd.js';
16
- import { runSetup } from './commands/setup-cmd.js';
17
- import { runBusLogin } from './commands/bus-cmd.js';
18
- import { createCliClient, requireCliClient } from './create-cli-client.js';
19
- import { runDataProductsList, runDataProductsGet, runDataProductsQuery, runDataProductsTables, runDataProductsCreate, runDataProductsReadiness, runDataProductsPromote, } from './commands/data-products-cmd.js';
20
- import { runDataPlaneIceberg, runDataPlaneExport, runPrimaryEntity, runDefineGlossary, runDataContractsUpdate, runQualityRules, } from './commands/data-plane-cmd.js';
21
- import { runMetricsRateLimits, runMetricsLog } from './commands/metrics-cmd.js';
22
- import { runQueueInfo, runQueueCheckpoint } from './commands/queue-cmd.js';
23
- import { runWorkflowsList, runWorkflowsGet, runWorkflowsCreate, runWorkflowsDeploy, runWorkflowsPreviewQueryTrigger, runWorkflowsRunQueryTrigger, } from './commands/workflows-cmd.js';
24
- import { runBundleSave } from './commands/bundle-cmd.js';
25
- import { runIngestCreate } from './commands/ingest-cmd.js';
26
- import { runTransformCreate } from './commands/transform-cmd.js';
27
- import { runDeliveryCreate } from './commands/delivery-cmd.js';
28
- import { runPush } from './commands/push-cmd.js';
29
- import { runLint } from './commands/lint-cmd.js';
30
- import { runConnectorsList, runConnectorsTest, runConnectorsCaptureSamples, runConnectorsListEntities, } from './commands/connectors-cmd.js';
31
- import { runObserveStatus } from './commands/observe-cmd.js';
32
- import { runTriggersList, runTriggersGet, runTriggersCreate, runTriggersTest, runTriggersResetBackfill, } from './commands/triggers-cmd.js';
33
- import { runDomainsList, runDomainsGet } from './commands/domains-cmd.js';
34
- import { runStandardsList, runStandardsGet } from './commands/standards-cmd.js';
35
- import { runDataContractsList, runDataContractsGet, runDataContractsCreate } from './commands/data-contracts-cmd.js';
36
- import { runGenerate } from './commands/generate-cmd.js';
37
- import { runTest } from './commands/test-cmd.js';
38
- import { runDeploy } from './commands/deploy-cmd.js';
39
- import { runImprovementsListCommand, runImprovementsApplyCommand, runImprovementsRejectCommand, } from './commands/improvements-cmd.js';
40
- import { runApprovalsListCommand, runApprovalsApproveCommand, runApprovalsRejectCommand, parseApprovalsListNumericFlags, } from './commands/approvals-cmd.js';
41
- import { runCdlcTransitionCommand, runCdlcReviewQueueCommand, } from './commands/cdlc-cmd.js';
42
- import { runCandidatesListCommand, runCandidatesActCommand, } from './commands/candidates-cmd.js';
43
- import { runPacksListCommand, runPacksActivateCommand, runPacksStatusCommand, } from './commands/packs-cmd.js';
44
- import { PROPOSALS_USAGE, runProposalsListCommand, runProposalsAcceptCommand, runProposalsRejectCommand, runProposalsInferDefinitionsCommand, } from './commands/proposals-cmd.js';
45
- import { DEFINE_USAGE, runDefineStatusCommand, runDefineEvidenceCommand, runDefineListCommand, runDefineGetCommand, runDefineSubmitShapeCommand, runDefineSubmitSemanticCommand, runDefineApproveCommand, runDefineApplyCommand, runDefineWithdrawCommand, runDefineSkillCommand, runDefineStartProcedureCommand, runDefineBatchCommand, } from './commands/define-cmd.js';
46
- import { runDeploymentsListCommand, runDeploymentsGetCommand, } from './commands/deployments-cmd.js';
47
- import { runActivityListCommand } from './commands/activity-cmd.js';
48
- import { runInstancesList, runInstancesGet, runInstancesStreamConfig, runInstancesCreate, runInstancesUpdate, runInstancesRedeployRuntimes, runInstancesDeploymentUrls, runInstancesRegistration, runInstancesRegister, parseCreateInstanceArgs, parseUpdateInstanceArgs, } from './commands/instances-cmd.js';
49
- import { runBotsList, runBotsGet, runBotsRegister, runBotsUpdate, runBotsDeregister, runBotsReconcile, } from './commands/bots-cmd.js';
50
- import { runProjectsList, runProjectsGet, runProjectsLink, runProjectsChanges, runProjectsClone, runProjectsGithubPullCmd, runProjectsGithubPushCmd, } from './commands/projects-cmd.js';
51
- import { runStatus } from './commands/status-cmd.js';
52
- import { runOntologyLinkClassCommand } from './commands/ontology-cmd.js';
53
- import { printCliHelp } from './help.js';
54
- import { printCliVersion } from './version.js';
55
- import { startUpdateCheck } from './update-notifier.js';
56
- import { LoxtepError } from '../errors/base.js';
57
- import { AuthenticationError, AuthorizationError } from '../errors/auth.js';
10
+ import { runLogin } from "./commands/login.js";
11
+ import { runLogout } from "./commands/logout.js";
12
+ import { runWhoami } from "./commands/whoami.js";
13
+ import { runAttach } from "./commands/attach-cmd.js";
14
+ import { runConfigList, runConfigPaths, runConfigSet, runConfigExportFromDataProduct, runConfigExportFromConnector, } from "./commands/config-cmd.js";
15
+ import { runInitCommand } from "./commands/init-cmd.js";
16
+ import { runStart } from "./commands/start-cmd.js";
17
+ import { runSetup } from "./commands/setup-cmd.js";
18
+ import { runBusLogin } from "./commands/bus-cmd.js";
19
+ import { createCliClient, requireCliClient } from "./create-cli-client.js";
20
+ import { runDataProductsList, runDataProductsGet, runDataProductsQuery, runDataProductsTables, runDataProductsCreate, runDataProductsReadiness, runDataProductsPromote, } from "./commands/data-products-cmd.js";
21
+ import { runDataPlaneIceberg, runDataPlaneExport, runPrimaryEntity, runDefineGlossary, runDataContractsUpdate, runQualityRules, } from "./commands/data-plane-cmd.js";
22
+ import { runMetricsRateLimits, runMetricsLog } from "./commands/metrics-cmd.js";
23
+ import { runQueueInfo, runQueueCheckpoint } from "./commands/queue-cmd.js";
24
+ import { runWorkflowsList, runWorkflowsGet, runWorkflowsCreate, runWorkflowsDeploy, runWorkflowsPreviewQueryTrigger, runWorkflowsRunQueryTrigger, } from "./commands/workflows-cmd.js";
25
+ import { runBundleSave } from "./commands/bundle-cmd.js";
26
+ import { runIngestCreate } from "./commands/ingest-cmd.js";
27
+ import { runTransformCreate } from "./commands/transform-cmd.js";
28
+ import { runDeliveryCreate } from "./commands/delivery-cmd.js";
29
+ import { runPush } from "./commands/push-cmd.js";
30
+ import { runLint } from "./commands/lint-cmd.js";
31
+ import { runConnectorsList, runConnectorsTest, runConnectorsCaptureSamples, runConnectorsListEntities, } from "./commands/connectors-cmd.js";
32
+ import { runObserveStatus } from "./commands/observe-cmd.js";
33
+ import { runTriggersList, runTriggersGet, runTriggersCreate, runTriggersTest, runTriggersResetBackfill, } from "./commands/triggers-cmd.js";
34
+ import { runDomainsList, runDomainsGet } from "./commands/domains-cmd.js";
35
+ import { runStandardsList, runStandardsGet } from "./commands/standards-cmd.js";
36
+ import { runDataContractsList, runDataContractsGet, runDataContractsCreate, } from "./commands/data-contracts-cmd.js";
37
+ import { runGenerate } from "./commands/generate-cmd.js";
38
+ import { runTest } from "./commands/test-cmd.js";
39
+ import { runDeploy } from "./commands/deploy-cmd.js";
40
+ import { runImprovementsListCommand, runImprovementsApplyCommand, runImprovementsRejectCommand, } from "./commands/improvements-cmd.js";
41
+ import { runApprovalsListCommand, runApprovalsApproveCommand, runApprovalsRejectCommand, parseApprovalsListNumericFlags, } from "./commands/approvals-cmd.js";
42
+ import { runCdlcTransitionCommand, runCdlcReviewQueueCommand, } from "./commands/cdlc-cmd.js";
43
+ import { runCandidatesListCommand, runCandidatesActCommand, } from "./commands/candidates-cmd.js";
44
+ import { runPacksListCommand, runPacksActivateCommand, runPacksStatusCommand, } from "./commands/packs-cmd.js";
45
+ import { PROPOSALS_USAGE, runProposalsListCommand, runProposalsAcceptCommand, runProposalsRejectCommand, runProposalsInferDefinitionsCommand, } from "./commands/proposals-cmd.js";
46
+ import { DEFINE_USAGE, runDefineStatusCommand, runDefineEvidenceCommand, runDefineListCommand, runDefineGetCommand, runDefineSubmitShapeCommand, runDefineSubmitSemanticCommand, runDefineApproveCommand, runDefineApplyCommand, runDefineWithdrawCommand, runDefineSkillCommand, runDefineStartProcedureCommand, runDefineBatchCommand, } from "./commands/define-cmd.js";
47
+ import { runDeploymentsListCommand, runDeploymentsGetCommand, } from "./commands/deployments-cmd.js";
48
+ import { runActivityListCommand } from "./commands/activity-cmd.js";
49
+ import { runInstancesList, runInstancesGet, runInstancesStreamConfig, runInstancesCreate, runInstancesUpdate, runInstancesRedeployRuntimes, runInstancesDeploymentUrls, runInstancesRegistration, runInstancesRegister, parseCreateInstanceArgs, parseUpdateInstanceArgs, } from "./commands/instances-cmd.js";
50
+ import { runBotsList, runBotsGet, runBotsRegister, runBotsUpdate, runBotsDeregister, runBotsReconcile, } from "./commands/bots-cmd.js";
51
+ import { runProjectsList, runProjectsGet, runProjectsLink, runProjectsChanges, runProjectsClone, runProjectsGithubPullCmd, runProjectsGithubPushCmd, } from "./commands/projects-cmd.js";
52
+ import { runStatus } from "./commands/status-cmd.js";
53
+ import { runOntologyLinkClassCommand } from "./commands/ontology-cmd.js";
54
+ import { printCliHelp } from "./help.js";
55
+ import { printCliVersion } from "./version.js";
56
+ import { startUpdateCheck } from "./update-notifier.js";
57
+ import { LoxtepError } from "../errors/base.js";
58
+ import { AuthenticationError, AuthorizationError } from "../errors/auth.js";
58
59
  function printHelp() {
59
60
  printCliHelp();
60
61
  }
@@ -76,7 +77,7 @@ function formatCliError(err) {
76
77
  * Does not read `process.argv` so callers can inject argv.
77
78
  */
78
79
  export async function runCli(argv) {
79
- if (argv.includes('--help') || argv.includes('-h')) {
80
+ if (argv.includes("--help") || argv.includes("-h")) {
80
81
  printHelp();
81
82
  return;
82
83
  }
@@ -93,11 +94,11 @@ export async function runCli(argv) {
93
94
  // finally block entirely, which used to silently swallow the notice for any pre-auth command.
94
95
  const updateCheck = startUpdateCheck();
95
96
  try {
96
- if (!command || command === '--help' || command === '-h') {
97
+ if (!command || command === "--help" || command === "-h") {
97
98
  printHelp();
98
99
  return;
99
100
  }
100
- if (command === '--version' || command === '-V' || command === 'version') {
101
+ if (command === "--version" || command === "-V" || command === "version") {
101
102
  printCliVersion();
102
103
  return;
103
104
  }
@@ -108,14 +109,40 @@ export async function runCli(argv) {
108
109
  }
109
110
  async function runCommand() {
110
111
  switch (command) {
111
- case 'login': {
112
- const emailIdx = args.indexOf('--email');
113
- const passwordIdx = args.indexOf('--password');
114
- const mfaIdx = args.indexOf('--mfa-code');
115
- const orgIdx = args.indexOf('--organization-id');
116
- const scope = args.includes('--global') ? 'global' : args.includes('--local') ? 'local' : undefined;
112
+ case "start": {
113
+ if (args.includes("--help") || args.includes("-h")) {
114
+ console.log("Usage: loxtep start [--client claude|codex|opencode|cursor] [--no-launch]\nInstall the client integration and launch your agent. Requires Node 22.20+.");
115
+ break;
116
+ }
117
+ for (let i = 1; i < args.length; i++) {
118
+ if (args[i] === "--no-launch")
119
+ continue;
120
+ if (args[i] === "--client" &&
121
+ args[i + 1] &&
122
+ !args[i + 1].startsWith("-")) {
123
+ i++;
124
+ continue;
125
+ }
126
+ throw new Error(`Unknown or incomplete start option: ${args[i]}. See loxtep start --help.`);
127
+ }
128
+ runStart({
129
+ client: getArg("--client"),
130
+ noLaunch: args.includes("--no-launch"),
131
+ });
132
+ break;
133
+ }
134
+ case "login": {
135
+ const emailIdx = args.indexOf("--email");
136
+ const passwordIdx = args.indexOf("--password");
137
+ const mfaIdx = args.indexOf("--mfa-code");
138
+ const orgIdx = args.indexOf("--organization-id");
139
+ const scope = args.includes("--global")
140
+ ? "global"
141
+ : args.includes("--local")
142
+ ? "local"
143
+ : undefined;
117
144
  await runLogin({
118
- console: args.includes('--console'),
145
+ console: args.includes("--console"),
119
146
  email: emailIdx >= 0 ? args[emailIdx + 1] : undefined,
120
147
  password: passwordIdx >= 0 ? args[passwordIdx + 1] : undefined,
121
148
  mfa_code: mfaIdx >= 0 ? args[mfaIdx + 1] : undefined,
@@ -124,24 +151,28 @@ export async function runCli(argv) {
124
151
  });
125
152
  break;
126
153
  }
127
- case 'logout': {
128
- const scope = args.includes('--global') ? 'global' : args.includes('--local') ? 'local' : undefined;
154
+ case "logout": {
155
+ const scope = args.includes("--global")
156
+ ? "global"
157
+ : args.includes("--local")
158
+ ? "local"
159
+ : undefined;
129
160
  await runLogout({ scope });
130
161
  break;
131
162
  }
132
- case 'whoami':
133
- await runWhoami({ debug: args.includes('--debug') });
163
+ case "whoami":
164
+ await runWhoami({ debug: args.includes("--debug") });
134
165
  break;
135
- case 'init': {
136
- const templateIdx = args.indexOf('--template');
166
+ case "init": {
167
+ const templateIdx = args.indexOf("--template");
137
168
  const templateSlug = templateIdx >= 0 ? args[templateIdx + 1] : undefined;
138
- const createRepoIdx = args.indexOf('--create-repo');
139
- const createRepo = createRepoIdx >= 0 ? (args[createRepoIdx + 1] || true) : undefined;
140
- const fromRepoIdx = args.indexOf('--from-repo');
169
+ const createRepoIdx = args.indexOf("--create-repo");
170
+ const createRepo = createRepoIdx >= 0 ? args[createRepoIdx + 1] || true : undefined;
171
+ const fromRepoIdx = args.indexOf("--from-repo");
141
172
  const fromRepo = fromRepoIdx >= 0 ? args[fromRepoIdx + 1] : undefined;
142
- const nameIdx = args.indexOf('--name');
173
+ const nameIdx = args.indexOf("--name");
143
174
  const name = nameIdx >= 0 ? args[nameIdx + 1] : undefined;
144
- const projectIdIdx = args.indexOf('--project-id');
175
+ const projectIdIdx = args.indexOf("--project-id");
145
176
  const projectId = projectIdIdx >= 0 ? args[projectIdIdx + 1] : undefined;
146
177
  // Attempt to get an authenticated client (don't fail if not logged in)
147
178
  const clientResult = await createCliClient().catch(() => null);
@@ -163,138 +194,142 @@ export async function runCli(argv) {
163
194
  process.exitCode = result.exitCode;
164
195
  break;
165
196
  }
166
- case 'generate':
197
+ case "generate":
167
198
  await runGenerate();
168
199
  break;
169
- case 'setup':
200
+ case "setup":
170
201
  await runSetup();
171
202
  break;
172
- case 'test':
203
+ case "test":
173
204
  await runTest();
174
205
  break;
175
- case 'deploy': {
176
- const dryRun = args.includes('--dry-run');
206
+ case "deploy": {
207
+ const dryRun = args.includes("--dry-run");
177
208
  await runDeploy({ dry_run: dryRun });
178
209
  break;
179
210
  }
180
- case 'lint': {
211
+ case "lint": {
181
212
  await runLint({
182
- workflow_id: getArg('--workflow'),
213
+ workflow_id: getArg("--workflow"),
183
214
  });
184
215
  break;
185
216
  }
186
- case 'attach': {
217
+ case "attach": {
187
218
  const authResult = await requireCliClient();
188
219
  const attachResult = await runAttach(authResult.client, {
189
- instanceId: getArg('--instance'),
220
+ instanceId: getArg("--instance"),
190
221
  });
191
222
  if (attachResult.stdout.length > 0) {
192
- attachResult.stdout.forEach(line => console.log(line));
223
+ attachResult.stdout.forEach((line) => console.log(line));
193
224
  }
194
225
  if (attachResult.stderr.length > 0) {
195
- attachResult.stderr.forEach(line => console.error(line));
226
+ attachResult.stderr.forEach((line) => console.error(line));
196
227
  }
197
228
  if (attachResult.exitCode !== 0) {
198
229
  process.exitCode = attachResult.exitCode;
199
230
  }
200
231
  break;
201
232
  }
202
- case 'link': {
233
+ case "link": {
203
234
  // Alias for projects link — cloud project ↔ directory bind.
204
235
  const linkRef = args[1];
205
- if (!linkRef || linkRef.startsWith('--')) {
206
- console.error('Usage: loxtep link <project_id|name> [--path <dir>]');
236
+ if (!linkRef || linkRef.startsWith("--")) {
237
+ console.error("Usage: loxtep link <project_id|name> [--path <dir>]");
207
238
  process.exitCode = 1;
208
239
  break;
209
240
  }
210
241
  await runProjectsLink(linkRef, {
211
- path: getArg('--path'),
212
- debug: args.includes('--debug'),
242
+ path: getArg("--path"),
243
+ debug: args.includes("--debug"),
213
244
  });
214
245
  break;
215
246
  }
216
- case 'projects':
217
- if (sub === 'list') {
247
+ case "projects":
248
+ if (sub === "list") {
218
249
  await runProjectsList({
219
- debug: args.includes('--debug'),
220
- source: getArg('--source'),
250
+ debug: args.includes("--debug"),
251
+ source: getArg("--source"),
221
252
  });
222
253
  }
223
- else if (sub === 'get' && args[2]) {
224
- await runProjectsGet(args[2], { debug: args.includes('--debug') });
254
+ else if (sub === "get" && args[2]) {
255
+ await runProjectsGet(args[2], { debug: args.includes("--debug") });
225
256
  }
226
- else if (sub === 'link' && args[2] && !args[2].startsWith('--')) {
257
+ else if (sub === "link" && args[2] && !args[2].startsWith("--")) {
227
258
  await runProjectsLink(args[2], {
228
- path: getArg('--path'),
229
- debug: args.includes('--debug'),
259
+ path: getArg("--path"),
260
+ debug: args.includes("--debug"),
230
261
  });
231
262
  }
232
- else if (sub === 'changes') {
263
+ else if (sub === "changes") {
233
264
  await runProjectsChanges({
234
- debug: args.includes('--debug'),
235
- json: args.includes('--json'),
265
+ debug: args.includes("--debug"),
266
+ json: args.includes("--json"),
236
267
  });
237
268
  }
238
- else if (sub === 'clone' && args[2] && !args[2].startsWith('--')) {
239
- const cloneDir = args[3] && !args[3].startsWith('--') ? args[3] : undefined;
269
+ else if (sub === "clone" && args[2] && !args[2].startsWith("--")) {
270
+ const cloneDir = args[3] && !args[3].startsWith("--") ? args[3] : undefined;
240
271
  await runProjectsClone(args[2], cloneDir, {
241
- debug: args.includes('--debug'),
272
+ debug: args.includes("--debug"),
242
273
  });
243
274
  }
244
- else if (sub === 'pull') {
275
+ else if (sub === "pull") {
245
276
  await runProjectsGithubPullCmd({
246
- debug: args.includes('--debug'),
247
- projectId: getArg('--project-id'),
248
- commitSha: getArg('--commit-sha'),
277
+ debug: args.includes("--debug"),
278
+ projectId: getArg("--project-id"),
279
+ commitSha: getArg("--commit-sha"),
249
280
  });
250
281
  }
251
- else if (sub === 'push') {
282
+ else if (sub === "push") {
252
283
  await runProjectsGithubPushCmd({
253
- debug: args.includes('--debug'),
254
- projectId: getArg('--project-id'),
255
- commitMessage: getArg('--message') ?? getArg('--commit-message'),
256
- branch: getArg('--branch'),
284
+ debug: args.includes("--debug"),
285
+ projectId: getArg("--project-id"),
286
+ commitMessage: getArg("--message") ?? getArg("--commit-message"),
287
+ branch: getArg("--branch"),
257
288
  });
258
289
  }
259
290
  else {
260
- console.error('Usage: loxtep projects list [--source local|remote|all] | projects get <id> | projects link <id|name> [--path <dir>] | projects changes [--json] | projects clone <id|name> [dir] | projects pull | projects push');
291
+ console.error("Usage: loxtep projects list [--source local|remote|all] | projects get <id> | projects link <id|name> [--path <dir>] | projects changes [--json] | projects clone <id|name> [dir] | projects pull | projects push");
261
292
  process.exitCode = 1;
262
293
  }
263
294
  break;
264
- case 'status': {
295
+ case "status": {
265
296
  // Cwd-first project workspace status — not `observe status` (bots/queues).
266
297
  await runStatus({
267
- json: args.includes('--json'),
268
- unpublished: args.includes('--unpublished'),
298
+ json: args.includes("--json"),
299
+ unpublished: args.includes("--unpublished"),
269
300
  });
270
301
  break;
271
302
  }
272
- case 'bus':
273
- if (sub === 'login') {
303
+ case "bus":
304
+ if (sub === "login") {
274
305
  await runBusLogin();
275
306
  }
276
307
  else {
277
- console.error('Usage: loxtep bus login');
308
+ console.error("Usage: loxtep bus login");
278
309
  process.exitCode = 1;
279
310
  }
280
311
  break;
281
- case 'config':
282
- if (sub === 'list') {
312
+ case "config":
313
+ if (sub === "list") {
283
314
  await runConfigList();
284
315
  }
285
- else if (sub === 'paths') {
316
+ else if (sub === "paths") {
286
317
  await runConfigPaths();
287
318
  }
288
- else if (sub === 'set' && args[2] != null) {
289
- await runConfigSet(args[2], args[3] ?? '');
319
+ else if (sub === "set" && args[2] != null) {
320
+ await runConfigSet(args[2], args[3] ?? "");
290
321
  }
291
- else if (sub === 'export') {
292
- const fromDpIdx = args.indexOf('--from-data-product');
322
+ else if (sub === "export") {
323
+ const fromDpIdx = args.indexOf("--from-data-product");
293
324
  const dpId = fromDpIdx >= 0 ? args[fromDpIdx + 1] : undefined;
294
- const fromConnIdx = args.indexOf('--from-connector');
325
+ const fromConnIdx = args.indexOf("--from-connector");
295
326
  const connId = fromConnIdx >= 0 ? args[fromConnIdx + 1] : undefined;
296
- const fmtArg = getArg('--format');
297
- const format = fmtArg === 'json' ? 'json' : fmtArg === 'env' ? 'env' : 'sh';
327
+ const fmtArg = getArg("--format");
328
+ const format = fmtArg === "json"
329
+ ? "json"
330
+ : fmtArg === "env"
331
+ ? "env"
332
+ : "sh";
298
333
  if (connId) {
299
334
  await runConfigExportFromConnector(connId, { format });
300
335
  }
@@ -302,47 +337,47 @@ export async function runCli(argv) {
302
337
  await runConfigExportFromDataProduct(dpId, { format });
303
338
  }
304
339
  else {
305
- console.error('Usage: loxtep config export --from-connector <id> [--format sh|json|env]\n loxtep config export --from-data-product <id> [--format sh|json|env]');
340
+ console.error("Usage: loxtep config export --from-connector <id> [--format sh|json|env]\n loxtep config export --from-data-product <id> [--format sh|json|env]");
306
341
  process.exitCode = 1;
307
342
  }
308
343
  }
309
344
  else {
310
- console.error('Usage: loxtep config list | loxtep config paths | loxtep config set <key> <value> | loxtep config export --from-connector <id> | loxtep config export --from-data-product <id>');
345
+ console.error("Usage: loxtep config list | loxtep config paths | loxtep config set <key> <value> | loxtep config export --from-connector <id> | loxtep config export --from-data-product <id>");
311
346
  process.exitCode = 1;
312
347
  }
313
348
  break;
314
- case 'data-products':
315
- if (sub === 'list') {
316
- await runDataProductsList({ debug: args.includes('--debug') });
349
+ case "data-products":
350
+ if (sub === "list") {
351
+ await runDataProductsList({ debug: args.includes("--debug") });
317
352
  }
318
- else if (sub === 'get' && args[2]) {
353
+ else if (sub === "get" && args[2]) {
319
354
  await runDataProductsGet(args[2]);
320
355
  }
321
- else if (sub === 'query' && args[2]) {
322
- const fileIdx = args.indexOf('--file');
356
+ else if (sub === "query" && args[2]) {
357
+ const fileIdx = args.indexOf("--file");
323
358
  const sql = fileIdx >= 0
324
359
  ? undefined
325
360
  : args
326
361
  .slice(3)
327
- .join(' ')
328
- .replace(/^["']|["']$/g, '');
362
+ .join(" ")
363
+ .replace(/^["']|["']$/g, "");
329
364
  if (fileIdx >= 0) {
330
- const fs = await import('fs/promises');
365
+ const fs = await import("fs/promises");
331
366
  const path = args[fileIdx + 1];
332
367
  if (!path) {
333
- console.error('Usage: loxtep data-products query <id> --file <path>');
368
+ console.error("Usage: loxtep data-products query <id> --file <path>");
334
369
  process.exitCode = 1;
335
370
  }
336
371
  else {
337
- const sqlFromFile = (await fs.readFile(path, 'utf-8')).trim();
372
+ const sqlFromFile = (await fs.readFile(path, "utf-8")).trim();
338
373
  await runDataProductsQuery(args[2], sqlFromFile, {
339
- receipt: args.includes('--receipt') || args.includes('--json'),
374
+ receipt: args.includes("--receipt") || args.includes("--json"),
340
375
  });
341
376
  }
342
377
  }
343
378
  else if (sql) {
344
379
  await runDataProductsQuery(args[2], sql, {
345
- receipt: args.includes('--receipt') || args.includes('--json'),
380
+ receipt: args.includes("--receipt") || args.includes("--json"),
346
381
  });
347
382
  }
348
383
  else {
@@ -350,59 +385,67 @@ export async function runCli(argv) {
350
385
  process.exitCode = 1;
351
386
  }
352
387
  }
353
- else if (sub === 'tables' && args[2]) {
388
+ else if (sub === "tables" && args[2]) {
354
389
  await runDataProductsTables(args[2]);
355
390
  }
356
- else if (sub === 'create') {
357
- const name = getArg('--name');
358
- const domainId = getArg('--domain-id');
359
- const kind = getArg('--kind');
360
- const description = getArg('--description');
361
- if (!name || !domainId || !kind || !['source', 'consumer'].includes(kind)) {
362
- console.error('Usage: loxtep data-products create --name <name> --domain-id <uuid> --kind <source|consumer> [--description <text>]');
391
+ else if (sub === "create") {
392
+ const name = getArg("--name");
393
+ const domainId = getArg("--domain-id");
394
+ const kind = getArg("--kind");
395
+ const description = getArg("--description");
396
+ if (!name ||
397
+ !domainId ||
398
+ !kind ||
399
+ !["source", "consumer"].includes(kind)) {
400
+ console.error("Usage: loxtep data-products create --name <name> --domain-id <uuid> --kind <source|consumer> [--description <text>]");
363
401
  process.exitCode = 1;
364
402
  }
365
403
  else {
366
- await runDataProductsCreate({ name, domain_id: domainId, kind, description });
404
+ await runDataProductsCreate({
405
+ name,
406
+ domain_id: domainId,
407
+ kind,
408
+ description,
409
+ });
367
410
  }
368
411
  }
369
- else if (sub === 'readiness' && args[2]) {
412
+ else if (sub === "readiness" && args[2]) {
370
413
  await runDataProductsReadiness(args[2]);
371
414
  }
372
- else if (sub === 'promote' && args[2]) {
373
- const target = getArg('--target');
374
- if (!target || !['silver', 'gold'].includes(target)) {
375
- console.error('Usage: loxtep data-products promote <id> --target <silver|gold>');
415
+ else if (sub === "promote" && args[2]) {
416
+ const target = getArg("--target");
417
+ if (!target || !["silver", "gold"].includes(target)) {
418
+ console.error("Usage: loxtep data-products promote <id> --target <silver|gold>");
376
419
  process.exitCode = 1;
377
420
  }
378
421
  else {
379
422
  await runDataProductsPromote(args[2], target);
380
423
  }
381
424
  }
382
- else if (sub === 'iceberg') {
425
+ else if (sub === "iceberg") {
383
426
  await runDataPlaneIceberg(args.slice(2));
384
427
  }
385
- else if (sub === 'export' && args[2]) {
428
+ else if (sub === "export" && args[2]) {
386
429
  await runDataPlaneExport(args.slice(2));
387
430
  }
388
- else if (sub === 'primary-entity' && args[2]) {
389
- await runPrimaryEntity(args[2], { json: args.includes('--json') });
431
+ else if (sub === "primary-entity" && args[2]) {
432
+ await runPrimaryEntity(args[2], { json: args.includes("--json") });
390
433
  }
391
434
  else {
392
435
  console.error('Usage: loxtep data-products list | get <id> | create --name ... --domain-id ... | query <id> "SQL" [--receipt] | tables <id> | iceberg ... | export <id> --start <eid> | primary-entity <id>');
393
436
  process.exitCode = 1;
394
437
  }
395
438
  break;
396
- case 'metrics':
397
- if (sub === 'rate-limits') {
439
+ case "metrics":
440
+ if (sub === "rate-limits") {
398
441
  await runMetricsRateLimits();
399
442
  }
400
- else if (sub === 'log') {
401
- const id = getArg('--id');
402
- const valueStr = getArg('--value');
443
+ else if (sub === "log") {
444
+ const id = getArg("--id");
445
+ const valueStr = getArg("--value");
403
446
  const value = valueStr != null ? Number(valueStr) : NaN;
404
447
  if (!id || Number.isNaN(value)) {
405
- console.error('Usage: loxtep metrics log --id <id> --value <number> [--tags k=v,...]');
448
+ console.error("Usage: loxtep metrics log --id <id> --value <number> [--tags k=v,...]");
406
449
  process.exitCode = 1;
407
450
  }
408
451
  else {
@@ -410,57 +453,62 @@ export async function runCli(argv) {
410
453
  }
411
454
  }
412
455
  else {
413
- console.error('Usage: loxtep metrics rate-limits | loxtep metrics log --id <id> --value <n>');
456
+ console.error("Usage: loxtep metrics rate-limits | loxtep metrics log --id <id> --value <n>");
414
457
  process.exitCode = 1;
415
458
  }
416
459
  break;
417
- case 'queue':
418
- if (sub === 'info') {
419
- const queueIdx = args.indexOf('--queue');
460
+ case "queue":
461
+ if (sub === "info") {
462
+ const queueIdx = args.indexOf("--queue");
420
463
  const idOrName = queueIdx >= 0 ? args[queueIdx + 1] : args[2];
421
464
  if (!idOrName) {
422
- console.error('Usage: loxtep queue info <data-product-id> | loxtep queue info --queue <queue-name>');
465
+ console.error("Usage: loxtep queue info <data-product-id> | loxtep queue info --queue <queue-name>");
423
466
  process.exitCode = 1;
424
467
  }
425
468
  else {
426
- await runQueueInfo(idOrName, { queueName: queueIdx >= 0, instanceId: getArg('--instance') });
469
+ await runQueueInfo(idOrName, {
470
+ queueName: queueIdx >= 0,
471
+ instanceId: getArg("--instance"),
472
+ });
427
473
  }
428
474
  }
429
- else if (sub === 'checkpoint' && args[2]) {
430
- const botIdx = args.indexOf('--bot');
475
+ else if (sub === "checkpoint" && args[2]) {
476
+ const botIdx = args.indexOf("--bot");
431
477
  const botId = botIdx >= 0 ? args[botIdx + 1] : undefined;
432
478
  if (!botId) {
433
- console.error('Usage: loxtep queue checkpoint <data-product-id> --bot <bot-id>');
479
+ console.error("Usage: loxtep queue checkpoint <data-product-id> --bot <bot-id>");
434
480
  process.exitCode = 1;
435
481
  }
436
482
  else {
437
- await runQueueCheckpoint(args[2], botId, { instanceId: getArg('--instance') });
483
+ await runQueueCheckpoint(args[2], botId, {
484
+ instanceId: getArg("--instance"),
485
+ });
438
486
  }
439
487
  }
440
488
  else {
441
- console.error('Usage: loxtep queue info <id> | loxtep queue checkpoint <id> --bot <bot-id>');
489
+ console.error("Usage: loxtep queue info <id> | loxtep queue checkpoint <id> --bot <bot-id>");
442
490
  process.exitCode = 1;
443
491
  }
444
492
  break;
445
- case 'workflows':
446
- if (sub === 'list') {
493
+ case "workflows":
494
+ if (sub === "list") {
447
495
  await runWorkflowsList({
448
- project_id: getArg('--project-id'),
449
- debug: args.includes('--debug'),
496
+ project_id: getArg("--project-id"),
497
+ debug: args.includes("--debug"),
450
498
  });
451
499
  }
452
- else if (sub === 'get' && args[2]) {
500
+ else if (sub === "get" && args[2]) {
453
501
  await runWorkflowsGet(args[2]);
454
502
  }
455
- else if (sub === 'create') {
456
- const name = getArg('--name');
457
- const projectId = getArg('--project-id');
458
- const templateId = getArg('--template-id');
459
- const description = getArg('--description');
460
- const workflowType = getArg('--workflow-type');
461
- const domainId = getArg('--domain-id');
503
+ else if (sub === "create") {
504
+ const name = getArg("--name");
505
+ const projectId = getArg("--project-id");
506
+ const templateId = getArg("--template-id");
507
+ const description = getArg("--description");
508
+ const workflowType = getArg("--workflow-type");
509
+ const domainId = getArg("--domain-id");
462
510
  if (!name || !projectId) {
463
- console.error('Usage: loxtep workflows create --name <name> --project-id <id> [--workflow-type ingestion|enrichment|delivery] [--domain-id <id>] [--template-id <id>] [--description <text>]');
511
+ console.error("Usage: loxtep workflows create --name <name> --project-id <id> [--workflow-type ingestion|enrichment|delivery] [--domain-id <id>] [--template-id <id>] [--description <text>]");
464
512
  process.exitCode = 1;
465
513
  }
466
514
  else {
@@ -474,13 +522,13 @@ export async function runCli(argv) {
474
522
  });
475
523
  }
476
524
  }
477
- else if (sub === 'deploy') {
478
- const projectId = getArg('--project-id');
479
- const instanceId = getArg('--instance-id');
480
- const versionId = getArg('--version-id');
481
- const force = args.includes('--force');
525
+ else if (sub === "deploy") {
526
+ const projectId = getArg("--project-id");
527
+ const instanceId = getArg("--instance-id");
528
+ const versionId = getArg("--version-id");
529
+ const force = args.includes("--force");
482
530
  if (!projectId) {
483
- console.error('Usage: loxtep workflows deploy --project-id <id> [--instance-id <id>] [--version-id <id>] [--force]');
531
+ console.error("Usage: loxtep workflows deploy --project-id <id> [--instance-id <id>] [--version-id <id>] [--force]");
484
532
  process.exitCode = 1;
485
533
  }
486
534
  else {
@@ -492,51 +540,52 @@ export async function runCli(argv) {
492
540
  });
493
541
  }
494
542
  }
495
- else if (sub === 'preview-query-trigger') {
496
- const workflowId = getArg('--workflow-id');
497
- const query = getArg('--query');
498
- const limitRaw = getArg('--limit');
499
- const primaryKeyRaw = getArg('--primary-key');
543
+ else if (sub === "preview-query-trigger") {
544
+ const workflowId = getArg("--workflow-id");
545
+ const query = getArg("--query");
546
+ const limitRaw = getArg("--limit");
547
+ const primaryKeyRaw = getArg("--primary-key");
500
548
  const primary_key = primaryKeyRaw
501
549
  ? primaryKeyRaw
502
- .split(',')
550
+ .split(",")
503
551
  .map((s) => s.trim())
504
552
  .filter(Boolean)
505
553
  : undefined;
506
- const limit = limitRaw != null && limitRaw !== '' ? Number(limitRaw) : undefined;
507
- if (!workflowId || (limitRaw != null && limitRaw !== '' && Number.isNaN(limit))) {
508
- console.error('Usage: loxtep workflows preview-query-trigger --workflow-id <uuid> [--project-id <uuid>] [--query <sql>] [--limit N] [--primary-key a,b]');
554
+ const limit = limitRaw != null && limitRaw !== "" ? Number(limitRaw) : undefined;
555
+ if (!workflowId ||
556
+ (limitRaw != null && limitRaw !== "" && Number.isNaN(limit))) {
557
+ console.error("Usage: loxtep workflows preview-query-trigger --workflow-id <uuid> [--project-id <uuid>] [--query <sql>] [--limit N] [--primary-key a,b]");
509
558
  process.exitCode = 1;
510
559
  }
511
560
  else {
512
561
  await runWorkflowsPreviewQueryTrigger({
513
562
  workflow_id: workflowId,
514
- project_id: getArg('--project-id'),
563
+ project_id: getArg("--project-id"),
515
564
  query,
516
565
  primary_key,
517
566
  limit,
518
567
  });
519
568
  }
520
569
  }
521
- else if (sub === 'run-query-trigger') {
522
- const workflowId = getArg('--workflow-id');
523
- const query = getArg('--query');
524
- const primaryKeyRaw = getArg('--primary-key');
570
+ else if (sub === "run-query-trigger") {
571
+ const workflowId = getArg("--workflow-id");
572
+ const query = getArg("--query");
573
+ const primaryKeyRaw = getArg("--primary-key");
525
574
  const primary_key = primaryKeyRaw
526
575
  ? primaryKeyRaw
527
- .split(',')
576
+ .split(",")
528
577
  .map((s) => s.trim())
529
578
  .filter(Boolean)
530
579
  : undefined;
531
- const sinkDataProductId = getArg('--sink-data-product-id');
580
+ const sinkDataProductId = getArg("--sink-data-product-id");
532
581
  if (!workflowId) {
533
- console.error('Usage: loxtep workflows run-query-trigger --workflow-id <uuid> [--project-id <uuid>] [--sink-data-product-id <uuid>]');
582
+ console.error("Usage: loxtep workflows run-query-trigger --workflow-id <uuid> [--project-id <uuid>] [--sink-data-product-id <uuid>]");
534
583
  process.exitCode = 1;
535
584
  }
536
585
  else {
537
586
  await runWorkflowsRunQueryTrigger({
538
587
  workflow_id: workflowId,
539
- project_id: getArg('--project-id'),
588
+ project_id: getArg("--project-id"),
540
589
  query,
541
590
  primary_key,
542
591
  sink_data_product_id: sinkDataProductId,
@@ -544,168 +593,173 @@ export async function runCli(argv) {
544
593
  }
545
594
  }
546
595
  else {
547
- console.error('Usage: loxtep workflows list [--project-id <id>] | get <id> | create --name <name> --project-id <id> | deploy --project-id <id> --instance-id <id> | preview-query-trigger --workflow-id <uuid> | run-query-trigger --workflow-id <uuid>');
596
+ console.error("Usage: loxtep workflows list [--project-id <id>] | get <id> | create --name <name> --project-id <id> | deploy --project-id <id> --instance-id <id> | preview-query-trigger --workflow-id <uuid> | run-query-trigger --workflow-id <uuid>");
548
597
  process.exitCode = 1;
549
598
  }
550
599
  break;
551
- case 'bundle':
552
- if (sub === 'save') {
600
+ case "bundle":
601
+ if (sub === "save") {
553
602
  await runBundleSave({
554
- file: getArg('--file'),
555
- project_id: getArg('--project-id'),
556
- dry_run: args.includes('--dry-run'),
603
+ file: getArg("--file"),
604
+ project_id: getArg("--project-id"),
605
+ dry_run: args.includes("--dry-run"),
557
606
  });
558
607
  }
559
608
  else {
560
- console.error('Usage: loxtep bundle save [--file .loxtep/sdk-ingest-bundle.json] [--project-id <id>] [--dry-run]');
609
+ console.error("Usage: loxtep bundle save [--file .loxtep/sdk-ingest-bundle.json] [--project-id <id>] [--dry-run]");
561
610
  process.exitCode = 1;
562
611
  }
563
612
  break;
564
- case 'ingest':
565
- if (sub === 'create' || sub === 'provision') {
566
- if (sub === 'provision') {
567
- console.error('Note: `loxtep ingest provision` is deprecated; use `loxtep ingest create`.');
613
+ case "ingest":
614
+ if (sub === "create" || sub === "provision") {
615
+ if (sub === "provision") {
616
+ console.error("Note: `loxtep ingest provision` is deprecated; use `loxtep ingest create`.");
568
617
  }
569
618
  await runIngestCreate({
570
- name: getArg('--name'),
571
- domain_id: getArg('--domain-id'),
572
- workflow_name: getArg('--workflow-name'),
573
- project_id: getArg('--project-id'),
574
- instance_id: getArg('--instance-id'),
575
- connector_id: getArg('--connector-id'),
576
- dry_run: args.includes('--dry-run'),
577
- deploy: args.includes('--deploy'),
578
- no_deploy: args.includes('--no-deploy'),
579
- iceberg: args.includes('--iceberg'),
619
+ name: getArg("--name"),
620
+ domain_id: getArg("--domain-id"),
621
+ workflow_name: getArg("--workflow-name"),
622
+ project_id: getArg("--project-id"),
623
+ instance_id: getArg("--instance-id"),
624
+ connector_id: getArg("--connector-id"),
625
+ dry_run: args.includes("--dry-run"),
626
+ deploy: args.includes("--deploy"),
627
+ no_deploy: args.includes("--no-deploy"),
628
+ iceberg: args.includes("--iceberg"),
629
+ transport_mode: getArg("--transport-mode"),
580
630
  });
581
631
  }
582
632
  else {
583
- console.error('Usage: loxtep ingest create [--name app-events] [--domain-id <id>] [--connector-id <id>] [--iceberg] [--dry-run] [--deploy]');
633
+ console.error("Usage: loxtep ingest create [--name app-events] [--domain-id <id>] [--connector-id <id>] [--transport-mode default|fast|volume] [--iceberg] [--dry-run] [--deploy]");
584
634
  process.exitCode = 1;
585
635
  }
586
636
  break;
587
- case 'transform':
588
- if (sub === 'create') {
589
- const from = getArg('--from');
637
+ case "transform":
638
+ if (sub === "create") {
639
+ const from = getArg("--from");
590
640
  if (!from) {
591
- console.error('Usage: loxtep transform create --from <upstream-dp> [--name cleaned-…] [--domain-id <id>] [--dry-run]');
641
+ console.error("Usage: loxtep transform create --from <upstream-dp> [--name cleaned-…] [--domain-id <id>] [--transport-mode default|fast|volume] [--dry-run]");
592
642
  process.exitCode = 1;
593
643
  }
594
644
  else {
595
645
  await runTransformCreate({
596
646
  from,
597
- name: getArg('--name'),
598
- project_id: getArg('--project-id'),
599
- domain_id: getArg('--domain-id'),
600
- dry_run: args.includes('--dry-run'),
647
+ name: getArg("--name"),
648
+ project_id: getArg("--project-id"),
649
+ domain_id: getArg("--domain-id"),
650
+ dry_run: args.includes("--dry-run"),
651
+ transport_mode: getArg("--transport-mode"),
601
652
  });
602
653
  }
603
654
  }
604
655
  else {
605
- console.error('Usage: loxtep transform create --from <upstream-dp> [--name cleaned-…] [--dry-run]');
656
+ console.error("Usage: loxtep transform create --from <upstream-dp> [--name cleaned-…] [--transport-mode default|fast|volume] [--dry-run]");
606
657
  process.exitCode = 1;
607
658
  }
608
659
  break;
609
- case 'delivery':
610
- if (sub === 'create') {
611
- const from = getArg('--from');
612
- const connectorId = getArg('--connector-id');
660
+ case "delivery":
661
+ if (sub === "create") {
662
+ const from = getArg("--from");
663
+ const connectorId = getArg("--connector-id");
613
664
  if (!from || !connectorId) {
614
- console.error('Usage: loxtep delivery create --from <dp-name> --connector-id <id> [--table schema.table] [--name …] [--dry-run]');
665
+ console.error("Usage: loxtep delivery create --from <dp-name> --connector-id <id> [--table schema.table] [--name …] [--transport-mode default|fast|volume] [--dry-run]");
615
666
  process.exitCode = 1;
616
667
  }
617
668
  else {
618
669
  await runDeliveryCreate({
619
670
  from,
620
671
  connector_id: connectorId,
621
- name: getArg('--name'),
622
- project_id: getArg('--project-id'),
623
- domain_id: getArg('--domain-id'),
624
- table: getArg('--table'),
625
- schema: getArg('--schema'),
626
- primary_key: getArg('--primary-key'),
627
- dry_run: args.includes('--dry-run'),
672
+ name: getArg("--name"),
673
+ project_id: getArg("--project-id"),
674
+ domain_id: getArg("--domain-id"),
675
+ table: getArg("--table"),
676
+ schema: getArg("--schema"),
677
+ primary_key: getArg("--primary-key"),
678
+ dry_run: args.includes("--dry-run"),
679
+ transport_mode: getArg("--transport-mode"),
628
680
  });
629
681
  }
630
682
  }
631
683
  else {
632
- console.error('Usage: loxtep delivery create --from <dp-name> --connector-id <id> [--table schema.table] [--name …] [--dry-run]');
684
+ console.error("Usage: loxtep delivery create --from <dp-name> --connector-id <id> [--table schema.table] [--name …] [--transport-mode default|fast|volume] [--dry-run]");
633
685
  process.exitCode = 1;
634
686
  }
635
687
  break;
636
- case 'push':
688
+ case "push":
637
689
  await runPush({
638
- project_id: getArg('--project-id'),
639
- workflow_id: getArg('--workflow-id'),
640
- dry_run: args.includes('--dry-run'),
641
- skip_reindex: args.includes('--skip-reindex'),
690
+ project_id: getArg("--project-id"),
691
+ workflow_id: getArg("--workflow-id"),
692
+ dry_run: args.includes("--dry-run"),
693
+ skip_reindex: args.includes("--skip-reindex"),
642
694
  });
643
695
  break;
644
- case 'connectors':
645
- if (sub === 'list') {
646
- await runConnectorsList({ type: getArg('--type') }, { debug: args.includes('--debug') });
696
+ case "connectors":
697
+ if (sub === "list") {
698
+ await runConnectorsList({ type: getArg("--type") }, { debug: args.includes("--debug") });
647
699
  }
648
- else if (sub === 'test' && args[2]) {
649
- await runConnectorsTest(args[2], { debug: args.includes('--debug') });
700
+ else if (sub === "test" && args[2]) {
701
+ await runConnectorsTest(args[2], { debug: args.includes("--debug") });
650
702
  }
651
- else if ((sub === 'list-entities' || sub === 'list_entities') &&
703
+ else if ((sub === "list-entities" || sub === "list_entities") &&
652
704
  args[2]) {
653
- await runConnectorsListEntities(args[2], { debug: args.includes('--debug') });
705
+ await runConnectorsListEntities(args[2], {
706
+ debug: args.includes("--debug"),
707
+ });
654
708
  }
655
- else if ((sub === 'capture-samples' || sub === 'capture_samples') &&
709
+ else if ((sub === "capture-samples" || sub === "capture_samples") &&
656
710
  args[2]) {
657
- const limitRaw = getArg('--limit');
658
- const limit = limitRaw != null && limitRaw !== '' ? Number(limitRaw) : undefined;
711
+ const limitRaw = getArg("--limit");
712
+ const limit = limitRaw != null && limitRaw !== "" ? Number(limitRaw) : undefined;
659
713
  await runConnectorsCaptureSamples({
660
714
  connector_id: args[2],
661
- entity_type: getArg('--entity-type') ?? getArg('--entity'),
715
+ entity_type: getArg("--entity-type") ?? getArg("--entity"),
662
716
  limit: Number.isFinite(limit) ? limit : undefined,
663
- }, { debug: args.includes('--debug') });
717
+ }, { debug: args.includes("--debug") });
664
718
  }
665
719
  else {
666
720
  console.error([
667
- 'Usage:',
668
- ' loxtep connectors list [--type sdk]',
669
- ' loxtep connectors test <connector_id>',
670
- ' loxtep connectors list-entities <connector_id>',
671
- ' loxtep connectors capture-samples <connector_id> --entity-type <name> [--limit N]',
672
- ].join('\n'));
721
+ "Usage:",
722
+ " loxtep connectors list [--type sdk]",
723
+ " loxtep connectors test <connector_id>",
724
+ " loxtep connectors list-entities <connector_id>",
725
+ " loxtep connectors capture-samples <connector_id> --entity-type <name> [--limit N]",
726
+ ].join("\n"));
673
727
  process.exitCode = 1;
674
728
  }
675
729
  break;
676
- case 'observe':
677
- if (sub === 'status') {
730
+ case "observe":
731
+ if (sub === "status") {
678
732
  await runObserveStatus();
679
733
  }
680
734
  else {
681
- console.error('Usage: loxtep observe status');
735
+ console.error("Usage: loxtep observe status");
682
736
  process.exitCode = 1;
683
737
  }
684
738
  break;
685
- case 'triggers':
686
- if (sub === 'list') {
739
+ case "triggers":
740
+ if (sub === "list") {
687
741
  await runTriggersList({
688
- debug: args.includes('--debug'),
689
- project_id: getArg('--project-id'),
690
- workflow_id: getArg('--workflow-id'),
742
+ debug: args.includes("--debug"),
743
+ project_id: getArg("--project-id"),
744
+ workflow_id: getArg("--workflow-id"),
691
745
  });
692
746
  }
693
- else if (sub === 'get' && args[2]) {
747
+ else if (sub === "get" && args[2]) {
694
748
  await runTriggersGet(args[2], {
695
- project_id: getArg('--project-id'),
696
- workflow_id: getArg('--workflow-id'),
749
+ project_id: getArg("--project-id"),
750
+ workflow_id: getArg("--workflow-id"),
697
751
  });
698
752
  }
699
- else if (sub === 'create') {
700
- const name = getArg('--name');
701
- const type = getArg('--type');
702
- const key = getArg('--key');
703
- const data = getArg('--data');
704
- const projectId = getArg('--project-id');
705
- const workflowId = getArg('--workflow-id');
753
+ else if (sub === "create") {
754
+ const name = getArg("--name");
755
+ const type = getArg("--type");
756
+ const key = getArg("--key");
757
+ const data = getArg("--data");
758
+ const projectId = getArg("--project-id");
759
+ const workflowId = getArg("--workflow-id");
706
760
  if (!name || !type || !key || !projectId || !workflowId) {
707
- console.error('Usage: loxtep triggers create --project-id <id> --workflow-id <id> --name <name> --type <database|api|webhook|file> --key <key> [--data <json>]\n' +
708
- 'Prefer: loxtep ingest create');
761
+ console.error("Usage: loxtep triggers create --project-id <id> --workflow-id <id> --name <name> --type <database|api|webhook|file> --key <key> [--data <json>]\n" +
762
+ "Prefer: loxtep ingest create");
709
763
  process.exitCode = 1;
710
764
  }
711
765
  else {
@@ -713,105 +767,107 @@ export async function runCli(argv) {
713
767
  name,
714
768
  type,
715
769
  key,
716
- data: data ?? '{}',
770
+ data: data ?? "{}",
717
771
  project_id: projectId,
718
772
  workflow_id: workflowId,
719
773
  });
720
774
  }
721
775
  }
722
- else if (sub === 'test' && args[2]) {
776
+ else if (sub === "test" && args[2]) {
723
777
  await runTriggersTest(args[2], {
724
- project_id: getArg('--project-id'),
725
- workflow_id: getArg('--workflow-id'),
778
+ project_id: getArg("--project-id"),
779
+ workflow_id: getArg("--workflow-id"),
726
780
  });
727
781
  }
728
- else if (sub === 'reset-backfill' && args[2]) {
782
+ else if (sub === "reset-backfill" && args[2]) {
729
783
  await runTriggersResetBackfill(args[2], {
730
- project_id: getArg('--project-id'),
731
- instance_id: getArg('--instance-id'),
732
- rebaseline_config_hash: args.includes('--rebaseline-config-hash'),
784
+ project_id: getArg("--project-id"),
785
+ instance_id: getArg("--instance-id"),
786
+ rebaseline_config_hash: args.includes("--rebaseline-config-hash"),
733
787
  });
734
788
  }
735
789
  else {
736
- console.error('Usage: loxtep triggers list [--project-id <id>] [--workflow-id <id>] | get <id> [--project-id <id>] [--workflow-id <id>] | create --project-id <id> --workflow-id <id> --name … | test <id> | reset-backfill <connection_id> [--rebaseline-config-hash] [--project-id <id>] [--instance-id <id>]');
790
+ console.error("Usage: loxtep triggers list [--project-id <id>] [--workflow-id <id>] | get <id> [--project-id <id>] [--workflow-id <id>] | create --project-id <id> --workflow-id <id> --name … | test <id> | reset-backfill <connection_id> [--rebaseline-config-hash] [--project-id <id>] [--instance-id <id>]");
737
791
  process.exitCode = 1;
738
792
  }
739
793
  break;
740
- case 'domains':
741
- if (sub === 'list') {
742
- await runDomainsList({ debug: args.includes('--debug') });
794
+ case "domains":
795
+ if (sub === "list") {
796
+ await runDomainsList({ debug: args.includes("--debug") });
743
797
  }
744
- else if (sub === 'get' && args[2]) {
798
+ else if (sub === "get" && args[2]) {
745
799
  await runDomainsGet(args[2]);
746
800
  }
747
801
  else {
748
- console.error('Usage: loxtep domains list | loxtep domains get <id>');
802
+ console.error("Usage: loxtep domains list | loxtep domains get <id>");
749
803
  process.exitCode = 1;
750
804
  }
751
805
  break;
752
- case 'standards':
753
- if (sub === 'list') {
754
- await runStandardsList({ debug: args.includes('--debug') });
806
+ case "standards":
807
+ if (sub === "list") {
808
+ await runStandardsList({ debug: args.includes("--debug") });
755
809
  }
756
- else if (sub === 'get' && args[2]) {
810
+ else if (sub === "get" && args[2]) {
757
811
  await runStandardsGet(args[2]);
758
812
  }
759
813
  else {
760
- console.error('Usage: loxtep standards list | loxtep standards get <id>');
814
+ console.error("Usage: loxtep standards list | loxtep standards get <id>");
761
815
  process.exitCode = 1;
762
816
  }
763
817
  break;
764
- case 'data-contracts':
765
- if (sub === 'list') {
766
- await runDataContractsList({ debug: args.includes('--debug') });
818
+ case "data-contracts":
819
+ if (sub === "list") {
820
+ await runDataContractsList({ debug: args.includes("--debug") });
767
821
  }
768
- else if (sub === 'get' && args[2]) {
822
+ else if (sub === "get" && args[2]) {
769
823
  await runDataContractsGet(args[2]);
770
824
  }
771
- else if (sub === 'create') {
772
- const dpId = getArg('--data-product-id');
773
- const name = getArg('--name');
825
+ else if (sub === "create") {
826
+ const dpId = getArg("--data-product-id");
827
+ const name = getArg("--name");
774
828
  if (!dpId || !name) {
775
- console.error('Usage: loxtep data-contracts create --data-product-id <id> --name <name> [--description <text>]');
829
+ console.error("Usage: loxtep data-contracts create --data-product-id <id> --name <name> [--description <text>]");
776
830
  process.exitCode = 1;
777
831
  }
778
832
  else {
779
- const schemaVersionId = getArg('--schema-version-id');
833
+ const schemaVersionId = getArg("--schema-version-id");
780
834
  await runDataContractsCreate({
781
835
  data_product_id: dpId,
782
836
  name,
783
- description: getArg('--description'),
784
- ...(schemaVersionId ? { schema_version_id: schemaVersionId } : {}),
837
+ description: getArg("--description"),
838
+ ...(schemaVersionId
839
+ ? { schema_version_id: schemaVersionId }
840
+ : {}),
785
841
  });
786
842
  }
787
843
  }
788
- else if (sub === 'update' && args[2]) {
844
+ else if (sub === "update" && args[2]) {
789
845
  await runDataContractsUpdate(args.slice(2));
790
846
  }
791
847
  else {
792
- console.error('Usage: loxtep data-contracts list | get <id> | create --data-product-id <id> --name <name>');
793
- console.error('Bind an existing contract with PUT /dataproducts/datacontracts/{id} (schema_ref or schema_version_id).');
848
+ console.error("Usage: loxtep data-contracts list | get <id> | create --data-product-id <id> --name <name>");
849
+ console.error("Bind an existing contract with PUT /dataproducts/datacontracts/{id} (schema_ref or schema_version_id).");
794
850
  process.exitCode = 1;
795
851
  }
796
852
  break;
797
- case 'promises':
853
+ case "promises":
798
854
  console.warn('Warning: "promises" is deprecated; use "data-contracts" (same behavior).');
799
- if (sub === 'list') {
800
- await runDataContractsList({ debug: args.includes('--debug') });
855
+ if (sub === "list") {
856
+ await runDataContractsList({ debug: args.includes("--debug") });
801
857
  }
802
- else if (sub === 'get' && args[2]) {
858
+ else if (sub === "get" && args[2]) {
803
859
  await runDataContractsGet(args[2]);
804
860
  }
805
861
  else {
806
- console.error('Usage: loxtep data-contracts list | loxtep data-contracts get <id>');
862
+ console.error("Usage: loxtep data-contracts list | loxtep data-contracts get <id>");
807
863
  process.exitCode = 1;
808
864
  }
809
865
  break;
810
- case 'improvements': {
866
+ case "improvements": {
811
867
  const authResult = await requireCliClient();
812
- if (sub === 'list') {
813
- const statusFilter = getArg('--status');
814
- const workflowFilter = getArg('--workflow');
868
+ if (sub === "list") {
869
+ const statusFilter = getArg("--status");
870
+ const workflowFilter = getArg("--workflow");
815
871
  const result = await runImprovementsListCommand(authResult.client, {
816
872
  status: statusFilter,
817
873
  workflow_name: workflowFilter,
@@ -823,7 +879,7 @@ export async function runCli(argv) {
823
879
  if (result.exitCode !== 0)
824
880
  process.exitCode = result.exitCode;
825
881
  }
826
- else if (sub === 'apply' && args[2]) {
882
+ else if (sub === "apply" && args[2]) {
827
883
  const result = await runImprovementsApplyCommand(authResult.client, args[2]);
828
884
  for (const line of result.stdout)
829
885
  console.log(line);
@@ -832,7 +888,7 @@ export async function runCli(argv) {
832
888
  if (result.exitCode !== 0)
833
889
  process.exitCode = result.exitCode;
834
890
  }
835
- else if (sub === 'reject' && args[2]) {
891
+ else if (sub === "reject" && args[2]) {
836
892
  const result = await runImprovementsRejectCommand(authResult.client, args[2]);
837
893
  for (const line of result.stdout)
838
894
  console.log(line);
@@ -842,21 +898,21 @@ export async function runCli(argv) {
842
898
  process.exitCode = result.exitCode;
843
899
  }
844
900
  else {
845
- console.error('Usage: loxtep improvements list [--status proposed|applied|rejected] [--workflow <name>]\n' +
846
- ' loxtep improvements apply <id>\n' +
847
- ' loxtep improvements reject <id>');
901
+ console.error("Usage: loxtep improvements list [--status proposed|applied|rejected] [--workflow <name>]\n" +
902
+ " loxtep improvements apply <id>\n" +
903
+ " loxtep improvements reject <id>");
848
904
  process.exitCode = 1;
849
905
  }
850
906
  break;
851
907
  }
852
- case 'approvals': {
908
+ case "approvals": {
853
909
  const authResult = await requireCliClient();
854
- const orgId = getArg('--organization-id');
855
- if (sub === 'list') {
856
- const statusFilter = getArg('--status');
910
+ const orgId = getArg("--organization-id");
911
+ if (sub === "list") {
912
+ const statusFilter = getArg("--status");
857
913
  const pageFlags = parseApprovalsListNumericFlags({
858
- page: getArg('--page'),
859
- page_size: getArg('--page-size'),
914
+ page: getArg("--page"),
915
+ page_size: getArg("--page-size"),
860
916
  });
861
917
  if (!pageFlags.ok) {
862
918
  console.error(pageFlags.error);
@@ -876,11 +932,11 @@ export async function runCli(argv) {
876
932
  if (result.exitCode !== 0)
877
933
  process.exitCode = result.exitCode;
878
934
  }
879
- else if (sub === 'approve' && args[2]) {
935
+ else if (sub === "approve" && args[2]) {
880
936
  const result = await runApprovalsApproveCommand(authResult.client, args[2], {
881
937
  organization_id: orgId,
882
- response: getArg('--response'),
883
- form_response_json: getArg('--form-response'),
938
+ response: getArg("--response"),
939
+ form_response_json: getArg("--form-response"),
884
940
  });
885
941
  for (const line of result.stdout)
886
942
  console.log(line);
@@ -889,11 +945,11 @@ export async function runCli(argv) {
889
945
  if (result.exitCode !== 0)
890
946
  process.exitCode = result.exitCode;
891
947
  }
892
- else if (sub === 'reject' && args[2]) {
948
+ else if (sub === "reject" && args[2]) {
893
949
  const result = await runApprovalsRejectCommand(authResult.client, args[2], {
894
950
  organization_id: orgId,
895
- response: getArg('--response'),
896
- form_response_json: getArg('--form-response'),
951
+ response: getArg("--response"),
952
+ form_response_json: getArg("--form-response"),
897
953
  });
898
954
  for (const line of result.stdout)
899
955
  console.log(line);
@@ -903,16 +959,16 @@ export async function runCli(argv) {
903
959
  process.exitCode = result.exitCode;
904
960
  }
905
961
  else {
906
- console.error('Usage: loxtep approvals list [--status pending|approved|rejected|expired] [--page N] [--page-size N] [--organization-id <id>]\n' +
907
- ' loxtep approvals approve <approval_request_id> [--response <val>] [--form-response <json>] [--organization-id <id>]\n' +
908
- ' loxtep approvals reject <approval_request_id> [--response <val>] [--form-response <json>] [--organization-id <id>]');
962
+ console.error("Usage: loxtep approvals list [--status pending|approved|rejected|expired] [--page N] [--page-size N] [--organization-id <id>]\n" +
963
+ " loxtep approvals approve <approval_request_id> [--response <val>] [--form-response <json>] [--organization-id <id>]\n" +
964
+ " loxtep approvals reject <approval_request_id> [--response <val>] [--form-response <json>] [--organization-id <id>]");
909
965
  process.exitCode = 1;
910
966
  }
911
967
  break;
912
968
  }
913
- case 'ontology': {
969
+ case "ontology": {
914
970
  const authResult = await requireCliClient();
915
- if (sub === 'link-class') {
971
+ if (sub === "link-class") {
916
972
  const result = await runOntologyLinkClassCommand(authResult.client, args);
917
973
  for (const line of result.stdout)
918
974
  console.log(line);
@@ -922,15 +978,15 @@ export async function runCli(argv) {
922
978
  process.exitCode = result.exitCode;
923
979
  }
924
980
  else {
925
- console.error('Usage: loxtep ontology link-class --source-uri <uri> --predicate-uri <uri> --target-uri <uri> [--description <text>] [--organization-id <id>]');
981
+ console.error("Usage: loxtep ontology link-class --source-uri <uri> --predicate-uri <uri> --target-uri <uri> [--description <text>] [--organization-id <id>]");
926
982
  process.exitCode = 1;
927
983
  }
928
984
  break;
929
985
  }
930
- case 'packs': {
986
+ case "packs": {
931
987
  const authResult = await requireCliClient();
932
- const orgId = getArg('--organization-id');
933
- if (sub === 'list') {
988
+ const orgId = getArg("--organization-id");
989
+ if (sub === "list") {
934
990
  const result = await runPacksListCommand(authResult.client);
935
991
  for (const line of result.stdout)
936
992
  console.log(line);
@@ -939,7 +995,7 @@ export async function runCli(argv) {
939
995
  if (result.exitCode !== 0)
940
996
  process.exitCode = result.exitCode;
941
997
  }
942
- else if (sub === 'activate' && args[2]) {
998
+ else if (sub === "activate" && args[2]) {
943
999
  const result = await runPacksActivateCommand(authResult.client, args[2], {
944
1000
  organization_id: orgId,
945
1001
  });
@@ -950,7 +1006,7 @@ export async function runCli(argv) {
950
1006
  if (result.exitCode !== 0)
951
1007
  process.exitCode = result.exitCode;
952
1008
  }
953
- else if (sub === 'status') {
1009
+ else if (sub === "status") {
954
1010
  const result = await runPacksStatusCommand(authResult.client);
955
1011
  for (const line of result.stdout)
956
1012
  console.log(line);
@@ -960,14 +1016,14 @@ export async function runCli(argv) {
960
1016
  process.exitCode = result.exitCode;
961
1017
  }
962
1018
  else {
963
- console.error('Usage: loxtep packs list\n' +
964
- ' loxtep packs activate <pack_id> [--organization-id <id>]\n' +
965
- ' loxtep packs status');
1019
+ console.error("Usage: loxtep packs list\n" +
1020
+ " loxtep packs activate <pack_id> [--organization-id <id>]\n" +
1021
+ " loxtep packs status");
966
1022
  process.exitCode = 1;
967
1023
  }
968
1024
  break;
969
1025
  }
970
- case 'proposals': {
1026
+ case "proposals": {
971
1027
  const authResult = await requireCliClient();
972
1028
  const printResult = (result) => {
973
1029
  for (const line of result.stdout)
@@ -977,30 +1033,30 @@ export async function runCli(argv) {
977
1033
  if (result.exitCode !== 0)
978
1034
  process.exitCode = result.exitCode;
979
1035
  };
980
- if (sub === 'list') {
981
- const page = getArg('--page');
982
- const pageSize = getArg('--page-size');
1036
+ if (sub === "list") {
1037
+ const page = getArg("--page");
1038
+ const pageSize = getArg("--page-size");
983
1039
  printResult(await runProposalsListCommand(authResult.client, {
984
- disposition: getArg('--disposition') ?? 'pending',
985
- proposal_type: getArg('--proposal-type'),
986
- data_product_id: getArg('--data-product-id'),
1040
+ disposition: getArg("--disposition") ?? "pending",
1041
+ proposal_type: getArg("--proposal-type"),
1042
+ data_product_id: getArg("--data-product-id"),
987
1043
  page: page ? Number(page) : undefined,
988
1044
  page_size: pageSize ? Number(pageSize) : undefined,
989
1045
  }));
990
1046
  }
991
- else if (sub === 'accept' && args[2]) {
1047
+ else if (sub === "accept" && args[2]) {
992
1048
  printResult(await runProposalsAcceptCommand(authResult.client, args[2], {
993
- definition: getArg('--definition'),
994
- resolution_note: getArg('--resolution-note'),
1049
+ definition: getArg("--definition"),
1050
+ resolution_note: getArg("--resolution-note"),
995
1051
  }));
996
1052
  }
997
- else if (sub === 'reject' && args[2]) {
1053
+ else if (sub === "reject" && args[2]) {
998
1054
  printResult(await runProposalsRejectCommand(authResult.client, args[2], {
999
- resolution_note: getArg('--resolution-note'),
1055
+ resolution_note: getArg("--resolution-note"),
1000
1056
  }));
1001
1057
  }
1002
- else if (sub === 'infer-definitions') {
1003
- const ids = args.slice(2).filter(a => a && !a.startsWith('--'));
1058
+ else if (sub === "infer-definitions") {
1059
+ const ids = args.slice(2).filter((a) => a && !a.startsWith("--"));
1004
1060
  printResult(await runProposalsInferDefinitionsCommand(authResult.client, ids));
1005
1061
  }
1006
1062
  else {
@@ -1009,7 +1065,7 @@ export async function runCli(argv) {
1009
1065
  }
1010
1066
  break;
1011
1067
  }
1012
- case 'define': {
1068
+ case "define": {
1013
1069
  const authResult = await requireCliClient();
1014
1070
  const printResult = (result) => {
1015
1071
  for (const line of result.stdout)
@@ -1019,58 +1075,58 @@ export async function runCli(argv) {
1019
1075
  if (result.exitCode !== 0)
1020
1076
  process.exitCode = result.exitCode;
1021
1077
  };
1022
- if (sub === 'status' && args[2]) {
1078
+ if (sub === "status" && args[2]) {
1023
1079
  printResult(await runDefineStatusCommand(authResult.client, args[2]));
1024
1080
  }
1025
- else if (sub === 'evidence' && args[2]) {
1081
+ else if (sub === "evidence" && args[2]) {
1026
1082
  printResult(await runDefineEvidenceCommand(authResult.client, args[2]));
1027
1083
  }
1028
- else if (sub === 'list') {
1084
+ else if (sub === "list") {
1029
1085
  printResult(await runDefineListCommand(authResult.client, {
1030
- data_product_id: getArg('--data-product-id'),
1031
- disposition: getArg('--disposition'),
1032
- proposal_type: getArg('--proposal-type'),
1086
+ data_product_id: getArg("--data-product-id"),
1087
+ disposition: getArg("--disposition"),
1088
+ proposal_type: getArg("--proposal-type"),
1033
1089
  }));
1034
1090
  }
1035
- else if (sub === 'get' && args[2]) {
1091
+ else if (sub === "get" && args[2]) {
1036
1092
  printResult(await runDefineGetCommand(authResult.client, args[2]));
1037
1093
  }
1038
- else if (sub === 'submit-shape' && args[2]) {
1094
+ else if (sub === "submit-shape" && args[2]) {
1039
1095
  printResult(await runDefineSubmitShapeCommand(authResult.client, args[2], {
1040
- definition_json: getArg('--definition'),
1041
- rationale: getArg('--rationale'),
1042
- base_revision: getArg('--base-revision'),
1043
- evidence_refs: getArg('--evidence-refs'),
1096
+ definition_json: getArg("--definition"),
1097
+ rationale: getArg("--rationale"),
1098
+ base_revision: getArg("--base-revision"),
1099
+ evidence_refs: getArg("--evidence-refs"),
1044
1100
  }));
1045
1101
  }
1046
- else if (sub === 'submit-semantic' && args[2]) {
1102
+ else if (sub === "submit-semantic" && args[2]) {
1047
1103
  printResult(await runDefineSubmitSemanticCommand(authResult.client, args[2], {
1048
- definition_json: getArg('--definition'),
1049
- rationale: getArg('--rationale'),
1104
+ definition_json: getArg("--definition"),
1105
+ rationale: getArg("--rationale"),
1050
1106
  }));
1051
1107
  }
1052
- else if (sub === 'approve' && args[2]) {
1108
+ else if (sub === "approve" && args[2]) {
1053
1109
  printResult(await runDefineApproveCommand(authResult.client, args[2]));
1054
1110
  }
1055
- else if (sub === 'apply' && args[2]) {
1111
+ else if (sub === "apply" && args[2]) {
1056
1112
  printResult(await runDefineApplyCommand(authResult.client, args[2]));
1057
1113
  }
1058
- else if (sub === 'withdraw' && args[2]) {
1114
+ else if (sub === "withdraw" && args[2]) {
1059
1115
  printResult(await runDefineWithdrawCommand(authResult.client, args[2]));
1060
1116
  }
1061
- else if (sub === 'skill') {
1117
+ else if (sub === "skill") {
1062
1118
  printResult(await runDefineSkillCommand(authResult.client));
1063
1119
  }
1064
- else if (sub === 'start-procedure' && args[2]) {
1120
+ else if (sub === "start-procedure" && args[2]) {
1065
1121
  printResult(await runDefineStartProcedureCommand(authResult.client, args[2]));
1066
1122
  }
1067
- else if (sub === 'batch') {
1123
+ else if (sub === "batch") {
1068
1124
  printResult(await runDefineBatchCommand(authResult.client, {
1069
- data_product_ids: getArg('--data-product-ids'),
1070
- action: getArg('--action'),
1125
+ data_product_ids: getArg("--data-product-ids"),
1126
+ action: getArg("--action"),
1071
1127
  }));
1072
1128
  }
1073
- else if (sub === 'glossary' || sub === 'apply-glossary') {
1129
+ else if (sub === "glossary" || sub === "apply-glossary") {
1074
1130
  await runDefineGlossary(args.slice(1));
1075
1131
  }
1076
1132
  else {
@@ -1079,16 +1135,16 @@ export async function runCli(argv) {
1079
1135
  }
1080
1136
  break;
1081
1137
  }
1082
- case 'cdlc': {
1138
+ case "cdlc": {
1083
1139
  const authResult = await requireCliClient();
1084
- const orgId = getArg('--organization-id');
1085
- if (sub === 'transition' && args[2]) {
1140
+ const orgId = getArg("--organization-id");
1141
+ if (sub === "transition" && args[2]) {
1086
1142
  const result = await runCdlcTransitionCommand(authResult.client, args[2], {
1087
- from: getArg('--from'),
1088
- to: getArg('--to'),
1143
+ from: getArg("--from"),
1144
+ to: getArg("--to"),
1089
1145
  organization_id: orgId,
1090
- actor: getArg('--actor'),
1091
- owner: getArg('--owner'),
1146
+ actor: getArg("--actor"),
1147
+ owner: getArg("--owner"),
1092
1148
  });
1093
1149
  for (const line of result.stdout)
1094
1150
  console.log(line);
@@ -1097,10 +1153,10 @@ export async function runCli(argv) {
1097
1153
  if (result.exitCode !== 0)
1098
1154
  process.exitCode = result.exitCode;
1099
1155
  }
1100
- else if (sub === 'review-queue') {
1156
+ else if (sub === "review-queue") {
1101
1157
  const result = await runCdlcReviewQueueCommand(authResult.client, {
1102
1158
  organization_id: orgId,
1103
- domain_id: getArg('--domain-id'),
1159
+ domain_id: getArg("--domain-id"),
1104
1160
  });
1105
1161
  for (const line of result.stdout)
1106
1162
  console.log(line);
@@ -1110,21 +1166,21 @@ export async function runCli(argv) {
1110
1166
  process.exitCode = result.exitCode;
1111
1167
  }
1112
1168
  else {
1113
- console.error('Usage: loxtep cdlc transition <artifact_ref> --from <state> --to <state> [--actor <id>] [--owner <id>] [--organization-id <id>]\n' +
1114
- ' loxtep cdlc review-queue [--domain-id <id>] [--organization-id <id>]\n' +
1115
- 'States: draft | in_review | approved | deployed | retired');
1169
+ console.error("Usage: loxtep cdlc transition <artifact_ref> --from <state> --to <state> [--actor <id>] [--owner <id>] [--organization-id <id>]\n" +
1170
+ " loxtep cdlc review-queue [--domain-id <id>] [--organization-id <id>]\n" +
1171
+ "States: draft | in_review | approved | deployed | retired");
1116
1172
  process.exitCode = 1;
1117
1173
  }
1118
1174
  break;
1119
1175
  }
1120
- case 'candidates': {
1176
+ case "candidates": {
1121
1177
  const authResult = await requireCliClient();
1122
- const orgId = getArg('--organization-id');
1123
- if (sub === 'list') {
1178
+ const orgId = getArg("--organization-id");
1179
+ if (sub === "list") {
1124
1180
  const result = await runCandidatesListCommand(authResult.client, {
1125
- candidate_type: getArg('--type'),
1126
- status: getArg('--status'),
1127
- mining_run_id: getArg('--mining-run-id'),
1181
+ candidate_type: getArg("--type"),
1182
+ status: getArg("--status"),
1183
+ mining_run_id: getArg("--mining-run-id"),
1128
1184
  organization_id: orgId,
1129
1185
  });
1130
1186
  for (const line of result.stdout)
@@ -1134,12 +1190,12 @@ export async function runCli(argv) {
1134
1190
  if (result.exitCode !== 0)
1135
1191
  process.exitCode = result.exitCode;
1136
1192
  }
1137
- else if (sub === 'act' && args[2]) {
1193
+ else if (sub === "act" && args[2]) {
1138
1194
  const result = await runCandidatesActCommand(authResult.client, args[2], {
1139
- action: getArg('--action'),
1195
+ action: getArg("--action"),
1140
1196
  organization_id: orgId,
1141
- rationale: getArg('--rationale'),
1142
- actor: getArg('--actor'),
1197
+ rationale: getArg("--rationale"),
1198
+ actor: getArg("--actor"),
1143
1199
  });
1144
1200
  for (const line of result.stdout)
1145
1201
  console.log(line);
@@ -1149,28 +1205,30 @@ export async function runCli(argv) {
1149
1205
  process.exitCode = result.exitCode;
1150
1206
  }
1151
1207
  else {
1152
- console.error('Usage: loxtep candidates list [--type <type>] [--status candidate|approved|rejected] [--mining-run-id <id>] [--organization-id <id>]\n' +
1153
- ' loxtep candidates act <candidate_id> --action approve|reject [--rationale <text>] [--actor <id>] [--organization-id <id>]\n' +
1154
- 'Types: semantic_conflict | procedure | promotion | entity_fact\n' +
1155
- 'approve routes the candidate into CDLC in_review; reject discards it.');
1208
+ console.error("Usage: loxtep candidates list [--type <type>] [--status candidate|approved|rejected] [--mining-run-id <id>] [--organization-id <id>]\n" +
1209
+ " loxtep candidates act <candidate_id> --action approve|reject [--rationale <text>] [--actor <id>] [--organization-id <id>]\n" +
1210
+ "Types: semantic_conflict | procedure | promotion | entity_fact\n" +
1211
+ "approve routes the candidate into CDLC in_review; reject discards it.");
1156
1212
  process.exitCode = 1;
1157
1213
  }
1158
1214
  break;
1159
1215
  }
1160
- case 'deployments': {
1216
+ case "deployments": {
1161
1217
  const authResult = await requireCliClient();
1162
- if (sub === 'list') {
1163
- const pageStr = getArg('--page');
1164
- const pageSizeStr = getArg('--page-size');
1218
+ if (sub === "list") {
1219
+ const pageStr = getArg("--page");
1220
+ const pageSizeStr = getArg("--page-size");
1165
1221
  const page = pageStr != null ? parseInt(pageStr, 10) : undefined;
1166
1222
  const page_size = pageSizeStr != null ? parseInt(pageSizeStr, 10) : undefined;
1167
1223
  const result = await runDeploymentsListCommand(authResult.client, {
1168
- project_id: getArg('--project-id'),
1169
- instance_id: getArg('--instance-id'),
1170
- workflow_id: getArg('--workflow-id'),
1171
- status: getArg('--status'),
1224
+ project_id: getArg("--project-id"),
1225
+ instance_id: getArg("--instance-id"),
1226
+ workflow_id: getArg("--workflow-id"),
1227
+ status: getArg("--status"),
1172
1228
  page: page != null && !Number.isNaN(page) ? page : undefined,
1173
- page_size: page_size != null && !Number.isNaN(page_size) ? page_size : undefined,
1229
+ page_size: page_size != null && !Number.isNaN(page_size)
1230
+ ? page_size
1231
+ : undefined,
1174
1232
  });
1175
1233
  for (const line of result.stdout)
1176
1234
  console.log(line);
@@ -1179,9 +1237,9 @@ export async function runCli(argv) {
1179
1237
  if (result.exitCode !== 0)
1180
1238
  process.exitCode = result.exitCode;
1181
1239
  }
1182
- else if (sub === 'get' && args[2]) {
1240
+ else if (sub === "get" && args[2]) {
1183
1241
  const result = await runDeploymentsGetCommand(authResult.client, args[2], {
1184
- include_versions: args.includes('--include-versions'),
1242
+ include_versions: args.includes("--include-versions"),
1185
1243
  });
1186
1244
  for (const line of result.stdout)
1187
1245
  console.log(line);
@@ -1191,21 +1249,21 @@ export async function runCli(argv) {
1191
1249
  process.exitCode = result.exitCode;
1192
1250
  }
1193
1251
  else {
1194
- console.error('Usage: loxtep deployments list [--project-id <id>] [--instance-id <id>] [--workflow-id <id>] [--status pending|in_progress|deployed|failed|rolled_back|archived]\n' +
1195
- ' loxtep deployments get <deployment_id> [--include-versions]');
1252
+ console.error("Usage: loxtep deployments list [--project-id <id>] [--instance-id <id>] [--workflow-id <id>] [--status pending|in_progress|deployed|failed|rolled_back|archived]\n" +
1253
+ " loxtep deployments get <deployment_id> [--include-versions]");
1196
1254
  process.exitCode = 1;
1197
1255
  }
1198
1256
  break;
1199
1257
  }
1200
- case 'activity': {
1258
+ case "activity": {
1201
1259
  const authResult = await requireCliClient();
1202
- if (sub === 'list') {
1203
- const sourceFilter = getArg('--source');
1204
- const actorFilter = getArg('--actor');
1205
- const resourceTypeFilter = getArg('--resource-type');
1206
- const fromFilter = getArg('--from');
1207
- const toFilter = getArg('--to');
1208
- const limitStr = getArg('--limit');
1260
+ if (sub === "list") {
1261
+ const sourceFilter = getArg("--source");
1262
+ const actorFilter = getArg("--actor");
1263
+ const resourceTypeFilter = getArg("--resource-type");
1264
+ const fromFilter = getArg("--from");
1265
+ const toFilter = getArg("--to");
1266
+ const limitStr = getArg("--limit");
1209
1267
  const limit = limitStr != null ? parseInt(limitStr, 10) : undefined;
1210
1268
  const result = await runActivityListCommand(authResult.client, {
1211
1269
  source: sourceFilter,
@@ -1223,23 +1281,23 @@ export async function runCli(argv) {
1223
1281
  process.exitCode = result.exitCode;
1224
1282
  }
1225
1283
  else {
1226
- console.error('Usage: loxtep activity list [--source cli|sdk|mcp|ui] [--actor <id>] [--resource-type <type>] [--from <date>] [--to <date>] [--limit <n>]');
1284
+ console.error("Usage: loxtep activity list [--source cli|sdk|mcp|ui] [--actor <id>] [--resource-type <type>] [--from <date>] [--to <date>] [--limit <n>]");
1227
1285
  process.exitCode = 1;
1228
1286
  }
1229
1287
  break;
1230
1288
  }
1231
- case 'instances': {
1232
- if (sub === 'list') {
1233
- await runInstancesList({ debug: args.includes('--debug') });
1289
+ case "instances": {
1290
+ if (sub === "list") {
1291
+ await runInstancesList({ debug: args.includes("--debug") });
1234
1292
  }
1235
- else if (sub === 'get' && args[2]) {
1293
+ else if (sub === "get" && args[2]) {
1236
1294
  await runInstancesGet(args[2]);
1237
1295
  }
1238
- else if (sub === 'stream-config') {
1239
- const maybeId = args[2] && !args[2].startsWith('-') ? args[2] : undefined;
1296
+ else if (sub === "stream-config") {
1297
+ const maybeId = args[2] && !args[2].startsWith("-") ? args[2] : undefined;
1240
1298
  await runInstancesStreamConfig(maybeId);
1241
1299
  }
1242
- else if (sub === 'create') {
1300
+ else if (sub === "create") {
1243
1301
  try {
1244
1302
  const input = parseCreateInstanceArgs(args.slice(2));
1245
1303
  await runInstancesCreate(input);
@@ -1249,7 +1307,7 @@ export async function runCli(argv) {
1249
1307
  process.exitCode = 1;
1250
1308
  }
1251
1309
  }
1252
- else if (sub === 'update') {
1310
+ else if (sub === "update") {
1253
1311
  try {
1254
1312
  const { instanceId, input } = parseUpdateInstanceArgs(args.slice(2));
1255
1313
  await runInstancesUpdate(instanceId, input);
@@ -1259,121 +1317,124 @@ export async function runCli(argv) {
1259
1317
  process.exitCode = 1;
1260
1318
  }
1261
1319
  }
1262
- else if (sub === 'redeploy-runtimes' && args[2] && !args[2].startsWith('-')) {
1320
+ else if (sub === "redeploy-runtimes" &&
1321
+ args[2] &&
1322
+ !args[2].startsWith("-")) {
1263
1323
  await runInstancesRedeployRuntimes(args[2]);
1264
1324
  }
1265
- else if (sub === 'deployment-urls') {
1325
+ else if (sub === "deployment-urls") {
1266
1326
  await runInstancesDeploymentUrls();
1267
1327
  }
1268
- else if (sub === 'register') {
1269
- const roleArn = getArg('--cross-account-role-arn');
1270
- const region = getArg('--region');
1328
+ else if (sub === "register") {
1329
+ const roleArn = getArg("--cross-account-role-arn");
1330
+ const region = getArg("--region");
1271
1331
  if (!roleArn) {
1272
- console.error('Usage: loxtep instances register --cross-account-role-arn <arn> [--region <region>]');
1332
+ console.error("Usage: loxtep instances register --cross-account-role-arn <arn> [--region <region>]");
1273
1333
  process.exitCode = 1;
1274
1334
  }
1275
1335
  else {
1276
1336
  await runInstancesRegister(roleArn, region);
1277
1337
  }
1278
1338
  }
1279
- else if (sub === 'registration') {
1339
+ else if (sub === "registration") {
1280
1340
  await runInstancesRegistration();
1281
1341
  }
1282
1342
  else {
1283
- console.error('Usage: loxtep instances list | get <id> | stream-config [<id>] | create --name ... --region ... --type ... | update <id> ... | redeploy-runtimes <id> | deployment-urls | register --cross-account-role-arn <arn> | registration');
1343
+ console.error("Usage: loxtep instances list | get <id> | stream-config [<id>] | create --name ... --region ... --type ... | update <id> ... | redeploy-runtimes <id> | deployment-urls | register --cross-account-role-arn <arn> | registration");
1284
1344
  process.exitCode = 1;
1285
1345
  }
1286
1346
  break;
1287
1347
  }
1288
- case 'bots': {
1289
- const instanceFlag = getArg('--instance');
1290
- if (sub === 'list') {
1348
+ case "bots": {
1349
+ const instanceFlag = getArg("--instance");
1350
+ if (sub === "list") {
1291
1351
  await runBotsList(instanceFlag);
1292
1352
  }
1293
- else if (sub === 'get') {
1294
- const botId = getArg('--bot-id') || (args[2] && !args[2].startsWith('-') ? args[2] : undefined);
1353
+ else if (sub === "get") {
1354
+ const botId = getArg("--bot-id") ||
1355
+ (args[2] && !args[2].startsWith("-") ? args[2] : undefined);
1295
1356
  if (!botId) {
1296
- console.error('Usage: loxtep bots get --instance <id> --bot-id <bot_id>');
1357
+ console.error("Usage: loxtep bots get --instance <id> --bot-id <bot_id>");
1297
1358
  process.exitCode = 1;
1298
1359
  }
1299
1360
  else {
1300
1361
  await runBotsGet(instanceFlag, botId);
1301
1362
  }
1302
1363
  }
1303
- else if (sub === 'register') {
1304
- const name = getArg('--name');
1305
- const lambdaName = getArg('--lambda-name');
1364
+ else if (sub === "register") {
1365
+ const name = getArg("--name");
1366
+ const lambdaName = getArg("--lambda-name");
1306
1367
  if (!name || !lambdaName) {
1307
- console.error('Usage: loxtep bots register --instance <id> --name <n> --lambda-name <fn> [--slug …] [--schedule …] [--paused|--unpaused]');
1368
+ console.error("Usage: loxtep bots register --instance <id> --name <n> --lambda-name <fn> [--slug …] [--schedule …] [--paused|--unpaused]");
1308
1369
  process.exitCode = 1;
1309
1370
  }
1310
1371
  else {
1311
- const paused = args.includes('--unpaused')
1372
+ const paused = args.includes("--unpaused")
1312
1373
  ? false
1313
- : args.includes('--paused')
1374
+ : args.includes("--paused")
1314
1375
  ? true
1315
1376
  : undefined;
1316
- const batchRaw = getArg('--batch-size');
1377
+ const batchRaw = getArg("--batch-size");
1317
1378
  await runBotsRegister(instanceFlag, {
1318
1379
  name,
1319
1380
  lambda_name: lambdaName,
1320
- slug: getArg('--slug'),
1321
- description: getArg('--description'),
1322
- source_queue: getArg('--source-queue'),
1323
- destination_queue: getArg('--destination-queue'),
1324
- error_queue: getArg('--error-queue'),
1325
- schedule: getArg('--schedule'),
1381
+ slug: getArg("--slug"),
1382
+ description: getArg("--description"),
1383
+ source_queue: getArg("--source-queue"),
1384
+ destination_queue: getArg("--destination-queue"),
1385
+ error_queue: getArg("--error-queue"),
1386
+ schedule: getArg("--schedule"),
1326
1387
  batch_size: batchRaw ? Number(batchRaw) : undefined,
1327
1388
  paused,
1328
1389
  });
1329
1390
  }
1330
1391
  }
1331
- else if (sub === 'update') {
1332
- const botId = getArg('--bot-id');
1392
+ else if (sub === "update") {
1393
+ const botId = getArg("--bot-id");
1333
1394
  if (!botId) {
1334
- console.error('Usage: loxtep bots update --instance <id> --bot-id <bot_id> [--name …] [--lambda-name …] …');
1395
+ console.error("Usage: loxtep bots update --instance <id> --bot-id <bot_id> [--name …] [--lambda-name …] …");
1335
1396
  process.exitCode = 1;
1336
1397
  }
1337
1398
  else {
1338
- const paused = args.includes('--unpaused')
1399
+ const paused = args.includes("--unpaused")
1339
1400
  ? false
1340
- : args.includes('--paused')
1401
+ : args.includes("--paused")
1341
1402
  ? true
1342
1403
  : undefined;
1343
- const batchRaw = getArg('--batch-size');
1404
+ const batchRaw = getArg("--batch-size");
1344
1405
  await runBotsUpdate(instanceFlag, botId, {
1345
- name: getArg('--name'),
1346
- lambda_name: getArg('--lambda-name'),
1347
- description: getArg('--description'),
1348
- source_queue: getArg('--source-queue'),
1349
- destination_queue: getArg('--destination-queue'),
1350
- error_queue: getArg('--error-queue'),
1351
- schedule: getArg('--schedule'),
1406
+ name: getArg("--name"),
1407
+ lambda_name: getArg("--lambda-name"),
1408
+ description: getArg("--description"),
1409
+ source_queue: getArg("--source-queue"),
1410
+ destination_queue: getArg("--destination-queue"),
1411
+ error_queue: getArg("--error-queue"),
1412
+ schedule: getArg("--schedule"),
1352
1413
  batch_size: batchRaw ? Number(batchRaw) : undefined,
1353
1414
  paused,
1354
1415
  });
1355
1416
  }
1356
1417
  }
1357
- else if (sub === 'deregister') {
1358
- const botId = getArg('--bot-id');
1418
+ else if (sub === "deregister") {
1419
+ const botId = getArg("--bot-id");
1359
1420
  if (!botId) {
1360
- console.error('Usage: loxtep bots deregister --instance <id> --bot-id <bot_id>');
1421
+ console.error("Usage: loxtep bots deregister --instance <id> --bot-id <bot_id>");
1361
1422
  process.exitCode = 1;
1362
1423
  }
1363
1424
  else {
1364
1425
  await runBotsDeregister(instanceFlag, botId);
1365
1426
  }
1366
1427
  }
1367
- else if (sub === 'reconcile') {
1428
+ else if (sub === "reconcile") {
1368
1429
  await runBotsReconcile(instanceFlag);
1369
1430
  }
1370
1431
  else {
1371
- console.error('Usage: loxtep bots register|list|get|update|deregister|reconcile --instance <id> …');
1432
+ console.error("Usage: loxtep bots register|list|get|update|deregister|reconcile --instance <id> …");
1372
1433
  process.exitCode = 1;
1373
1434
  }
1374
1435
  break;
1375
1436
  }
1376
- case 'quality-rules':
1437
+ case "quality-rules":
1377
1438
  await runQualityRules(args.slice(1));
1378
1439
  break;
1379
1440
  default:
@@ -1385,7 +1446,7 @@ export async function runCli(argv) {
1385
1446
  }
1386
1447
  // Auto-run only when executed as the CLI bin (skip under Jest imports).
1387
1448
  if (process.env.JEST_WORKER_ID === undefined) {
1388
- runCli(process.argv.slice(2)).catch(err => {
1449
+ runCli(process.argv.slice(2)).catch((err) => {
1389
1450
  console.error(formatCliError(err));
1390
1451
  process.exit(1);
1391
1452
  });