@onkernel/sdk 0.21.0 → 0.23.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 (111) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/README.md +15 -19
  3. package/client.d.mts +3 -0
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +3 -0
  6. package/client.d.ts.map +1 -1
  7. package/client.js +3 -0
  8. package/client.js.map +1 -1
  9. package/client.mjs +3 -0
  10. package/client.mjs.map +1 -1
  11. package/package.json +1 -1
  12. package/resources/agents/agents.d.mts +10 -0
  13. package/resources/agents/agents.d.mts.map +1 -0
  14. package/resources/agents/agents.d.ts +10 -0
  15. package/resources/agents/agents.d.ts.map +1 -0
  16. package/resources/agents/agents.js +17 -0
  17. package/resources/agents/agents.js.map +1 -0
  18. package/resources/agents/agents.mjs +12 -0
  19. package/resources/agents/agents.mjs.map +1 -0
  20. package/resources/agents/auth/auth.d.mts +294 -0
  21. package/resources/agents/auth/auth.d.mts.map +1 -0
  22. package/resources/agents/auth/auth.d.ts +294 -0
  23. package/resources/agents/auth/auth.d.ts.map +1 -0
  24. package/resources/agents/auth/auth.js +62 -0
  25. package/resources/agents/auth/auth.js.map +1 -0
  26. package/resources/agents/auth/auth.mjs +57 -0
  27. package/resources/agents/auth/auth.mjs.map +1 -0
  28. package/resources/agents/auth/index.d.mts +3 -0
  29. package/resources/agents/auth/index.d.mts.map +1 -0
  30. package/resources/agents/auth/index.d.ts +3 -0
  31. package/resources/agents/auth/index.d.ts.map +1 -0
  32. package/resources/agents/auth/index.js +9 -0
  33. package/resources/agents/auth/index.js.map +1 -0
  34. package/resources/agents/auth/index.mjs +4 -0
  35. package/resources/agents/auth/index.mjs.map +1 -0
  36. package/resources/agents/auth/invocations.d.mts +124 -0
  37. package/resources/agents/auth/invocations.d.mts.map +1 -0
  38. package/resources/agents/auth/invocations.d.ts +124 -0
  39. package/resources/agents/auth/invocations.d.ts.map +1 -0
  40. package/resources/agents/auth/invocations.js +94 -0
  41. package/resources/agents/auth/invocations.js.map +1 -0
  42. package/resources/agents/auth/invocations.mjs +90 -0
  43. package/resources/agents/auth/invocations.mjs.map +1 -0
  44. package/resources/agents/auth.d.mts +2 -0
  45. package/resources/agents/auth.d.mts.map +1 -0
  46. package/resources/agents/auth.d.ts +2 -0
  47. package/resources/agents/auth.d.ts.map +1 -0
  48. package/resources/agents/auth.js +6 -0
  49. package/resources/agents/auth.js.map +1 -0
  50. package/resources/agents/auth.mjs +3 -0
  51. package/resources/agents/auth.mjs.map +1 -0
  52. package/resources/agents/index.d.mts +3 -0
  53. package/resources/agents/index.d.mts.map +1 -0
  54. package/resources/agents/index.d.ts +3 -0
  55. package/resources/agents/index.d.ts.map +1 -0
  56. package/resources/agents/index.js +9 -0
  57. package/resources/agents/index.js.map +1 -0
  58. package/resources/agents/index.mjs +4 -0
  59. package/resources/agents/index.mjs.map +1 -0
  60. package/resources/agents.d.mts +2 -0
  61. package/resources/agents.d.mts.map +1 -0
  62. package/resources/agents.d.ts +2 -0
  63. package/resources/agents.d.ts.map +1 -0
  64. package/resources/agents.js +6 -0
  65. package/resources/agents.js.map +1 -0
  66. package/resources/agents.mjs +3 -0
  67. package/resources/agents.mjs.map +1 -0
  68. package/resources/browser-pools.d.mts +24 -23
  69. package/resources/browser-pools.d.mts.map +1 -1
  70. package/resources/browser-pools.d.ts +24 -23
  71. package/resources/browser-pools.d.ts.map +1 -1
  72. package/resources/browsers/browsers.d.mts +38 -38
  73. package/resources/browsers/browsers.d.mts.map +1 -1
  74. package/resources/browsers/browsers.d.ts +38 -38
  75. package/resources/browsers/browsers.d.ts.map +1 -1
  76. package/resources/browsers/browsers.js +3 -7
  77. package/resources/browsers/browsers.js.map +1 -1
  78. package/resources/browsers/browsers.mjs +3 -7
  79. package/resources/browsers/browsers.mjs.map +1 -1
  80. package/resources/index.d.mts +1 -0
  81. package/resources/index.d.mts.map +1 -1
  82. package/resources/index.d.ts +1 -0
  83. package/resources/index.d.ts.map +1 -1
  84. package/resources/index.js +3 -1
  85. package/resources/index.js.map +1 -1
  86. package/resources/index.mjs +1 -0
  87. package/resources/index.mjs.map +1 -1
  88. package/resources/invocations.d.mts +5 -0
  89. package/resources/invocations.d.mts.map +1 -1
  90. package/resources/invocations.d.ts +5 -0
  91. package/resources/invocations.d.ts.map +1 -1
  92. package/resources/shared.d.mts +5 -5
  93. package/resources/shared.d.ts +5 -5
  94. package/src/client.ts +5 -0
  95. package/src/resources/agents/agents.ts +41 -0
  96. package/src/resources/agents/auth/auth.ts +385 -0
  97. package/src/resources/agents/auth/index.ts +24 -0
  98. package/src/resources/agents/auth/invocations.ts +167 -0
  99. package/src/resources/agents/auth.ts +3 -0
  100. package/src/resources/agents/index.ts +17 -0
  101. package/src/resources/agents.ts +3 -0
  102. package/src/resources/browser-pools.ts +24 -23
  103. package/src/resources/browsers/browsers.ts +38 -38
  104. package/src/resources/index.ts +1 -0
  105. package/src/resources/invocations.ts +6 -0
  106. package/src/resources/shared.ts +5 -5
  107. package/src/version.ts +1 -1
  108. package/version.d.mts +1 -1
  109. package/version.d.ts +1 -1
  110. package/version.js +1 -1
  111. package/version.mjs +1 -1
