@canaryai/cli 0.2.9 → 0.2.12

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 (58) hide show
  1. package/dist/{chunk-C2PGZRYK.js → chunk-CEW4BDXD.js} +26 -7
  2. package/dist/chunk-CEW4BDXD.js.map +1 -0
  3. package/dist/chunk-ERSNYLMZ.js +229 -0
  4. package/dist/chunk-ERSNYLMZ.js.map +1 -0
  5. package/dist/{chunk-XGO62PO2.js → chunk-MSMC6UXW.js} +198 -11
  6. package/dist/{chunk-XGO62PO2.js.map → chunk-MSMC6UXW.js.map} +1 -1
  7. package/dist/{chunk-LC7ZVXPH.js → chunk-Q7WFBG5C.js} +2 -2
  8. package/dist/{debug-workflow-I3F36JBL.js → debug-workflow-53ULOFJC.js} +4 -4
  9. package/dist/{docs-REHST3YB.js → docs-BEE3LOCO.js} +2 -2
  10. package/dist/{feature-flag-3HB5NTMY.js → feature-flag-CYTDV4ZB.js} +2 -2
  11. package/dist/index.js +61 -139
  12. package/dist/index.js.map +1 -1
  13. package/dist/init-M6I3MG3D.js +146 -0
  14. package/dist/init-M6I3MG3D.js.map +1 -0
  15. package/dist/{issues-YU57CHXS.js → issues-NLM72HLU.js} +2 -2
  16. package/dist/{knobs-QJ4IBLCT.js → knobs-O35GAU5M.js} +2 -2
  17. package/dist/list-4K4EIGAT.js +57 -0
  18. package/dist/list-4K4EIGAT.js.map +1 -0
  19. package/dist/local-NHXXPHZ3.js +63 -0
  20. package/dist/local-NHXXPHZ3.js.map +1 -0
  21. package/dist/{local-browser-MKTJ36KY.js → local-browser-VAZORCO3.js} +3 -3
  22. package/dist/login-ZLP64YQP.js +130 -0
  23. package/dist/login-ZLP64YQP.js.map +1 -0
  24. package/dist/{mcp-ZOKM2AUE.js → mcp-ZF5G5DCB.js} +4 -126
  25. package/dist/mcp-ZF5G5DCB.js.map +1 -0
  26. package/dist/{record-TNDBT3NY.js → record-V6QKFFH3.js} +6 -47
  27. package/dist/record-V6QKFFH3.js.map +1 -0
  28. package/dist/{release-L4IXOHDF.js → release-7TI7EIGD.js} +8 -4
  29. package/dist/release-7TI7EIGD.js.map +1 -0
  30. package/dist/{session-RNLKFS2Z.js → session-UGNJXRUW.js} +138 -70
  31. package/dist/session-UGNJXRUW.js.map +1 -0
  32. package/dist/skill-ORWAPBDW.js +424 -0
  33. package/dist/skill-ORWAPBDW.js.map +1 -0
  34. package/dist/{src-2WSMYBMJ.js → src-4VIDSK4A.js} +2 -2
  35. package/dist/start-E532F3BU.js +112 -0
  36. package/dist/start-E532F3BU.js.map +1 -0
  37. package/dist/workflow-HXIUXRFI.js +613 -0
  38. package/dist/workflow-HXIUXRFI.js.map +1 -0
  39. package/package.json +1 -1
  40. package/dist/chunk-C2PGZRYK.js.map +0 -1
  41. package/dist/chunk-DXIAHB72.js +0 -340
  42. package/dist/chunk-DXIAHB72.js.map +0 -1
  43. package/dist/chunk-QLFSJG5O.js +0 -93
  44. package/dist/chunk-QLFSJG5O.js.map +0 -1
  45. package/dist/mcp-ZOKM2AUE.js.map +0 -1
  46. package/dist/record-TNDBT3NY.js.map +0 -1
  47. package/dist/release-L4IXOHDF.js.map +0 -1
  48. package/dist/session-RNLKFS2Z.js.map +0 -1
  49. package/dist/skill-CZ7SHI3P.js +0 -156
  50. package/dist/skill-CZ7SHI3P.js.map +0 -1
  51. /package/dist/{chunk-LC7ZVXPH.js.map → chunk-Q7WFBG5C.js.map} +0 -0
  52. /package/dist/{debug-workflow-I3F36JBL.js.map → debug-workflow-53ULOFJC.js.map} +0 -0
  53. /package/dist/{docs-REHST3YB.js.map → docs-BEE3LOCO.js.map} +0 -0
  54. /package/dist/{feature-flag-3HB5NTMY.js.map → feature-flag-CYTDV4ZB.js.map} +0 -0
  55. /package/dist/{issues-YU57CHXS.js.map → issues-NLM72HLU.js.map} +0 -0
  56. /package/dist/{knobs-QJ4IBLCT.js.map → knobs-O35GAU5M.js.map} +0 -0
  57. /package/dist/{local-browser-MKTJ36KY.js.map → local-browser-VAZORCO3.js.map} +0 -0
  58. /package/dist/{src-2WSMYBMJ.js.map → src-4VIDSK4A.js.map} +0 -0
