checkly 8.7.0-prerelease-633a7ed → 8.8.0-prerelease-e12e48f

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 (47) hide show
  1. package/dist/ai-context/context.d.ts +5 -5
  2. package/dist/ai-context/context.js +3 -3
  3. package/dist/ai-context/context.js.map +1 -1
  4. package/dist/ai-context/public-skills/checkly/SKILL.md +1 -1
  5. package/dist/ai-context/skills-command/references/investigate-checks.md +69 -0
  6. package/dist/ai-context/skills-command/references/investigate-test-sessions.md +42 -5
  7. package/dist/ai-context/skills-command/references/investigate.md +2 -2
  8. package/dist/commands/assets/download.d.ts +19 -0
  9. package/dist/commands/assets/download.js +170 -0
  10. package/dist/commands/assets/download.js.map +1 -0
  11. package/dist/commands/assets/list.d.ts +17 -0
  12. package/dist/commands/assets/list.js +107 -0
  13. package/dist/commands/assets/list.js.map +1 -0
  14. package/dist/commands/checks/delete.d.ts +15 -0
  15. package/dist/commands/checks/delete.js +65 -0
  16. package/dist/commands/checks/delete.js.map +1 -0
  17. package/dist/commands/checks/get.d.ts +6 -0
  18. package/dist/commands/checks/get.js +118 -8
  19. package/dist/commands/checks/get.js.map +1 -1
  20. package/dist/formatters/assets.d.ts +22 -0
  21. package/dist/formatters/assets.js +280 -0
  22. package/dist/formatters/assets.js.map +1 -0
  23. package/dist/formatters/check-result-detail.d.ts +8 -1
  24. package/dist/formatters/check-result-detail.js +103 -8
  25. package/dist/formatters/check-result-detail.js.map +1 -1
  26. package/dist/formatters/render.d.ts +1 -0
  27. package/dist/formatters/render.js +6 -0
  28. package/dist/formatters/render.js.map +1 -1
  29. package/dist/helpers/command-style.d.ts +1 -0
  30. package/dist/helpers/command-style.js +5 -0
  31. package/dist/helpers/command-style.js.map +1 -1
  32. package/dist/helpers/result-assets.d.ts +54 -0
  33. package/dist/helpers/result-assets.js +305 -0
  34. package/dist/helpers/result-assets.js.map +1 -0
  35. package/dist/rest/api.d.ts +2 -0
  36. package/dist/rest/api.js +2 -0
  37. package/dist/rest/api.js.map +1 -1
  38. package/dist/rest/asset-manifests.d.ts +30 -0
  39. package/dist/rest/asset-manifests.js +29 -0
  40. package/dist/rest/asset-manifests.js.map +1 -0
  41. package/dist/rest/check-results.d.ts +2 -1
  42. package/dist/rest/check-results.js.map +1 -1
  43. package/dist/rest/checks.d.ts +1 -0
  44. package/dist/rest/checks.js +3 -0
  45. package/dist/rest/checks.js.map +1 -1
  46. package/oclif.manifest.json +582 -320
  47. package/package.json +13 -10
@@ -43,10 +43,10 @@ export declare const REFERENCES: readonly [{
43
43
  }];
44
44
  export declare const INVESTIGATE_REFERENCES: readonly [{
45
45
  readonly id: "investigate-checks";
46
- readonly description: "Inspecting checks (`checks list`, `checks get`) and triggering on-demand runs";
46
+ readonly description: "Inspect checks (`checks list`, `checks get`), retry attempts, result assets, and trigger on-demand runs";
47
47
  }, {
48
48
  readonly id: "investigate-test-sessions";
49
- readonly description: "Run and inspect recorded test sessions, drill into test-session error groups, run RCA, and retrieve result assets";
49
+ readonly description: "Run and inspect recorded test sessions, drill into test-session error groups, run RCA, and list/download result assets";
50
50
  }];