@@ -127,14 +127,10 @@ export class Browsers extends APIResource {
127
127
  }
128
128
 
129
129
  /**
130
- * Delete a persistent browser session by its persistent_id.
130
+ * DEPRECATED: Use DELETE /browsers/{id} instead. Delete a persistent browser
131
+ * session by its persistent_id.
131
132
  *
132
- * @example
133
- * ```ts
134
- * await client.browsers.delete({
135
- * persistent_id: 'persistent_id',
136
- * });
137
- * ```
133
+ * @deprecated
138
134
  */
139
135
  delete(params: BrowserDeleteParams, options?: RequestOptions): APIPromise<void> {
140
136
  const { persistent_id } = params;
@@ -192,11 +188,12 @@ export class Browsers extends APIResource {
192
188
  export type BrowserListResponsesOffsetPagination = OffsetPagination<BrowserListResponse>;
193
189
 
194
190
  /**
195
- * Optional persistence configuration for the browser session.
191
+ * @deprecated DEPRECATED: Use timeout_seconds (up to 72 hours) and Profiles
192
+ * instead.
196
193
  */
197
194
  export interface BrowserPersistence {
198
195
  /**
199
- * Unique identifier for the persistent browser session.
196
+ * DEPRECATED: Unique identifier for the persistent browser session.
200
197
  */
201
198
  id: string;
202
199
  }
@@ -279,7 +276,8 @@ export interface BrowserCreateResponse {
279
276
  kiosk_mode?: boolean;
280
277
 
281
278
  /**
282
- * Optional persistence configuration for the browser session.
279
+ * @deprecated DEPRECATED: Use timeout_seconds (up to 72 hours) and Profiles
280
+ * instead.
283
281
  */
284
282
  persistence?: BrowserPersistence;
285
283
 
@@ -295,11 +293,11 @@ export interface BrowserCreateResponse {
295
293
 
296
294
  /**
297
295
  * Initial browser window size in pixels with optional refresh rate. If omitted,
298
- * image defaults apply (commonly 1024x768@60). Only specific viewport
299
- * configurations are supported. The server will reject unsupported combinations.
300
- * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
301
- * 1440x900@25, 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will
302
- * be automatically determined from the width and height if they match a supported
296
+ * image defaults apply (1920x1080@25). Only specific viewport configurations are
297
+ * supported. The server will reject unsupported combinations. Supported
298
+ * resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25, 1440x900@25,
299
+ * 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will be
300
+ * automatically determined from the width and height if they match a supported
303
301
  * configuration exactly. Note: Higher resolutions may affect the responsiveness of
304
302
  * live view browser
305
303
  */
@@ -354,7 +352,8 @@ export interface BrowserRetrieveResponse {
354
352
  kiosk_mode?: boolean;
355
353
 
356
354
  /**
357
- * Optional persistence configuration for the browser session.
355
+ * @deprecated DEPRECATED: Use timeout_seconds (up to 72 hours) and Profiles
356
+ * instead.
358
357
  */
359
358
  persistence?: BrowserPersistence;
360
359
 
@@ -370,11 +369,11 @@ export interface BrowserRetrieveResponse {
370
369
 
371
370
  /**
372
371
  * Initial browser window size in pixels with optional refresh rate. If omitted,
373
- * image defaults apply (commonly 1024x768@60). Only specific viewport
374
- * configurations are supported. The server will reject unsupported combinations.
375
- * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
376
- * 1440x900@25, 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will
377
- * be automatically determined from the width and height if they match a supported
372
+ * image defaults apply (1920x1080@25). Only specific viewport configurations are
373
+ * supported. The server will reject unsupported combinations. Supported
374
+ * resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25, 1440x900@25,
375
+ * 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will be
376
+ * automatically determined from the width and height if they match a supported
378
377
  * configuration exactly. Note: Higher resolutions may affect the responsiveness of
379
378
  * live view browser
380
379
  */
@@ -429,7 +428,8 @@ export interface BrowserListResponse {
429
428
  kiosk_mode?: boolean;
430
429
 
431
430
  /**
432
- * Optional persistence configuration for the browser session.
431
+ * @deprecated DEPRECATED: Use timeout_seconds (up to 72 hours) and Profiles
432
+ * instead.
433
433
  */
434
434
  persistence?: BrowserPersistence;
435
435
 
@@ -445,11 +445,11 @@ export interface BrowserListResponse {
445
445
 
446
446
  /**
447
447
  * Initial browser window size in pixels with optional refresh rate. If omitted,
448
- * image defaults apply (commonly 1024x768@60). Only specific viewport
449
- * configurations are supported. The server will reject unsupported combinations.
450
- * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
451
- * 1440x900@25, 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will
452
- * be automatically determined from the width and height if they match a supported
448
+ * image defaults apply (1920x1080@25). Only specific viewport configurations are
449
+ * supported. The server will reject unsupported combinations. Supported
450
+ * resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25, 1440x900@25,
451
+ * 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will be
452
+ * automatically determined from the width and height if they match a supported
453
453
  * configuration exactly. Note: Higher resolutions may affect the responsiveness of
454
454
  * live view browser
455
455
  */
@@ -480,7 +480,8 @@ export interface BrowserCreateParams {
480
480
  kiosk_mode?: boolean;
481
481
 
482
482
  /**
483
- * Optional persistence configuration for the browser session.
483
+ * @deprecated DEPRECATED: Use timeout_seconds (up to 72 hours) and Profiles
484
+ * instead.
484
485
  */
485
486
  persistence?: BrowserPersistence;
486
487
 
@@ -505,21 +506,20 @@ export interface BrowserCreateParams {
505
506
 
506
507
  /**
507
508
  * The number of seconds of inactivity before the browser session is terminated.
508
- * Only applicable to non-persistent browsers. Activity includes CDP connections
509
- * and live view connections. Defaults to 60 seconds. Minimum allowed is 10
510
- * seconds. Maximum allowed is 259200 (72 hours). We check for inactivity every 5
511
- * seconds, so the actual timeout behavior you will see is +/- 5 seconds around the
512
- * specified value.
509
+ * Activity includes CDP connections and live view connections. Defaults to 60
510
+ * seconds. Minimum allowed is 10 seconds. Maximum allowed is 259200 (72 hours). We
511
+ * check for inactivity every 5 seconds, so the actual timeout behavior you will
512
+ * see is +/- 5 seconds around the specified value.
513
513
  */
514
514
  timeout_seconds?: number;
515
515
 
516
516
  /**
517
517
  * Initial browser window size in pixels with optional refresh rate. If omitted,
518
- * image defaults apply (commonly 1024x768@60). Only specific viewport
519
- * configurations are supported. The server will reject unsupported combinations.
520
- * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
521
- * 1440x900@25, 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will
522
- * be automatically determined from the width and height if they match a supported
518
+ * image defaults apply (1920x1080@25). Only specific viewport configurations are
519
+ * supported. The server will reject unsupported combinations. Supported
520
+ * resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25, 1440x900@25,
521
+ * 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will be
522
+ * automatically determined from the width and height if they match a supported
523
523
  * configuration exactly. Note: Higher resolutions may affect the responsiveness of
524
524
  * live view browser
525
525
  */
@@ -1,6 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
  export * from './shared';
4
+ export { Agents } from './agents/agents';
4
5
  export {
5
6
  Apps,
6
7
  type AppListResponse,
@@ -416,6 +416,12 @@ export interface InvocationCreateParams {
416
416
  */
417
417
  async?: boolean;
418
418
 
419
+ /**
420
+ * Timeout in seconds for async invocations (min 10, max 3600). Only applies when
421
+ * async is true.
422
+ */
423
+ async_timeout_seconds?: number;
424
+
419
425
  /**
420
426
  * Input data for the action, sent as a JSON string.
421
427
  */
@@ -53,11 +53,11 @@ export interface BrowserProfile {
53
53
 
54
54
  /**
55
55
  * Initial browser window size in pixels with optional refresh rate. If omitted,
56
- * image defaults apply (commonly 1024x768@60). Only specific viewport
57
- * configurations are supported. The server will reject unsupported combinations.
58
- * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
59
- * 1440x900@25, 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will
60
- * be automatically determined from the width and height if they match a supported
56
+ * image defaults apply (1920x1080@25). Only specific viewport configurations are
57
+ * supported. The server will reject unsupported combinations. Supported
58
+ * resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25, 1440x900@25,
59
+ * 1024x768@60, 1200x800@60 If refresh_rate is not provided, it will be
60
+ * automatically determined from the width and height if they match a supported
61
61
  * configuration exactly. Note: Higher resolutions may affect the responsiveness of
62
62
  * live view browser
63
63
  */
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.21.0'; // x-release-please-version
1
+ export const VERSION = '0.23.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.21.0";
1
+ export declare const VERSION = "0.23.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.21.0";
1
+ export declare const VERSION = "0.23.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.21.0'; // x-release-please-version
4
+ exports.VERSION = '0.23.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.21.0'; // x-release-please-version
1
+ export const VERSION = '0.23.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map