@@ -1,7 +1,7 @@
1
1
  import { createRequire as __cr } from "module"; const require = __cr(import.meta.url);
2
2
  import {
3
3
  PlaywrightClient
4
- } from "./chunk-XGO62PO2.js";
4
+ } from "./chunk-MSMC6UXW.js";
5
5
 
6
6
  // src/local-browser/host.ts
7
7
  var HEARTBEAT_INTERVAL_MS = 3e4;
@@ -370,4 +370,4 @@ var LocalBrowserHost = class {
370
370
  export {
371
371
  LocalBrowserHost
372
372
  };
373
- //# sourceMappingURL=chunk-LC7ZVXPH.js.map
373
+ //# sourceMappingURL=chunk-Q7WFBG5C.js.map
@@ -1,16 +1,16 @@
1
1
  import { createRequire as __cr } from "module"; const require = __cr(import.meta.url);
2
2
  import {
3
3
  downloadStorageState
4
- } from "./chunk-QLFSJG5O.js";
4
+ } from "./chunk-ERSNYLMZ.js";
5
5
  import {
6
6
  LocalBrowserHost
7
- } from "./chunk-LC7ZVXPH.js";
7
+ } from "./chunk-Q7WFBG5C.js";
8
8
  import {
9
9
  getArgValue,
10
10
  hasFlag,
11
11
  resolveConfig
12
12
  } from "./chunk-PWWQGYFG.js";
13
- import "./chunk-XGO62PO2.js";
13
+ import "./chunk-MSMC6UXW.js";
14
14
  import "./chunk-XAA5VQ5N.js";
15
15
  import "./chunk-P5Z2Y5VV.js";
16
16
  import "./chunk-VKVL7WBN.js";
