@onkernel/sdk 0.147.0 → 0.149.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 (124) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/client.d.mts +18 -0
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +18 -0
  5. package/client.d.ts.map +1 -1
  6. package/client.js +18 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +18 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/browsers/browsers.d.mts +4 -0
  12. package/resources/browsers/browsers.d.mts.map +1 -1
  13. package/resources/browsers/browsers.d.ts +4 -0
  14. package/resources/browsers/browsers.d.ts.map +1 -1
  15. package/resources/browsers/browsers.js +4 -0
  16. package/resources/browsers/browsers.js.map +1 -1
  17. package/resources/browsers/browsers.mjs +4 -0
  18. package/resources/browsers/browsers.mjs.map +1 -1
  19. package/resources/browsers/index.d.mts +1 -0
  20. package/resources/browsers/index.d.mts.map +1 -1
  21. package/resources/browsers/index.d.ts +1 -0
  22. package/resources/browsers/index.d.ts.map +1 -1
  23. package/resources/browsers/index.js +3 -1
  24. package/resources/browsers/index.js.map +1 -1
  25. package/resources/browsers/index.mjs +1 -0
  26. package/resources/browsers/index.mjs.map +1 -1
  27. package/resources/browsers/live-view.d.mts +74 -0
  28. package/resources/browsers/live-view.d.mts.map +1 -0
  29. package/resources/browsers/live-view.d.ts +74 -0
  30. package/resources/browsers/live-view.d.ts.map +1 -0
  31. package/resources/browsers/live-view.js +33 -0
  32. package/resources/browsers/live-view.js.map +1 -0
  33. package/resources/browsers/live-view.mjs +29 -0
  34. package/resources/browsers/live-view.mjs.map +1 -0
  35. package/resources/index.d.mts +3 -0
  36. package/resources/index.d.mts.map +1 -1
  37. package/resources/index.d.ts +3 -0
  38. package/resources/index.d.ts.map +1 -1
  39. package/resources/index.js +7 -1
  40. package/resources/index.js.map +1 -1
  41. package/resources/index.mjs +3 -0
  42. package/resources/index.mjs.map +1 -1
  43. package/resources/report-types/index.d.mts +3 -0
  44. package/resources/report-types/index.d.mts.map +1 -0
  45. package/resources/report-types/index.d.ts +3 -0
  46. package/resources/report-types/index.d.ts.map +1 -0
  47. package/resources/report-types/index.js +9 -0
  48. package/resources/report-types/index.js.map +1 -0
  49. package/resources/report-types/index.mjs +4 -0
  50. package/resources/report-types/index.mjs.map +1 -0
  51. package/resources/report-types/report-types.d.mts +98 -0
  52. package/resources/report-types/report-types.d.mts.map +1 -0
  53. package/resources/report-types/report-types.d.ts +98 -0
  54. package/resources/report-types/report-types.d.ts.map +1 -0
  55. package/resources/report-types/report-types.js +38 -0
  56. package/resources/report-types/report-types.js.map +1 -0
  57. package/resources/report-types/report-types.mjs +33 -0
  58. package/resources/report-types/report-types.mjs.map +1 -0
  59. package/resources/report-types/versions.d.mts +47 -0
  60. package/resources/report-types/versions.d.mts.map +1 -0
  61. package/resources/report-types/versions.d.ts +47 -0
  62. package/resources/report-types/versions.d.ts.map +1 -0
  63. package/resources/report-types/versions.js +20 -0
  64. package/resources/report-types/versions.js.map +1 -0
  65. package/resources/report-types/versions.mjs +16 -0
  66. package/resources/report-types/versions.mjs.map +1 -0
  67. package/resources/report-types.d.mts +2 -0
  68. package/resources/report-types.d.mts.map +1 -0
  69. package/resources/report-types.d.ts +2 -0
  70. package/resources/report-types.d.ts.map +1 -0
  71. package/resources/report-types.js +6 -0
  72. package/resources/report-types.js.map +1 -0
  73. package/resources/report-types.mjs +3 -0
  74. package/resources/report-types.mjs.map +1 -0
  75. package/resources/reports.d.mts +136 -0
  76. package/resources/reports.d.mts.map +1 -0
  77. package/resources/reports.d.ts +136 -0
  78. package/resources/reports.d.ts.map +1 -0
  79. package/resources/reports.js +58 -0
  80. package/resources/reports.js.map +1 -0
  81. package/resources/reports.mjs +54 -0
  82. package/resources/reports.mjs.map +1 -0
  83. package/resources/tasks.d.mts +144 -0
  84. package/resources/tasks.d.mts.map +1 -0
  85. package/resources/tasks.d.ts +144 -0
  86. package/resources/tasks.d.ts.map +1 -0
  87. package/resources/tasks.js +67 -0
  88. package/resources/tasks.js.map +1 -0
  89. package/resources/tasks.mjs +63 -0
  90. package/resources/tasks.mjs.map +1 -0
  91. package/resources/vaults/items.d.mts +82 -17
  92. package/resources/vaults/items.d.mts.map +1 -1
  93. package/resources/vaults/items.d.ts +82 -17
  94. package/resources/vaults/items.d.ts.map +1 -1
  95. package/resources/vaults/items.js +4 -0
  96. package/resources/vaults/items.js.map +1 -1
  97. package/resources/vaults/items.mjs +4 -0
  98. package/resources/vaults/items.mjs.map +1 -1
  99. package/resources/vaults/vaults.d.mts +4 -1
  100. package/resources/vaults/vaults.d.mts.map +1 -1
  101. package/resources/vaults/vaults.d.ts +4 -1
  102. package/resources/vaults/vaults.d.ts.map +1 -1
  103. package/resources/vaults/vaults.js +4 -1
  104. package/resources/vaults/vaults.js.map +1 -1
  105. package/resources/vaults/vaults.mjs +4 -1
  106. package/resources/vaults/vaults.mjs.map +1 -1
  107. package/src/client.ts +66 -0
  108. package/src/resources/browsers/browsers.ts +18 -0
  109. package/src/resources/browsers/index.ts +7 -0
  110. package/src/resources/browsers/live-view.ts +97 -0
  111. package/src/resources/index.ts +24 -0
  112. package/src/resources/report-types/index.ts +11 -0
  113. package/src/resources/report-types/report-types.ts +137 -0
  114. package/src/resources/report-types/versions.ts +61 -0
  115. package/src/resources/report-types.ts +3 -0
  116. package/src/resources/reports.ts +166 -0
  117. package/src/resources/tasks.ts +183 -0
  118. package/src/resources/vaults/items.ts +86 -9
  119. package/src/resources/vaults/vaults.ts +4 -1
  120. package/src/version.ts +1 -1
  121. package/version.d.mts +1 -1
  122. package/version.d.ts +1 -1
  123. package/version.js +1 -1
  124. package/version.mjs +1 -1