51
51
  export declare const COMMUNICATE_REFERENCES: readonly [{
52
52
  readonly id: "communicate-incidents";
@@ -114,13 +114,13 @@ export declare const ACTIONS: readonly [{
114
114
  }];
115
115
  }, {
116
116
  readonly id: "investigate";
117
- readonly description: "Access check and test-session status, analyze failures, and investigate errors.";
117
+ readonly description: "Access check and test-session status, analyze failures, inspect attempts/assets, and investigate errors.";
118
118
  readonly references: readonly [{
119
119
  readonly id: "investigate-checks";
120
- readonly description: "Inspecting checks (`checks list`, `checks get`) and triggering on-demand runs";
120
+ readonly description: "Inspect checks (`checks list`, `checks get`), retry attempts, result assets, and trigger on-demand runs";
121
121
  }, {
122
122
  readonly id: "investigate-test-sessions";
123
- readonly description: "Run and inspect recorded test sessions, drill into test-session error groups, run RCA, and retrieve result assets";
123
+ readonly description: "Run and inspect recorded test sessions, drill into test-session error groups, run RCA, and list/download result assets";
124
124
  }];
125
125
  }, {
126
126
  readonly id: "communicate";
@@ -59,11 +59,11 @@ export const REFERENCES = [
59
59
  export const INVESTIGATE_REFERENCES = [
60
60
  {
61
61
  id: 'investigate-checks',
62
- description: 'Inspecting checks (`checks list`, `checks get`) and triggering on-demand runs',
62
+ description: 'Inspect checks (`checks list`, `checks get`), retry attempts, result assets, and trigger on-demand runs',
63
63
  },
64
64
  {
65
65
  id: 'investigate-test-sessions',
66
- description: 'Run and inspect recorded test sessions, drill into test-session error groups, run RCA, and retrieve result assets',
66
+ description: 'Run and inspect recorded test sessions, drill into test-session error groups, run RCA, and list/download result assets',
67
67
  },
68
68
  ];
69
69
  export const COMMUNICATE_REFERENCES = [
@@ -98,7 +98,7 @@ export const ACTIONS = [
98
98
  },
99
99
  {
100
100
  id: 'investigate',
101
- description: 'Access check and test-session status, analyze failures, and investigate errors.',
101
+ description: 'Access check and test-session status, analyze failures, inspect attempts/assets, and investigate errors.',
102
102
  references: INVESTIGATE_REFERENCES,
103
103
  },
104
104
  {
@@ -1 +1 @@
1
- {"version":3,"file":"context.js","sourceRoot":"","sources":["../../src/ai-context/context.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB;QACE,EAAE,EAAE,0BAA0B;QAC9B,WAAW,EAAE,oHAAoH;KAClI;IACD;QACE,EAAE,EAAE,sBAAsB;QAC1B,WAAW,EAAE,gFAAgF;KAC9F;IACD;QACE,EAAE,EAAE,0BAA0B;QAC9B,WAAW,EAAE,qEAAqE;KACnF;IACD;QACE,EAAE,EAAE,6BAA6B;QACjC,WAAW,EAAE,oFAAoF;KAClG;IACD;QACE,EAAE,EAAE,4BAA4B;QAChC,WAAW,EAAE,qEAAqE;KACnF;IACD;QACE,EAAE,EAAE,wBAAwB;QAC5B,WAAW,EAAE,sDAAsD;KACpE;IACD;QACE,EAAE,EAAE,wBAAwB;QAC5B,WAAW,EAAE,sDAAsD;KACpE;IACD;QACE,EAAE,E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E,2CAA2C;QAC3D,iBAAiB,EAAE,8DAA8D;QACjF,SAAS,EAAE,oEAAoE;KAChF;CACF,CAAA"}
1
+ {"version":3,"file":"context.js","sourceRoot":"","sources":["../../src/ai-context/context.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB;QACE,EAAE,EAAE,0BAA0B;QAC9B,WAAW,EAAE,oHAAoH;KAClI;IACD;QACE,EAAE,EAAE,sBAAsB;QAC1B,WAAW,EAAE,gFAAgF;KAC9F;IACD;QACE,EAAE,EAAE,0BAA0B;QAC9B,WAAW,EAAE,qEAAqE;KACnF;IACD;QACE,EAAE,EAAE,6BAA6B;QACjC,WAAW,EAAE,oFAAoF;KAClG;IACD;QACE,EAAE,EAAE,4BAA4B;QAChC,WAAW,EAAE,qEAAqE;KACnF;IACD;QACE,EAAE,EAAE,wBAAwB;QAC5B,WAAW,EAAE,sDAAsD;KACpE;IACD;QACE,EAAE,EAAE,wBAAwB;QAC5B,WAAW,EAAE,sDAAsD;KACpE;IACD;QACE,EAAE,EAAE,wBAAwB;QAC5B,WAAW,EAAE,sDAAsD;KACpE;IACD;QACE,EAAE,EAAE,yBAAyB;QAC7B,WAAW,EAAE,gFAAgF;KAC9F;IACD;QACE,EAAE,EAAE,8BAA8B;QAClC,WAAW,EAAE,kDAAkD;KAChE;IACD;QACE,EAAE,EAAE,wBAAwB;QAC5B,WAAW,EAAE,+DAA+D;KAC7E;IACD;QACE,EAAE,EAAE,0BAA0B;QAC9B,WAAW,EAAE,kJAAkJ;KAChK;IACD;QACE,EAAE,EAAE,iCAAiC;QACrC,WAAW,EAAE,6IAA6I;KAC3J;IACD;QACE,EAAE,EAAE,uBAAuB;QAC3B,WAAW,EAAE,8RAA8R;KAC5S;CACO,CAAA;AAEV,MAAM,CAAC,MAAM,sBAAsB,GAAG;IACpC;QACE,EAAE,EAAE,oBAAoB;QACxB,WAAW,EAAE,yGAAyG;KACvH;IACD;QACE,EAAE,EAAE,2BAA2B;Q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c,EAAE,6BAA6B;QAC7C,iBAAiB,EACf,mEAAmE;QACrE,SAAS,EAAE,sDAAsD;KAClE;IACD,kBAAkB,EAAE;QAClB,cAAc,EAAE,sCAAsC;QACtD,iBAAiB,EACf,mEAAmE;QACrE,SAAS,EAAE,+DAA+D;KAC3E;IACD,gBAAgB,EAAE;QAChB,cAAc,EAAE,oCAAoC;QACpD,iBAAiB,EACf,+DAA+D;QACjE,SAAS,EAAE,6DAA6D;KACzE;IACD,mBAAmB,EAAE;QACnB,cAAc,EAAE,uCAAuC;QACvD,iBAAiB,EAAE,8CAA8C;QACjE,SAAS,EAAE,gEAAgE;KAC5E;IACD,wBAAwB,EAAE;QACxB,cAAc,EAAE,4CAA4C;QAC5D,iBAAiB,EAAE,wDAAwD;QAC3E,SAAS,EAAE,qEAAqE;KACjF;IACD,mBAAmB,EAAE;QACnB,cAAc,EAAE,uCAAuC;QACvD,iBAAiB,EAAE,iDAAiD;QACpE,SAAS,EAAE,gEAAgE;KAC5E;IACD,uBAAuB,EAAE;QACvB,cAAc,EAAE,2CAA2C;QAC3D,iBAAiB,EAAE,8DAA8D;QACjF,SAAS,EAAE,oEAAoE;KAChF;CACF,CAAA"}
@@ -103,7 +103,7 @@ Learn how to initialize and set up a new Checkly CLI project from scratch.
103
103
  Learn how to create and manage monitoring checks using Checkly constructs and the CLI.
104
104
 
105
105
  ### `npx checkly skills investigate`
106
- Access check and test-session status, analyze failures, and investigate errors.
106
+ Access check and test-session status, analyze failures, inspect attempts/assets, and investigate errors.
107
107
 
108
108
  ### `npx checkly skills communicate`
109
109
  Open incidents and lead customer communications via status pages.
@@ -32,6 +32,7 @@ Shows check configuration, recent results, error groups, and analytics stats.
32
32
 
33
33
  Flags:
34
34
  - `-r, --result <result-id>` — drill into a specific result (see below)
35
+ - `--include-attempts` — with `--result`, also list the individual retry attempts for that result (see below)
35
36
  - `-e, --error-group <error-group-id>` — show full details for a specific error group
36
37
  - `--results-limit <n>` — number of recent results to show (default 10)
37
38
  - `--results-cursor <cursor>` — paginate results using the cursor from previous output
@@ -47,8 +48,76 @@ Flags:
47
48
 
48
49
  ```bash
49
50
  npx checkly checks get <check-id> --result <result-id>
51
+ npx checkly checks get <check-id> --result <result-id> --output json
50
52
  ```
51
53
 
54
+ ### View retry attempts for a result
55
+
56
+ When a check has retries enabled, a single run produces one `FINAL` result plus
57
+ one `ATTEMPT` result for each earlier failed try (all sharing a `sequenceId`).
58
+ By default only the `FINAL` result is shown. Add `--include-attempts` to list the
59
+ full retry sequence — attempt number, status, location, duration, and a short
60
+ error summary:
61
+
62
+ ```bash
63
+ npx checkly checks get <check-id> --result <result-id> --include-attempts
64
+ npx checkly checks get <check-id> --result <result-id> --include-attempts --output json
65
+ ```
66
+
67
+ With `--include-attempts --output json`, the command returns a stable envelope:
68
+
69
+ ```json
70
+ {
71
+ "result": {},
72
+ "attempts": []
73
+ }
74
+ ```
75
+
76
+ Use the `attempts` array to inspect intermediate retry failures. Use the `result`
77
+ object for the requested result row.
78
+
79
+ ### List or download result assets
80
+
81
+ Result detail output summarizes available screenshots, traces, and videos when
82
+ present. Use the dedicated asset manifest commands to inspect exact asset names
83
+ and download files:
84
+
85
+ ```bash
86
+ npx checkly assets list --check-id <check-id> --result-id <result-id>
87
+ npx checkly assets list --check-id <check-id> --result-id <result-id> --type trace --view tree
88
+ npx checkly assets list --check-id <check-id> --result-id <result-id> --output json
89
+ npx checkly assets download --check-id <check-id> --result-id <result-id> --asset "<Asset>"
90
+ npx checkly assets download --check-id <check-id> --result-id <result-id> --type all --dir ./checkly-assets
91
+ ```
92
+
93
+ Run `assets list` first to discover available files. The default table output
94
+ has an `Asset` column; copy that value into `--asset` for single-file downloads.
95
+
96
+ Flags:
97
+ - `--type <type>` - filter/select by `log`, `trace`, `video`, `screenshot`, `pcap`, `report`, `file`, or `all`.
98
+ - `--asset <value>` - exact Asset/Name value or glob. Prefer copying the `Asset` value from the default table output before downloading a single file.
99
+ - `--dir <path>` - destination directory for downloads; defaults under `./checkly-assets/`.
100
+ - `--force` / `--skip-existing` - overwrite or preserve existing files.
101
+
102
+ `assets list --output json` uses a stable list envelope:
103
+
104
+ ```json
105
+ {
106
+ "data": [],
107
+ "pagination": {
108
+ "length": 0
109
+ }
110
+ }
111
+ ```
112
+
113
+ `assets download` requires `--type` or `--asset` unless the manifest is a single
114
+ archive bundle. Archive entries download as their containing archive; filters
115
+ narrow the manifest list, not the archive bytes.
116
+
117
+ Do not invent asset names or assume every result has the same artifact set. Some
118
+ results have screenshots only, some have traces or videos, and some have no
119
+ downloadable assets.
120
+
52
121
  ### View an error group
53
122
 
54
123
  ```bash
@@ -78,7 +78,7 @@ Flags:
78
78
 
79
79
  The detail view shows the session status, metadata, result rows, test-session result IDs, check IDs when available, and test-session error group IDs. Prefer `--watch` before investigating failures so you do not act on partial results.
80
80
 
81
- Use `--output json` when you need exact fields, result links, or asset URLs. For Playwright Check Suite results, inspect result payload fields such as Playwright result details, traces, videos, screenshots, reports, and links when present.
81
+ Use `--output json` when you need exact fields, result links, check IDs, or test-session result IDs. For downloadable logs, traces, videos, screenshots, reports, and files, use `checkly assets list` and `checkly assets download` with the test session ID and result ID.
82
82
 
83
83
  ## Inspect a test-session error group
84
84
 
@@ -116,13 +116,50 @@ If RCA is unavailable because of plan or entitlement limits, run `npx checkly ac
116
116
 
117
117
  ## Retrieve result assets
118
118
 
119
- There is no dedicated `test-sessions download` command. Use the JSON outputs and links exposed by the session or result payload.
119
+ Use the asset manifest commands for recorded test-session result files. Start
120
+ from `test-sessions get` to identify the `testSessionResultId` (and `checkId`
121
+ when available) for the row you want to inspect.
120
122
 
121
123
  ```bash
122
124
  npx checkly test-sessions get <test-session-id> --output json
123
- npx checkly checks get <check-id> --result <test-session-result-id> --output json
125
+ npx checkly assets list --test-session-id <test-session-id> --result-id <test-session-result-id>
126
+ npx checkly assets list --test-session-id <test-session-id> --result-id <test-session-result-id> --type trace --view tree
127
+ npx checkly assets list --test-session-id <test-session-id> --result-id <test-session-result-id> --output json
128
+ npx checkly assets download --test-session-id <test-session-id> --result-id <test-session-result-id> --asset "<Asset>"
129
+ npx checkly assets download --test-session-id <test-session-id> --result-id <test-session-result-id> --type all --dir ./checkly-assets
124
130
  ```
125
131
 
126
- Use `test-sessions get --output json` first. If a result includes public URLs or asset fields, download those URLs directly. If a result only gives `checkId` plus `testSessionResultId`, use `checks get <check-id> --result <test-session-result-id> --output json` to fetch detailed result data; terminal output summarizes available screenshots, traces, and videos, while JSON output exposes the underlying URLs/fields.
132
+ Run `assets list` first to discover available files. The default table output
133
+ has an `Asset` column; copy that value into `--asset` for single-file downloads.
127
134
 
128
- Do not invent asset names or assume every result has the same artifact set. Some results have screenshots only, some have traces or videos, and some have no downloadable assets.
135
+ Flags:
136
+ - `--type <type>` - filter/select by `log`, `trace`, `video`, `screenshot`, `pcap`, `report`, `file`, or `all`.
137
+ - `--asset <value>` - exact Asset/Name value or glob. Prefer copying the `Asset` value from `assets list --view table` for single-file downloads.
138
+ - `--dir <path>` - destination directory for downloads; defaults under `./checkly-assets/`.
139
+ - `--force` / `--skip-existing` - overwrite or preserve existing files.
140
+
141
+ `assets list --output json` uses a stable list envelope:
142
+
143
+ ```json
144
+ {
145
+ "data": [],
146
+ "pagination": {
147
+ "length": 0
148
+ }
149
+ }
150
+ ```
151
+
152
+ `assets download` requires `--type` or `--asset` unless the manifest is a single
153
+ archive bundle. Archive entries download as their containing archive; filters
154
+ narrow the manifest list, not the archive bytes.
155
+
156
+ If you also need the scheduled check result view for the same row, and the row
157
+ has a `checkId`, use:
158
+
159
+ ```bash
160
+ npx checkly checks get <check-id> --result <test-session-result-id>
161
+ ```
162
+
163
+ Do not invent asset names or assume every result has the same artifact set. Some
164
+ results have screenshots only, some have traces or videos, and some have no
165
+ downloadable assets.
@@ -9,7 +9,7 @@ Read-only commands execute immediately without confirmation.
9
9
  Parse and read further reference documentation when tasked with investigating any of the following:
10
10
 
11
11
  ### `npx checkly skills investigate checks`
12
- Inspecting checks (`checks list`, `checks get`) and triggering on-demand runs
12
+ Inspect checks (`checks list`, `checks get`), retry attempts, result assets, and trigger on-demand runs
13
13
 
14
14
  ### `npx checkly skills investigate test-sessions`
15
- Run and inspect recorded test sessions, drill into test-session error groups, run RCA, and retrieve result assets
15
+ Run and inspect recorded test sessions, drill into test-session error groups, run RCA, and list/download result assets
@@ -0,0 +1,19 @@
1
+ import { AuthCommand } from '../authCommand.js';
2
+ export default class AssetsDownload extends AuthCommand {
3
+ static hidden: boolean;
4
+ static readOnly: boolean;
5
+ static idempotent: boolean;
6
+ static description: string;
7
+ static flags: {
8
+ 'check-id': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
9
+ 'test-session-id': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
10
+ 'result-id': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
11
+ type: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
12
+ asset: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
13
+ dir: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
14
+ force: import("@oclif/core/interfaces").BooleanFlag<boolean>;
15
+ 'skip-existing': import("@oclif/core/interfaces").BooleanFlag<boolean>;
16
+ output: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
17
+ };
18
+ run(): Promise<void>;
19
+ }
@@ -0,0 +1,170 @@
1
+ import { Flags } from '@oclif/core';
2
+ import path from 'node:path';
3
+ import { AuthCommand } from '../authCommand.js';
4
+ import { outputFlag } from '../../helpers/flags.js';
5
+ import { assetSelectorValue, formatDownloadedAssets } from '../../formatters/assets.js';
6
+ import { assertManifestSupportsDownload, archiveBundleAssets, assetManifestFiltersFromSelection, assetTypeSelectionFromFlag, assetTypes, defaultDownloadDirectory, destinationPathForAsset, downloadAssetToFile, fetchAssetManifest, hasArchiveEntries, isSingleArchiveBundle, resolveAssetSource, selectAssets, } from '../../helpers/result-assets.js';
7
+ export default class AssetsDownload extends AuthCommand {
8
+ static hidden = false;
9
+ static readOnly = true;
10
+ static idempotent = true;
11
+ static description = 'Download result assets.';
12
+ static flags = {
13
+ 'check-id': Flags.string({
14
+ description: 'Check ID for a scheduled check result.',
15
+ }),
16
+ 'test-session-id': Flags.string({
17
+ description: 'Test session ID for a test-session result.',
18
+ }),
19
+ 'result-id': Flags.string({
20
+ description: 'Check result ID or test-session result ID.',
21
+ required: true,
22
+ }),
23
+ 'type': Flags.string({
24
+ description: 'Select assets by type.',
25
+ options: assetTypes,
26
+ }),
27
+ 'asset': Flags.string({
28
+ description: 'Select an asset by exact Asset/Name value or glob.',
29
+ }),
30
+ 'dir': Flags.string({
31
+ description: 'Directory to write assets into.',
32
+ }),
33
+ 'force': Flags.boolean({
34
+ description: 'Overwrite existing files.',
35
+ default: false,
36
+ }),
37
+ 'skip-existing': Flags.boolean({
38
+ description: 'Skip files that already exist.',
39
+ default: false,
40
+ }),
41
+ 'output': outputFlag({ default: 'table', options: ['table', 'json'] }),
42
+ };
43
+ async run() {
44
+ const { flags } = await this.parse(AssetsDownload);
45
+ this.style.outputFormat = flags.output;
46
+ const source = resolveAssetSource(flags);
47
+ const type = assetTypeSelectionFromFlag(flags.type);
48
+ const showProgress = flags.output !== 'json' && this.fancy && process.stdout.isTTY;
49
+ let progressStarted = false;
50
+ const startProgress = (message) => {
51
+ if (!showProgress)
52
+ return;
53
+ this.style.actionStart(message);
54
+ progressStarted = true;
55
+ };
56
+ const setProgress = (message) => {
57
+ if (!showProgress || !progressStarted)
58
+ return;
59
+ this.style.actionStatus(message);
60
+ };
61
+ const stopProgress = (success) => {
62
+ if (!showProgress || !progressStarted)
63
+ return;
64
+ if (success) {
65
+ this.style.actionSuccess();
66
+ }
67
+ else {
68
+ this.style.actionFailure();
69
+ }
70
+ progressStarted = false;
71
+ };
72
+ if (flags.force && flags['skip-existing']) {
73
+ throw new Error('--force and --skip-existing are mutually exclusive.');
74
+ }
75
+ try {
76
+ startProgress('Fetching asset manifest');
77
+ const filters = assetManifestFiltersFromSelection({
78
+ type,
79
+ asset: flags.asset,
80
+ });
81
+ const manifest = await fetchAssetManifest(source, filters);
82
+ assertManifestSupportsDownload(manifest, filters);
83
+ const assets = selectAssets(manifest.assets, {
84
+ type,
85
+ asset: flags.asset,
86
+ });
87
+ const hasSelector = Boolean(flags.type || flags.asset);
88
+ if (!hasSelector && !isSingleArchiveBundle(assets)) {
89
+ throw new Error('Pass --type or --asset to select assets. Use --type all to download all assets.');
90
+ }
91
+ if (assets.length === 0) {
92
+ stopProgress(true);
93
+ if (flags.output === 'json') {
94
+ this.log(JSON.stringify({ source, directory: null, files: [], warnings: [] }, null, 2));
95
+ return;
96
+ }
97
+ this.log('No matching assets found.');
98
+ return;
99
+ }
100
+ const directory = path.resolve(flags.dir ?? defaultDownloadDirectory(source));
101
+ const rows = [];
102
+ const directAssets = assets.filter(asset => !asset.archive);
103
+ const archiveAssets = archiveBundleAssets(assets);
104
+ const downloadTargets = [
105
+ ...directAssets.map(asset => ({ asset, displayType: undefined })),
106
+ ...archiveAssets.map(asset => ({ asset, displayType: 'archive' })),
107
+ ];
108
+ const warnings = [];
109
+ if (hasArchiveEntries(assets)) {
110
+ warnings.push('Selected assets include archive entries. Downloading the containing archive file; filters narrow the manifest list, not the archive bytes.');
111
+ }
112
+ for (const [index, target] of downloadTargets.entries()) {
113
+ const { asset, displayType } = target;
114
+ const filePath = destinationPathForAsset(directory, asset);
115
+ const label = `${index + 1}/${downloadTargets.length} ${displayType ?? asset.type} ${assetSelectorValue(asset)}`;
116
+ let lastProgressUpdate = 0;
117
+ setProgress(`Downloading ${label}`);
118
+ const status = await downloadAssetToFile(asset, filePath, {
119
+ force: flags.force,
120
+ skipExisting: flags['skip-existing'],
121
+ onProgress: showProgress
122
+ ? ({ downloadedBytes, totalBytes }) => {
123
+ const now = Date.now();
124
+ if (now - lastProgressUpdate < 250)
125
+ return;
126
+ lastProgressUpdate = now;
127
+ setProgress(`Downloading ${label} ${formatDownloadBytes(downloadedBytes, totalBytes)}`);
128
+ }
129
+ : undefined,
130
+ });
131
+ setProgress(status === 'skipped' ? `Skipped ${label}` : `Downloaded ${label}`);
132
+ rows.push({ status, path: filePath, asset, displayType });
133
+ }
134
+ stopProgress(true);
135
+ if (flags.output === 'json') {
136
+ this.log(JSON.stringify({ source, directory, files: rows, warnings }, null, 2));
137
+ return;
138
+ }
139
+ const output = [
140
+ ...warnings.map(warning => `Warning: ${warning}`),
141
+ formatDownloadedAssets(rows),
142
+ ].filter(Boolean);
143
+ this.log(output.join('\n\n'));
144
+ }
145
+ catch (err) {
146
+ stopProgress(false);
147
+ this.style.longError('Failed to download assets.', err);
148
+ process.exitCode = 1;
149
+ }
150
+ }
151
+ }
152
+ function formatDownloadBytes(downloadedBytes, totalBytes) {
153
+ if (totalBytes === undefined)
154
+ return formatBytes(downloadedBytes);
155
+ return `${formatBytes(downloadedBytes)} / ${formatBytes(totalBytes)}`;
156
+ }
157
+ function formatBytes(bytes) {
158
+ if (bytes < 1024)
159
+ return `${bytes} B`;
160
+ const units = ['KB', 'MB', 'GB', 'TB'];
161
+ let value = bytes / 1024;
162
+ let unitIndex = 0;
163
+ while (value >= 1024 && unitIndex < units.length - 1) {
164
+ value /= 1024;
165
+ unitIndex += 1;
166
+ }
167
+ const rounded = value >= 10 ? value.toFixed(1) : value.toFixed(2);
168
+ return `${rounded} ${units[unitIndex]}`;
169
+ }
170
+ //# sourceMappingURL=download.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"download.js","sourceRoot":"","sources":["../../../src/commands/assets/download.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAA;AACnC,OAAO,IAAI,MAAM,WAAW,CAAA;AAC5B,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EA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,OAAO,IAAI,KAAK,CAAC,SAAS,CAAC,EAAE,CAAA;AACzC,CAAC"}
@@ -0,0 +1,17 @@
1
+ import { AuthCommand } from '../authCommand.js';
2
+ export default class AssetsList extends AuthCommand {
3
+ static hidden: boolean;
4
+ static readOnly: boolean;
5
+ static idempotent: boolean;
6
+ static description: string;
7
+ static flags: {
8
+ 'check-id': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
9
+ 'test-session-id': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
10
+ 'result-id': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
11
+ type: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
12
+ asset: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
13
+ view: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
14
+ output: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
15
+ };
16
+ run(): Promise<void>;
17
+ }
@@ -0,0 +1,107 @@
1
+ import { Flags } from '@oclif/core';
2
+ import chalk from 'chalk';
3
+ import { AuthCommand } from '../authCommand.js';
4
+ import { outputFlag } from '../../helpers/flags.js';
5
+ import { formatAssetListHeader, formatAssetListNextSteps, formatAssetManifestEntries, formatAssetManifestTree, } from '../../formatters/assets.js';
6
+ import { assetManifestFiltersFromSelection, assetTypeSelectionFromFlag, assetTypes, fetchAssetManifest, filterAssetsBySelector, filterAssetsByType, resolveAssetSource, } from '../../helpers/result-assets.js';
7
+ export default class AssetsList extends AuthCommand {
8
+ static hidden = false;
9
+ static readOnly = true;
10
+ static idempotent = true;
11
+ static description = 'List result assets.';
12
+ static flags = {
13
+ 'check-id': Flags.string({
14
+ description: 'Check ID for a scheduled check result.',
15
+ }),
16
+ 'test-session-id': Flags.string({
17
+ description: 'Test session ID for a test-session result.',
18
+ }),
19
+ 'result-id': Flags.string({
20
+ description: 'Check result ID or test-session result ID.',
21
+ required: true,
22
+ }),
23
+ 'type': Flags.string({
24
+ description: 'Filter assets by type.',
25
+ options: assetTypes,
26
+ default: 'all',
27
+ }),
28
+ 'asset': Flags.string({
29
+ description: 'Filter assets by exact Asset/Name value or glob.',
30
+ }),
31
+ 'view': Flags.string({
32
+ description: 'Human output view. Ignored with --output json.',
33
+ options: ['table', 'tree'],
34
+ default: 'table',
35
+ }),
36
+ 'output': outputFlag({ default: 'table' }),
37
+ };
38
+ async run() {
39
+ const { flags } = await this.parse(AssetsList);
40
+ this.style.outputFormat = flags.output;
41
+ const source = resolveAssetSource(flags);
42
+ const type = assetTypeSelectionFromFlag(flags.type);
43
+ try {
44
+ const filters = assetManifestFiltersFromSelection({
45
+ type,
46
+ asset: flags.asset,
47
+ });
48
+ const manifest = await fetchAssetManifest(source, filters);
49
+ const assets = filterAssetsBySelector(filterAssetsByType(manifest.assets, type), flags.asset);
50
+ if (flags.output === 'json') {
51
+ this.log(JSON.stringify({
52
+ data: assets,
53
+ pagination: {
54
+ length: assets.length,
55
+ },
56
+ }, null, 2));
57
+ return;
58
+ }
59
+ const fmt = flags.output === 'md' ? 'md' : 'terminal';
60
+ const output = [];
61
+ output.push(formatAssetListHeader({
62
+ sourceType: source.kind,
63
+ checkId: source.kind === 'check-result' ? source.checkId : undefined,
64
+ testSessionId: source.kind === 'test-session-result' ? source.testSessionId : undefined,
65
+ resultId: source.resultId,
66
+ type,
67
+ asset: flags.asset,
68
+ }, assets, fmt));
69
+ output.push('');
70
+ if (assets.length === 0) {
71
+ output.push('No assets found.');
72
+ }
73
+ else if (flags.view === 'tree') {
74
+ output.push(formatAssetManifestTree(assets, fmt));
75
+ output.push('');
76
+ output.push(chalk.dim('Tip: use --view table to copy exact Asset values for download.'));
77
+ }
78
+ else {
79
+ output.push(formatAssetManifestEntries(assets, fmt));
80
+ }
81
+ const nextSteps = formatAssetListNextSteps({
82
+ sourceType: source.kind,
83
+ checkId: source.kind === 'check-result' ? source.checkId : undefined,
84
+ testSessionId: source.kind === 'test-session-result' ? source.testSessionId : undefined,
85
+ resultId: source.resultId,
86
+ type,
87
+ asset: flags.asset,
88
+ }, assets, fmt);
89
+ if (nextSteps) {
90
+ output.push('');
91
+ output.push(nextSteps);
92
+ }
93
+ if (manifest.truncated) {
94
+ const returned = manifest.entriesReturned ?? manifest.assets.length;
95
+ const total = manifest.entriesTotal == null ? 'unknown' : String(manifest.entriesTotal);
96
+ output.push('');
97
+ output.push(chalk.yellow(`Warning: asset manifest is truncated (${returned} of ${total} entries returned).`));
98
+ }
99
+ this.log(output.join('\n'));
100
+ }
101
+ catch (err) {
102
+ this.style.longError('Failed to list assets.', err);
103
+ process.exitCode = 1;
104
+ }
105
+ }
106
+ }
107
+ //# sourceMappingURL=list.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"list.js","sourceRoot":"","sources":["../../../src/commands/assets/list.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAA;AACnC,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAA;AAEnD,OAAO,EACL,qBAAqB,EACrB,wBAAwB,EACxB,0BAA0B,EAC1B,uBAAuB,GACxB,MAAM,4BAA4B,CAAA;AACnC,OAAO,EACL,iCAAiC,EACjC,0BAA0B,EAC1B,UAAU,EACV,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,kBAAkB,GACnB,MAAM,gCAAgC,CAAA;AAEvC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,WAAW;IACjD,MAAM,CAAC,MAAM,GAAG,KAAK,CAAA;IACrB,MAAM,CAAC,QAAQ,GAAG,IAAI,CAAA;IACtB,MAAM,CAAC,UAAU,GAAG,IAAI,CAAA;IACxB,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A;gBACf,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,yCAAyC,QAAQ,OAAO,KAAK,qBAAqB,CAAC,CAAC,CAAA;YAC/G,CAAC;YAED,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAA;QAC7B,CAAC;QAAC,OAAO,GAAQ,EAAE,CAAC;YAClB,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,wBAAwB,EAAE,GAAG,CAAC,CAAA;YACnD,OAAO,CAAC,QAAQ,GAAG,CAAC,CAAA;QACtB,CAAC;IACH,CAAC"}
@@ -0,0 +1,15 @@
1
+ import { AuthCommand } from '../authCommand.js';
2
+ export default class ChecksDelete extends AuthCommand {
3
+ static hidden: boolean;
4
+ static destructive: boolean;
5
+ static idempotent: boolean;
6
+ static description: string;
7
+ static args: {
8
+ id: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
9
+ };
10
+ static flags: {
11
+ force: import("@oclif/core/interfaces").BooleanFlag<boolean>;
12
+ 'dry-run': import("@oclif/core/interfaces").BooleanFlag<boolean>;
13
+ };
14
+ run(): Promise<void>;
15
+ }