@@ -262,4 +262,4 @@ async function runDebugWorkflow(argv) {
262
262
  export {
263
263
  runDebugWorkflow
264
264
  };
265
- //# sourceMappingURL=debug-workflow-I3F36JBL.js.map
265
+ //# sourceMappingURL=debug-workflow-53ULOFJC.js.map
@@ -2,7 +2,7 @@ import { createRequire as __cr } from "module"; const require = __cr(import.meta
2
2
  import {
3
3
  apiRequest,
4
4
  fetchList
5
- } from "./chunk-QLFSJG5O.js";
5
+ } from "./chunk-ERSNYLMZ.js";
6
6
  import {
7
7
  getArgValue,
8
8
  hasFlag,
@@ -270,4 +270,4 @@ async function runDocs(argv) {
270
270
  export {
271
271
  runDocs
272
272
  };
273
- //# sourceMappingURL=docs-REHST3YB.js.map
273
+ //# sourceMappingURL=docs-BEE3LOCO.js.map
@@ -4,7 +4,7 @@ import {
4
4
  fetchList,
5
5
  parseLifecycleStage,
6
6
  toLifecycleLabel
7
- } from "./chunk-QLFSJG5O.js";
7
+ } from "./chunk-ERSNYLMZ.js";
8
8
  import {
9
9
  getArgValue,
10
10
  hasFlag,
@@ -277,4 +277,4 @@ async function runFeatureFlag(argv) {
277
277
  export {
278
278
  runFeatureFlag
279
279
  };
280
- //# sourceMappingURL=feature-flag-3HB5NTMY.js.map
280
+ //# sourceMappingURL=feature-flag-CYTDV4ZB.js.map
package/dist/index.js CHANGED
@@ -1,11 +1,4 @@
1
1
  import { createRequire as __cr } from "module"; const require = __cr(import.meta.url);
2
- import {
3
- connectTunnel,
4
- createLocalRun,
5
- createTunnel,
6
- runLocalTest,
7
- runTunnel
8
- } from "./chunk-DXIAHB72.js";
9
2
  import {
10
3
  ENV_URLS,
11
4
  envToProfile,
@@ -27,7 +20,7 @@ import {
27
20
  // src/index.ts
28
21
  import { spawnSync as spawnSync2 } from "child_process";
29
22
  import { createRequire as createRequire2 } from "module";
30
- import process7 from "process";
23
+ import process6 from "process";
31
24
  import path4 from "path";
32
25
  import { fileURLToPath as fileURLToPath2, pathToFileURL as pathToFileURL2 } from "url";
33
26
 
@@ -547,79 +540,10 @@ async function runOrgs(argv) {
547
540
  console.log("To switch: canary login --org <name>");
548
541
  }
549
542
 
550
- // src/run-local.ts
551
- import process4 from "process";
552
- function getArgValue2(argv, key) {
553
- const index = argv.indexOf(key);
554
- if (index === -1) return void 0;
555
- return argv[index + 1];
556
- }
557
- async function runLocalSession(argv) {
558
- const apiUrl = getArgValue2(argv, "--api-url") ?? process4.env.CANARY_API_URL ?? "https://api.trycanary.ai";
559
- const token = getArgValue2(argv, "--token") ?? process4.env.CANARY_API_TOKEN ?? await readStoredToken();
560
- if (!token) {
561
- console.error("Missing token. Run `canary login` first or set CANARY_API_TOKEN.");
562
- process4.exit(1);
563
- }
564
- const portRaw = getArgValue2(argv, "--port") ?? process4.env.CANARY_LOCAL_PORT;
565
- const tunnelUrl = getArgValue2(argv, "--tunnel-url");
566
- const title = getArgValue2(argv, "--title");
567
- const featureSpec = getArgValue2(argv, "--feature");
568
- const startUrl = getArgValue2(argv, "--start-url");
569
- if (!tunnelUrl && !portRaw) {
570
- console.error("Missing --port or --tunnel-url");
571
- process4.exit(1);
572
- }
573
- let publicUrl = tunnelUrl;
574
- let ws = null;
575
- if (!publicUrl && portRaw) {
576
- const port = Number(portRaw);
577
- if (Number.isNaN(port) || port <= 0) {
578
- console.error("Invalid --port value");
579
- process4.exit(1);
580
- }
581
- const tunnel = await createTunnel({ apiUrl, token, port });
582
- publicUrl = tunnel.publicUrl;
583
- ws = connectTunnel({
584
- apiUrl,
585
- tunnelId: tunnel.tunnelId,
586
- token: tunnel.token,
587
- port,
588
- onReady: () => {
589
- console.log(`Tunnel connected: ${publicUrl ?? tunnel.tunnelId}`);
590
- }
591
- });
592
- }
593
- if (!publicUrl) {
594
- console.error("Failed to resolve tunnel URL");
595
- process4.exit(1);
596
- }
597
- const run2 = await createLocalRun({
598
- apiUrl,
599
- token,
600
- title,
601
- featureSpec,
602
- startUrl,
603
- tunnelUrl: publicUrl
604
- });
605
- console.log(`Local test queued: ${run2.runId}`);
606
- if (run2.watchUrl) {
607
- console.log(`Watch: ${run2.watchUrl}`);
608
- }
609
- if (ws) {
610
- console.log("Tunnel active. Press Ctrl+C to stop.");
611
- process4.on("SIGINT", () => {
612
- ws?.close();
613
- process4.exit(0);
614
- });
615
- await new Promise(() => void 0);
616
- }
617
- }
618
-
619
543
  // src/remote-test.ts
620
- import process5 from "process";
544
+ import process4 from "process";
621
545
  import { createParser } from "eventsource-parser";
622
- function getArgValue3(argv, key) {
546
+ function getArgValue2(argv, key) {
623
547
  const index = argv.indexOf(key);
624
548
  if (index === -1 || index >= argv.length - 1) return void 0;
625
549
  return argv[index + 1];
@@ -708,12 +632,12 @@ ${available}`
708
632
  return result;
709
633
  }
710
634
  async function runRemoteTest(argv) {
711
- const apiUrl = getArgValue3(argv, "--api-url") ?? process5.env.CANARY_API_URL ?? "https://api.trycanary.ai";
712
- const token = getArgValue3(argv, "--token") ?? process5.env.CANARY_API_TOKEN ?? await readStoredToken();
713
- const tag = getArgValue3(argv, "--tag");
714
- const namePattern = getArgValue3(argv, "--name-pattern");
715
- const propertyArg = getArgValue3(argv, "--property");
716
- const environmentArg = getArgValue3(argv, "--environment");
635
+ const apiUrl = getArgValue2(argv, "--api-url") ?? process4.env.CANARY_API_URL ?? "https://api.trycanary.ai";
636
+ const token = getArgValue2(argv, "--token") ?? process4.env.CANARY_API_TOKEN ?? await readStoredToken();
637
+ const tag = getArgValue2(argv, "--tag");
638
+ const namePattern = getArgValue2(argv, "--name-pattern");
639
+ const propertyArg = getArgValue2(argv, "--property");
640
+ const environmentArg = getArgValue2(argv, "--environment");
717
641
  const verbose = hasFlag2(argv, "--verbose", "-v");
718
642
  if (!token) {
719
643
  console.error("Error: No API token found.");
@@ -723,7 +647,7 @@ async function runRemoteTest(argv) {
723
647
  console.error("");
724
648
  console.error("Or create an API key in Settings > API Keys and pass it:");
725
649
  console.error(" canary test --remote --token cnry_...");
726
- process5.exit(1);
650
+ process4.exit(1);
727
651
  }
728
652
  let resolvedConfig = {};
729
653
  if (propertyArg || environmentArg) {
@@ -731,7 +655,7 @@ async function runRemoteTest(argv) {
731
655
  resolvedConfig = await resolveTestConfig(apiUrl, token, propertyArg, environmentArg);
732
656
  } catch (err) {
733
657
  console.error(`${err instanceof Error ? err.message : String(err)}`);
734
- process5.exit(1);
658
+ process4.exit(1);
735
659
  }
736
660
  }
737
661
  console.log("Starting remote workflow tests...");
@@ -759,18 +683,18 @@ async function runRemoteTest(argv) {
759
683
  });
760
684
  } catch (err) {
761
685
  console.error(`Failed to connect to API: ${err}`);
762
- process5.exit(1);
686
+ process4.exit(1);
763
687
  }
764
688
  if (!triggerRes.ok) {
765
689
  const errorText = await triggerRes.text();
766
690
  console.error(`Failed to start tests: ${triggerRes.status}`);
767
691
  console.error(errorText);
768
- process5.exit(1);
692
+ process4.exit(1);
769
693
  }
770
694
  const triggerData = await triggerRes.json();
771
695
  if (!triggerData.ok || !triggerData.suiteId) {
772
696
  console.error(`Failed to start tests: ${triggerData.error ?? "Unknown error"}`);
773
- process5.exit(1);
697
+ process4.exit(1);
774
698
  }
775
699
  const { suiteId, jobId, appUrl } = triggerData;
776
700
  if (verbose) {
@@ -789,11 +713,11 @@ async function runRemoteTest(argv) {
789
713
  });
790
714
  } catch (err) {
791
715
  console.error(`Failed to connect to event stream: ${err}`);
792
- process5.exit(1);
716
+ process4.exit(1);
793
717
  }
794
718
  if (!streamRes.ok || !streamRes.body) {
795
719
  console.error(`Failed to connect to event stream: ${streamRes.status}`);
796
- process5.exit(1);
720
+ process4.exit(1);
797
721
  }
798
722
  let exitCode = 0;
799
723
  let hasCompleted = false;
@@ -869,7 +793,7 @@ async function runRemoteTest(argv) {
869
793
  console.log("\u2500".repeat(50));
870
794
  if (totalWorkflows === 0) {
871
795
  console.log("No workflows found matching the filter criteria.");
872
- process5.exit(0);
796
+ process4.exit(0);
873
797
  }
874
798
  const passRate = totalWorkflows > 0 ? Math.round(successfulWorkflows / totalWorkflows * 100) : 0;
875
799
  if (failedWorkflows > 0) {
@@ -886,14 +810,14 @@ async function runRemoteTest(argv) {
886
810
  if (failedSection) {
887
811
  console.log(failedSection);
888
812
  }
889
- process5.exit(exitCode);
813
+ process4.exit(exitCode);
890
814
  }
891
815
 
892
816
  // src/debug-session.ts
893
817
  import fs3 from "fs/promises";
894
818
  import os from "os";
895
819
  import path3 from "path";
896
- import process6 from "process";
820
+ import process5 from "process";
897
821
  async function writeDebugSession(loginUrl, expiresAt, apiUrl) {
898
822
  const dir = path3.join(os.homedir(), ".config", "canary-cli");
899
823
  const filePath = path3.join(dir, "debug-session.json");
@@ -921,17 +845,17 @@ async function runDebugSession(argv) {
921
845
  if (res.status === 401) {
922
846
  console.error("Error: Unauthorized. Your session may have expired.");
923
847
  console.error("Run: canary login");
924
- process6.exit(1);
848
+ process5.exit(1);
925
849
  }
926
850
  if (res.status === 403) {
927
851
  console.error("Error: Forbidden. Debug session creation requires superadmin access.");
928
- process6.exit(1);
852
+ process5.exit(1);
929
853
  }
930
854
  if (res.status === 404) {
931
855
  console.error(
932
856
  "Error: Endpoint not found. The debug-session feature may not be deployed to this environment."
933
857
  );
934
- process6.exit(1);
858
+ process5.exit(1);
935
859
  }
936
860
  try {
937
861
  const errorJson = JSON.parse(text);
@@ -939,12 +863,12 @@ async function runDebugSession(argv) {
939
863
  } catch {
940
864
  console.error(`Error (${res.status}): ${text || res.statusText}`);
941
865
  }
942
- process6.exit(1);
866
+ process5.exit(1);
943
867
  }
944
868
  const json = await res.json();
945
869
  if (!json.ok || !json.loginUrl) {
946
870
  console.error(`Error: ${json.message ?? json.error ?? "Failed to create debug session"}`);
947
- process6.exit(1);
871
+ process5.exit(1);
948
872
  }
949
873
  const filePath = await writeDebugSession(json.loginUrl, json.expiresAt ?? "", apiUrl);
950
874
  if (jsonOutput) {
@@ -971,7 +895,7 @@ async function runDebugSession(argv) {
971
895
  }
972
896
  } catch (err) {
973
897
  console.error(`Failed to create debug session: ${err}`);
974
- process6.exit(1);
898
+ process5.exit(1);
975
899
  }
976
900
  }
977
901
 
@@ -1000,11 +924,12 @@ function isSuperadminToken(token) {
1000
924
  // src/index.ts
1001
925
  var require2 = createRequire2(import.meta.url);
1002
926
  var pkg = require2("../package.json");
1003
- var loadMcp = () => import("./mcp-ZOKM2AUE.js").then((m) => m.runMcp);
1004
- var loadLocalBrowser = () => import("./local-browser-MKTJ36KY.js").then((m) => m.runLocalBrowser);
1005
- var loadDebugWorkflow = () => import("./debug-workflow-I3F36JBL.js").then((m) => m.runDebugWorkflow);
1006
- var loadRecord = () => import("./record-TNDBT3NY.js").then((m) => m.runRecord);
1007
- var loadSession = () => import("./session-RNLKFS2Z.js").then((m) => m.runSession);
927
+ var loadMcp = () => import("./mcp-ZF5G5DCB.js").then((m) => m.runMcp);
928
+ var loadLocalBrowser = () => import("./local-browser-VAZORCO3.js").then((m) => m.runLocalBrowser);
929
+ var loadDebugWorkflow = () => import("./debug-workflow-53ULOFJC.js").then((m) => m.runDebugWorkflow);
930
+ var loadRecord = () => import("./record-V6QKFFH3.js").then((m) => m.runRecord);
931
+ var loadSession = () => import("./session-UGNJXRUW.js").then((m) => m.runSession);
932
+ var loadLocal = () => import("./local-NHXXPHZ3.js").then((m) => m.runLocal);
1008
933
  var canary = { run };
1009
934
  var baseDir = typeof __dirname !== "undefined" ? __dirname : path4.dirname(fileURLToPath2(import.meta.url));
1010
935
  var preloadPath = path4.join(baseDir, "runner", "preload.js");
@@ -1012,23 +937,23 @@ var requireFn = makeRequire();
1012
937
  function runPlaywrightTests(args) {
1013
938
  const playwrightCli = requireFn.resolve("@playwright/test/cli");
1014
939
  const { runnerBin, preloadFlag } = resolveRunner(preloadPath);
1015
- const nodeOptions = process7.env.NODE_OPTIONS && preloadFlag ? `${process7.env.NODE_OPTIONS} ${preloadFlag}` : preloadFlag ?? process7.env.NODE_OPTIONS;
940
+ const nodeOptions = process6.env.NODE_OPTIONS && preloadFlag ? `${process6.env.NODE_OPTIONS} ${preloadFlag}` : preloadFlag ?? process6.env.NODE_OPTIONS;
1016
941
  const env = {
1017
- ...process7.env,
1018
- CANARY_ENABLED: process7.env.CANARY_ENABLED ?? "1",
942
+ ...process6.env,
943
+ CANARY_ENABLED: process6.env.CANARY_ENABLED ?? "1",
1019
944
  CANARY_RUNNER: "canary",
1020
945
  ...nodeOptions ? { NODE_OPTIONS: nodeOptions } : {}
1021
946
  };
1022
947
  const result = spawnSync2(runnerBin, [playwrightCli, "test", ...args], {
1023
948
  env,
1024
949
  stdio: "inherit",
1025
- cwd: process7.cwd()
950
+ cwd: process6.cwd()
1026
951
  });
1027
952
  if (result.error) {
1028
953
  console.error("canary failed to launch Playwright:", result.error);
1029
- process7.exit(1);
954
+ process6.exit(1);
1030
955
  }
1031
- process7.exit(result.status ?? 1);
956
+ process6.exit(result.status ?? 1);
1032
957
  }
1033
958
  function printVersion() {
1034
959
  console.log(`canary v${pkg.version}`);
@@ -1040,18 +965,17 @@ function printHelp({ isSuperadmin }) {
1040
965
  "Usage:",
1041
966
  " canary test [playwright options] Run local Playwright tests",
1042
967
  " canary test --remote [options] Run remote workflow tests",
1043
- " canary local-run --tunnel-url <url> [options]",
1044
- " canary tunnel --port <localPort> [options]",
1045
- " canary run --port <localPort> [options]",
1046
968
  " canary mcp",
1047
969
  " canary browser [--mode playwright|cdp] [--cdp-url <url>] [--no-headless]",
1048
970
  " canary login [--org <name>] [--app-url https://app.trycanary.ai] [--no-open]",
1049
971
  " canary orgs List organizations",
1050
972
  " canary debug <workflowId> [options] Debug workflow in local headed browser",
1051
973
  " canary record [options] Record browser interactions",
974
+ " canary local <sub-command> Set up and manage local testing",
1052
975
  " canary session <sub-command> Manage local browser sessions",
1053
976
  " canary issues <sub-command> Search and view issues",
1054
- " canary skill <name> Output an AI agent skill template"
977
+ " canary workflow <sub-command> Inspect workflow definitions",
978
+ " canary skill <name> Install an AI agent skill template"
1055
979
  ];
1056
980
  lines.push(
1057
981
  " canary release <sub-command> Release QA gate (CI/CD)"
@@ -1204,9 +1128,9 @@ function printTestHelp() {
1204
1128
  ].join("\n")
1205
1129
  );
1206
1130
  }
1207
- var COMMANDS_WITH_HELP = /* @__PURE__ */ new Set(["test"]);
1131
+ var COMMANDS_WITH_HELP = /* @__PURE__ */ new Set(["test", "session", "local", "issues", "workflow", "release", "skill", "skills"]);
1208
1132
  async function resolveIsSuperadmin() {
1209
- const envToken = process7.env.CANARY_API_TOKEN;
1133
+ const envToken = process6.env.CANARY_API_TOKEN;
1210
1134
  if (envToken) return isSuperadminToken(envToken);
1211
1135
  const tokens = await readAllStoredTokens();
1212
1136
  return tokens.some((t) => isSuperadminToken(t));
@@ -1243,23 +1167,11 @@ async function main(argv) {
1243
1167
  runPlaywrightTests(rest);
1244
1168
  return;
1245
1169
  }
1246
- if (command === "local-run") {
1247
- await runLocalTest(rest);
1248
- return;
1249
- }
1250
- if (command === "run") {
1251
- await runLocalSession(rest);
1252
- return;
1253
- }
1254
1170
  if (command === "mcp") {
1255
1171
  const runMcp = await loadMcp();
1256
1172
  await runMcp(rest);
1257
1173
  return;
1258
1174
  }
1259
- if (command === "tunnel") {
1260
- await runTunnel(rest);
1261
- return;
1262
- }
1263
1175
  if (command === "login") {
1264
1176
  await runLogin(rest);
1265
1177
  return;
@@ -1288,6 +1200,11 @@ async function main(argv) {
1288
1200
  await runSession(rest);
1289
1201
  return;
1290
1202
  }
1203
+ if (command === "local") {
1204
+ const runLocal = await loadLocal();
1205
+ await runLocal(rest);
1206
+ return;
1207
+ }
1291
1208
  if (command === "debug-session") {
1292
1209
  await runDebugSession(rest);
1293
1210
  return;
@@ -1303,41 +1220,46 @@ async function main(argv) {
1303
1220
  return;
1304
1221
  }
1305
1222
  if (command === "release") {
1306
- const { runRelease } = await import("./release-L4IXOHDF.js");
1223
+ const { runRelease } = await import("./release-7TI7EIGD.js");
1307
1224
  await runRelease(rest);
1308
1225
  return;
1309
1226
  }
1310
1227
  if (command === "docs") {
1311
- const { runDocs } = await import("./docs-REHST3YB.js");
1228
+ const { runDocs } = await import("./docs-BEE3LOCO.js");
1312
1229
  await runDocs(rest);
1313
1230
  return;
1314
1231
  }
1315
1232
  if (command === "feature-flag") {
1316
- const { runFeatureFlag } = await import("./feature-flag-3HB5NTMY.js");
1233
+ const { runFeatureFlag } = await import("./feature-flag-CYTDV4ZB.js");
1317
1234
  await runFeatureFlag(rest);
1318
1235
  return;
1319
1236
  }
1320
1237
  if (command === "knobs") {
1321
- const { runKnobs } = await import("./knobs-QJ4IBLCT.js");
1238
+ const { runKnobs } = await import("./knobs-O35GAU5M.js");
1322
1239
  await runKnobs(rest);
1323
1240
  return;
1324
1241
  }
1325
1242
  if (command === "issues") {
1326
- const { runIssues } = await import("./issues-YU57CHXS.js");
1243
+ const { runIssues } = await import("./issues-NLM72HLU.js");
1327
1244
  await runIssues(rest);
1328
1245
  return;
1329
1246
  }
1247
+ if (command === "workflow") {
1248
+ const { runWorkflow } = await import("./workflow-HXIUXRFI.js");
1249
+ await runWorkflow(rest);
1250
+ return;
1251
+ }
1330
1252
  if (command === "skill" || command === "skills") {
1331
- const { runSkill } = await import("./skill-CZ7SHI3P.js");
1253
+ const { runSkill } = await import("./skill-ORWAPBDW.js");
1332
1254
  await runSkill(rest);
1333
1255
  return;
1334
1256
  }
1335
1257
  console.log(`Unknown command "${command}".`);
1336
1258
  printHelp({ isSuperadmin: await resolveIsSuperadmin() });
1337
- process7.exit(1);
1259
+ process6.exit(1);
1338
1260
  }
1339
- if (import.meta.url === pathToFileURL2(process7.argv[1]).href) {
1340
- void main(process7.argv.slice(2));
1261
+ if (import.meta.url === pathToFileURL2(process6.argv[1]).href) {
1262
+ void main(process6.argv.slice(2));
1341
1263
  }
1342
1264
  export {
1343
1265
  canary,