@@ -44,7 +44,10 @@ class Vaults extends resource_1.APIResource {
44
44
  * first blocks new payments on it, then removes its enrolled card. If that fails,
45
45
  * the wallet is kept and keeps refusing payments; retry the deletion. Reconcile
46
46
  * the original attempt with the provider or support first; deleting or recreating
47
- * an item is not proof that a payment did not occur.
47
+ * an item is not proof that a payment did not occur. Each 1Password
48
+ * credential_account in the vault is ended the same way as deleting it; the vault
49
+ * is kept and this returns 409 provider_revocation_pending while 1Password has not
50
+ * confirmed a revoke.
48
51
  *
49
52
  * @example
50
53
  * ```ts
@@ -1 +1 @@
1
- {"version":3,"file":"vaults.js","sourceRoot":"","sources":["../../src/resources/vaults/vaults.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,qDAAkD;AAClD,6DAAoC;AACpC,sCAmGiB;AAEjB,yDAAmG;AACnG,uDAAsD;AAEtD,uDAAiD;AAEjD,MAAa,MAAO,SAAQ,sBAAW;IAAvC;;QACE,UAAK,GAAmB,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAsF3D,CAAC;IApFC;;;;;;;OAOG;IACH,QAAQ,CAAC,QAAgB,EAAE,OAAwB;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,WAAW,QAAQ,EAAE,EAAE,OAAO,CAAC,CAAC;IAC9D,CAAC;IAED;;;;;;;;;;OAUG;IACH,IAAI,CACF,QAA4C,EAAE,EAC9C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,SAAS,EAAE,CAAA,6BAAuB,CAAA,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5F,CAAC;IAED;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,QAAgB,EAAE,OAAwB;QAC/C,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAA,WAAI,EAAA,WAAW,QAAQ,EAAE,EAAE;YACpD,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;IAED;;;;;;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AC,OAAO,CAAC,MAAM,CAAC,IAAA,WAAI,EAAA,WAAW,QAAQ,EAAE,EAAE;YACpD,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;OAeG;IACH,qBAAqB,CAAC,QAAgB,EAAE,OAAwB;QAC9D,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,WAAW,QAAQ,iBAAiB,EAAE,OAAO,CAAC,CAAC;IAC7E,CAAC;IAED;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,IAAuB,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,SAAS,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5D,CAAC;CACF;AA1FD,wBA0FC;AAmFD,MAAM,CAAC,KAAK,GAAG,aAAK,CAAC"}
@@ -40,7 +40,10 @@ export class Vaults extends APIResource {
40
40
  * first blocks new payments on it, then removes its enrolled card. If that fails,
41
41
  * the wallet is kept and keeps refusing payments; retry the deletion. Reconcile
42
42
  * the original attempt with the provider or support first; deleting or recreating
43
- * an item is not proof that a payment did not occur.
43
+ * an item is not proof that a payment did not occur. Each 1Password
44
+ * credential_account in the vault is ended the same way as deleting it; the vault
45
+ * is kept and this returns 409 provider_revocation_pending while 1Password has not
46
+ * confirmed a revoke.
44
47
  *
45
48
  * @example
46
49
  * ```ts
@@ -1 +1 @@
1
- {"version":3,"file":"vaults.mjs","sourceRoot":"","sources":["../../src/resources/vaults/vaults.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,KAAK,QAAQ,oBAAgB;AACpC,OAAO,EAuCL,KAAK,GA4DN,oBAAgB;AAEjB,OAAO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AAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;OAeG;IACH,qBAAqB,CAAC,QAAgB,EAAE,OAAwB;QAC9D,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,WAAW,QAAQ,iBAAiB,EAAE,OAAO,CAAC,CAAC;IAC7E,CAAC;IAED;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,IAAuB,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,SAAS,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5D,CAAC;CACF;AAmFD,MAAM,CAAC,KAAK,GAAG,KAAK,CAAC"}
package/src/client.ts CHANGED
@@ -143,6 +143,22 @@ import {
143
143
  ProxyIPs,
144
144
  ProxyIPsOffsetPagination,
145
145
  } from './resources/proxy-ips';
146
+ import {
147
+ Report,
148
+ ReportCreateParams,
149
+ ReportListParams,
150
+ Reports,
151
+ ReportsOffsetPagination,
152
+ } from './resources/reports';
153
+ import {
154
+ Task,
155
+ TaskCreateParams,
156
+ TaskLinkBrowsersParams,
157
+ TaskListParams,
158
+ TaskMetadata,
159
+ Tasks,
160
+ TasksOffsetPagination,
161
+ } from './resources/tasks';
146
162
  import {
147
163
  VaultProviderConfig,
148
164
  VaultProviderConfigCreateParams,
@@ -233,6 +249,14 @@ import {
233
249
  ProjectsOffsetPagination,
234
250
  UpdateProjectRequest,
235
251
  } from './resources/projects/projects';
252
+ import {
253
+ ReportType,
254
+ ReportTypeListParams,
255
+ ReportTypeSummariesOffsetPagination,
256
+ ReportTypeSummary,
257
+ ReportTypeVersionSummary,
258
+ ReportTypes,
259
+ } from './resources/report-types/report-types';
236
260
  import {
237
261
  Attempt,
238
262
  ProviderTarget,
@@ -1095,6 +1119,18 @@ export class Kernel {
1095
1119
  * Create, list, retrieve, and delete browser profiles.
1096
1120
  */
1097
1121
  profiles: API.Profiles = new API.Profiles(this);
1122
+ /**
1123
+ * Define tasks that agents work toward and link the browsers they use.
1124
+ */
1125
+ tasks: API.Tasks = new API.Tasks(this);
1126
+ /**
1127
+ * Discover report types and submit typed reports against tasks.
1128
+ */
1129
+ reports: API.Reports = new API.Reports(this);
1130
+ /**
1131
+ * Discover report types and submit typed reports against tasks.
1132
+ */
1133
+ reportTypes: API.ReportTypes = new API.ReportTypes(this);
1098
1134
  auth: API.Auth = new API.Auth(this);
1099
1135
  telemetry: API.Telemetry = new API.Telemetry(this);
1100
1136
  /**
@@ -1148,6 +1184,9 @@ Kernel.Invocations = Invocations;
1148
1184
  Kernel.ConfigRegistry = ConfigRegistry;
1149
1185
  Kernel.Browsers = Browsers;
1150
1186
  Kernel.Profiles = Profiles;
1187
+ Kernel.Tasks = Tasks;
1188
+ Kernel.Reports = Reports;
1189
+ Kernel.ReportTypes = ReportTypes;
1151
1190
  Kernel.Auth = Auth;
1152
1191
  Kernel.Telemetry = Telemetry;
1153
1192
  Kernel.Proxies = Proxies;
@@ -1288,6 +1327,33 @@ export declare namespace Kernel {
1288
1327
  type ProfileDownloadParams as ProfileDownloadParams,
1289
1328
  };
1290
1329
 
1330
+ export {
1331
+ Tasks as Tasks,
1332
+ type Task as Task,
1333
+ type TaskMetadata as TaskMetadata,
1334
+ type TasksOffsetPagination as TasksOffsetPagination,
1335
+ type TaskCreateParams as TaskCreateParams,
1336
+ type TaskListParams as TaskListParams,
1337
+ type TaskLinkBrowsersParams as TaskLinkBrowsersParams,
1338
+ };
1339
+
1340
+ export {
1341
+ Reports as Reports,
1342
+ type Report as Report,
1343
+ type ReportsOffsetPagination as ReportsOffsetPagination,
1344
+ type ReportCreateParams as ReportCreateParams,
1345
+ type ReportListParams as ReportListParams,
1346
+ };
1347
+
1348
+ export {
1349
+ ReportTypes as ReportTypes,
1350
+ type ReportType as ReportType,
1351
+ type ReportTypeSummary as ReportTypeSummary,
1352
+ type ReportTypeVersionSummary as ReportTypeVersionSummary,
1353
+ type ReportTypeSummariesOffsetPagination as ReportTypeSummariesOffsetPagination,
1354
+ type ReportTypeListParams as ReportTypeListParams,
1355
+ };
1356
+
1291
1357
  export { Auth as Auth };
1292
1358
 
1293
1359
  export { Telemetry as Telemetry };
@@ -20,6 +20,14 @@ import {
20
20
  ComputerTypeTextParams,
21
21
  ComputerWriteClipboardParams,
22
22
  } from './computer';
23
+ import * as LiveViewAPI from './live-view';
24
+ import {
25
+ BrowserLiveView,
26
+ BrowserLiveViewRequest,
27
+ BrowserLiveViewScope,
28
+ LiveView,
29
+ LiveViewCreateParams,
30
+ } from './live-view';
23
31
  import * as LogsAPI from './logs';
24
32
  import { LogStreamParams, Logs } from './logs';
25
33
  import * as ProcessAPI from './process';
@@ -161,6 +169,7 @@ import { browserFetch, type BrowserFetchInit } from '../../lib/browser-fetch';
161
169
 
162
170
  export class Browsers extends APIResource {
163
171
  telemetry: TelemetryAPI.Telemetry = new TelemetryAPI.Telemetry(this._client);
172
+ liveView: LiveViewAPI.LiveView = new LiveViewAPI.LiveView(this._client);
164
173
  replays: ReplaysAPI.Replays = new ReplaysAPI.Replays(this._client);
165
174
  fs: FsAPI.Fs = new FsAPI.Fs(this._client);
166
175
  process: ProcessAPI.Process = new ProcessAPI.Process(this._client);
@@ -2441,6 +2450,7 @@ export interface BrowserSaveProfileParams {
2441
2450
  }
2442
2451
 
2443
2452
  Browsers.Telemetry = TelemetryAPITelemetry;
2453
+ Browsers.LiveView = LiveView;
2444
2454
  Browsers.Replays = Replays;
2445
2455
  Browsers.Fs = Fs;
2446
2456
  Browsers.Process = Process;
@@ -2551,6 +2561,14 @@ export declare namespace Browsers {
2551
2561
  type TelemetryStreamParams as TelemetryStreamParams,
2552
2562
  };
2553
2563
 
2564
+ export {
2565
+ LiveView as LiveView,
2566
+ type BrowserLiveView as BrowserLiveView,
2567
+ type BrowserLiveViewRequest as BrowserLiveViewRequest,
2568
+ type BrowserLiveViewScope as BrowserLiveViewScope,
2569
+ type LiveViewCreateParams as LiveViewCreateParams,
2570
+ };
2571
+
2554
2572
  export {
2555
2573
  Replays as Replays,
2556
2574
  type ReplayListResponse as ReplayListResponse,
@@ -76,6 +76,13 @@ export {
76
76
  type FUploadZipParams,
77
77
  type FWriteFileParams,
78
78
  } from './fs/index';
79
+ export {
80
+ LiveView,
81
+ type BrowserLiveView,
82
+ type BrowserLiveViewRequest,
83
+ type BrowserLiveViewScope,
84
+ type LiveViewCreateParams,
85
+ } from './live-view';
79
86
  export { Logs, type LogStreamParams } from './logs';
80
87
  export {
81
88
  Playwright,
@@ -0,0 +1,97 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../core/resource';
4
+ import { APIPromise } from '../../core/api-promise';
5
+ import { RequestOptions } from '../../internal/request-options';
6
+ import { path } from '../../internal/utils/path';
7
+
8
+ /**
9
+ * Create and manage browser sessions.
10
+ */
11
+ export class LiveView extends APIResource {
12
+ /**
13
+ * Creates a live view URL for a headful browser that grants either read-only or
14
+ * control access. The URL works only for the live view: it cannot connect to CDP,
15
+ * WebDriver, or any other browser endpoint. A read-only URL shows the browser but
16
+ * cannot send input, regardless of query parameters. The URL stays valid until the
17
+ * browser is deleted, or until `ttl_seconds` elapse when set. For a browser
18
+ * acquired from a pool, it stops working when the browser is released. Nothing is
19
+ * stored, so a URL cannot be revoked before then.
20
+ *
21
+ * @example
22
+ * ```ts
23
+ * const browserLiveView =
24
+ * await client.browsers.liveView.create(
25
+ * 'htzv5orfit78e1m2biiifpbv',
26
+ * );
27
+ * ```
28
+ */
29
+ create(
30
+ idOrName: string,
31
+ body: LiveViewCreateParams | null | undefined = {},
32
+ options?: RequestOptions,
33
+ ): APIPromise<BrowserLiveView> {
34
+ return this._client.post(path`/browsers/${idOrName}/live_view`, { body, ...options });
35
+ }
36
+ }
37
+
38
+ export interface BrowserLiveView {
39
+ /**
40
+ * `read` shows the browser without accepting input. `control` also lets the viewer
41
+ * drive the browser through the live view.
42
+ */
43
+ scope: BrowserLiveViewScope;
44
+
45
+ /**
46
+ * Live view URL. Treat it as a credential.
47
+ */
48
+ url: string;
49
+
50
+ /**
51
+ * When the URL expires. Absent when it stays valid until the browser is deleted.
52
+ */
53
+ expires_at?: string;
54
+ }
55
+
56
+ export interface BrowserLiveViewRequest {
57
+ /**
58
+ * `read` shows the browser without accepting input. `control` also lets the viewer
59
+ * drive the browser through the live view.
60
+ */
61
+ scope?: BrowserLiveViewScope;
62
+
63
+ /**
64
+ * Seconds until the URL expires. Omit to keep it valid until the browser is
65
+ * deleted.
66
+ */
67
+ ttl_seconds?: number;
68
+ }
69
+
70
+ /**
71
+ * `read` shows the browser without accepting input. `control` also lets the viewer
72
+ * drive the browser through the live view.
73
+ */
74
+ export type BrowserLiveViewScope = 'read' | 'control';
75
+
76
+ export interface LiveViewCreateParams {
77
+ /**
78
+ * `read` shows the browser without accepting input. `control` also lets the viewer
79
+ * drive the browser through the live view.
80
+ */
81
+ scope?: BrowserLiveViewScope;
82
+
83
+ /**
84
+ * Seconds until the URL expires. Omit to keep it valid until the browser is
85
+ * deleted.
86
+ */
87
+ ttl_seconds?: number;
88
+ }
89
+
90
+ export declare namespace LiveView {
91
+ export {
92
+ type BrowserLiveView as BrowserLiveView,
93
+ type BrowserLiveViewRequest as BrowserLiveViewRequest,
94
+ type BrowserLiveViewScope as BrowserLiveViewScope,
95
+ type LiveViewCreateParams as LiveViewCreateParams,
96
+ };
97
+ }
@@ -202,6 +202,21 @@ export {
202
202
  type ProxyIPListParams,
203
203
  type ProxyIPsOffsetPagination,
204
204
  } from './proxy-ips';
205
+ export {
206
+ ReportTypes,
207
+ type ReportType,
208
+ type ReportTypeSummary,
209
+ type ReportTypeVersionSummary,
210
+ type ReportTypeListParams,
211
+ type ReportTypeSummariesOffsetPagination,
212
+ } from './report-types/report-types';
213
+ export {
214
+ Reports,
215
+ type Report,
216
+ type ReportCreateParams,
217
+ type ReportListParams,
218
+ type ReportsOffsetPagination,
219
+ } from './reports';
205
220
  export {
206
221
  SearchResource,
207
222
  type Attempt,
@@ -214,6 +229,15 @@ export {
214
229
  type Warning,
215
230
  type SearchCreateParams,
216
231
  } from './search/search';
232
+ export {
233
+ Tasks,
234
+ type Task,
235
+ type TaskMetadata,
236
+ type TaskCreateParams,
237
+ type TaskListParams,
238
+ type TaskLinkBrowsersParams,
239
+ type TasksOffsetPagination,
240
+ } from './tasks';
217
241
  export { Telemetry } from './telemetry/telemetry';
218
242
  export {
219
243
  VaultProviderConfigs,
@@ -0,0 +1,11 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ export {
4
+ ReportTypes,
5
+ type ReportType,
6
+ type ReportTypeSummary,
7
+ type ReportTypeVersionSummary,
8
+ type ReportTypeListParams,
9
+ type ReportTypeSummariesOffsetPagination,
10
+ } from './report-types';
11
+ export { Versions, type ReportTypeVersion, type VersionRetrieveParams } from './versions';
@@ -0,0 +1,137 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../core/resource';
4
+ import * as VersionsAPI from './versions';
5
+ import { ReportTypeVersion, VersionRetrieveParams, Versions } from './versions';
6
+ import { APIPromise } from '../../core/api-promise';
7
+ import { OffsetPagination, type OffsetPaginationParams, PagePromise } from '../../core/pagination';
8
+ import { RequestOptions } from '../../internal/request-options';
9
+ import { path } from '../../internal/utils/path';
10
+
11
+ /**
12
+ * Discover report types and submit typed reports against tasks.
13
+ */
14
+ export class ReportTypes extends APIResource {
15
+ versions: VersionsAPI.Versions = new VersionsAPI.Versions(this._client);
16
+
17
+ /**
18
+ * Retrieve a report type, its versions, and the JSON Schema of its latest version.
19
+ */
20
+ retrieve(type: string, options?: RequestOptions): APIPromise<ReportType> {
21
+ return this._client.get(path`/report_types/${type}`, options);
22
+ }
23
+
24
+ /**
25
+ * List the report types agents can submit for a task. Retrieve a type for the JSON
26
+ * Schema of its data.
27
+ */
28
+ list(
29
+ query: ReportTypeListParams,
30
+ options?: RequestOptions,
31
+ ): PagePromise<ReportTypeSummariesOffsetPagination, ReportTypeSummary> {
32
+ return this._client.getAPIList('/report_types', OffsetPagination<ReportTypeSummary>, {
33
+ query,
34
+ ...options,
35
+ });
36
+ }
37
+ }
38
+
39
+ export type ReportTypeSummariesOffsetPagination = OffsetPagination<ReportTypeSummary>;
40
+
41
+ /**
42
+ * A kind of report agents can submit against a task, with its versions and the
43
+ * JSON Schema of its latest version. A shipped version never changes; changes ship
44
+ * as new versions.
45
+ */
46
+ export interface ReportType {
47
+ /**
48
+ * What the report type records and when to submit it
49
+ */
50
+ description: string;
51
+
52
+ /**
53
+ * Highest version that is not retired. A report submitted without a schema_version
54
+ * uses this version. It is 0 when every version is retired.
55
+ */
56
+ latest_version: number;
57
+
58
+ /**
59
+ * JSON Schema (draft 2020-12) of the latest version, which a report's data must
60
+ * match. Its field descriptions and examples describe what to send. Null when
61
+ * every version is retired.
62
+ */
63
+ schema: { [key: string]: unknown } | null;
64
+
65
+ /**
66
+ * Report type name, such as task.result
67
+ */
68
+ type: string;
69
+
70
+ /**
71
+ * Every version of the type, oldest first, including retired versions.
72
+ */
73
+ versions: Array<ReportTypeVersionSummary>;
74
+ }
75
+
76
+ /**
77
+ * A kind of report agents can submit against a task. Retrieve the type for the
78
+ * JSON Schema of its data.
79
+ */
80
+ export interface ReportTypeSummary {
81
+ /**
82
+ * What the report type records and when to submit it
83
+ */
84
+ description: string;
85
+
86
+ /**
87
+ * Highest version that is not retired. A report submitted without a schema_version
88
+ * uses this version. It is 0 when every version is retired.
89
+ */
90
+ latest_version: number;
91
+
92
+ /**
93
+ * Report type name, such as task.result
94
+ */
95
+ type: string;
96
+ }
97
+
98
+ /**
99
+ * One schema version of a report type, without its schema.
100
+ */
101
+ export interface ReportTypeVersionSummary {
102
+ /**
103
+ * Whether the version is retired. Retired versions are no longer accepted for new
104
+ * reports; existing reports keep them.
105
+ */
106
+ retired: boolean;
107
+
108
+ /**
109
+ * Schema version number, starting at 1.
110
+ */
111
+ version: number;
112
+ }
113
+
114
+ export interface ReportTypeListParams extends OffsetPaginationParams {
115
+ /**
116
+ * Task the agent is finding a report type for.
117
+ */
118
+ task_id: string;
119
+ }
120
+
121
+ ReportTypes.Versions = Versions;
122
+
123
+ export declare namespace ReportTypes {
124
+ export {
125
+ type ReportType as ReportType,
126
+ type ReportTypeSummary as ReportTypeSummary,
127
+ type ReportTypeVersionSummary as ReportTypeVersionSummary,
128
+ type ReportTypeSummariesOffsetPagination as ReportTypeSummariesOffsetPagination,
129
+ type ReportTypeListParams as ReportTypeListParams,
130
+ };
131
+
132
+ export {
133
+ Versions as Versions,
134
+ type ReportTypeVersion as ReportTypeVersion,
135
+ type VersionRetrieveParams as VersionRetrieveParams,
136
+ };
137
+ }
@@ -0,0 +1,61 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../core/resource';
4
+ import { APIPromise } from '../../core/api-promise';
5
+ import { RequestOptions } from '../../internal/request-options';
6
+ import { path } from '../../internal/utils/path';
7
+
8
+ /**
9
+ * Discover report types and submit typed reports against tasks.
10
+ */
11
+ export class Versions extends APIResource {
12
+ /**
13
+ * Retrieve one schema version of a report type, including retired versions.
14
+ */
15
+ retrieve(
16
+ version: number,
17
+ params: VersionRetrieveParams,
18
+ options?: RequestOptions,
19
+ ): APIPromise<ReportTypeVersion> {
20
+ const { type } = params;
21
+ return this._client.get(path`/report_types/${type}/versions/${version}`, options);
22
+ }
23
+ }
24
+
25
+ /**
26
+ * One immutable schema version of a report type.
27
+ */
28
+ export interface ReportTypeVersion {
29
+ /**
30
+ * Whether the version is retired. Retired versions are no longer accepted for new
31
+ * reports; existing reports keep them.
32
+ */
33
+ retired: boolean;
34
+
35
+ /**
36
+ * JSON Schema (draft 2020-12) that a report's data must match. Its field
37
+ * descriptions and examples describe what to send.
38
+ */
39
+ schema: { [key: string]: unknown };
40
+
41
+ /**
42
+ * Report type name, such as task.result
43
+ */
44
+ type: string;
45
+
46
+ /**
47
+ * Schema version number, starting at 1.
48
+ */
49
+ version: number;
50
+ }
51
+
52
+ export interface VersionRetrieveParams {
53
+ /**
54
+ * Report type name, such as task.result
55
+ */
56
+ type: string;
57
+ }
58
+
59
+ export declare namespace Versions {
60
+ export { type ReportTypeVersion as ReportTypeVersion, type VersionRetrieveParams as VersionRetrieveParams };
61
+ }
@@ -0,0 +1,3 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ export * from './report-types/index';