@onkernel/sdk 0.90.0 → 0.91.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 (95) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/client.d.mts +5 -2
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +5 -2
  5. package/client.d.ts.map +1 -1
  6. package/client.js +3 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +3 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/browser-pools.d.mts +4 -0
  12. package/resources/browser-pools.d.mts.map +1 -1
  13. package/resources/browser-pools.d.ts +4 -0
  14. package/resources/browser-pools.d.ts.map +1 -1
  15. package/resources/browsers/browsers.d.mts +29 -1
  16. package/resources/browsers/browsers.d.mts.map +1 -1
  17. package/resources/browsers/browsers.d.ts +29 -1
  18. package/resources/browsers/browsers.d.ts.map +1 -1
  19. package/resources/browsers/browsers.js.map +1 -1
  20. package/resources/browsers/browsers.mjs.map +1 -1
  21. package/resources/browsers/index.d.mts +1 -1
  22. package/resources/browsers/index.d.mts.map +1 -1
  23. package/resources/browsers/index.d.ts +1 -1
  24. package/resources/browsers/index.d.ts.map +1 -1
  25. package/resources/browsers/index.js.map +1 -1
  26. package/resources/browsers/index.mjs.map +1 -1
  27. package/resources/browsers/telemetry.d.mts +1 -1
  28. package/resources/browsers/telemetry.d.ts +1 -1
  29. package/resources/browsers/telemetry.js +1 -1
  30. package/resources/browsers/telemetry.mjs +1 -1
  31. package/resources/credential-providers.d.mts +8 -4
  32. package/resources/credential-providers.d.mts.map +1 -1
  33. package/resources/credential-providers.d.ts +8 -4
  34. package/resources/credential-providers.d.ts.map +1 -1
  35. package/resources/index.d.mts +2 -1
  36. package/resources/index.d.mts.map +1 -1
  37. package/resources/index.d.ts +2 -1
  38. package/resources/index.d.ts.map +1 -1
  39. package/resources/index.js +3 -1
  40. package/resources/index.js.map +1 -1
  41. package/resources/index.mjs +1 -0
  42. package/resources/index.mjs.map +1 -1
  43. package/resources/invocations.d.mts +4 -0
  44. package/resources/invocations.d.mts.map +1 -1
  45. package/resources/invocations.d.ts +4 -0
  46. package/resources/invocations.d.ts.map +1 -1
  47. package/resources/telemetry/destinations.d.mts +138 -0
  48. package/resources/telemetry/destinations.d.mts.map +1 -0
  49. package/resources/telemetry/destinations.d.ts +138 -0
  50. package/resources/telemetry/destinations.d.ts.map +1 -0
  51. package/resources/telemetry/destinations.js +63 -0
  52. package/resources/telemetry/destinations.js.map +1 -0
  53. package/resources/telemetry/destinations.mjs +59 -0
  54. package/resources/telemetry/destinations.mjs.map +1 -0
  55. package/resources/telemetry/index.d.mts +3 -0
  56. package/resources/telemetry/index.d.mts.map +1 -0
  57. package/resources/telemetry/index.d.ts +3 -0
  58. package/resources/telemetry/index.d.ts.map +1 -0
  59. package/resources/telemetry/index.js +9 -0
  60. package/resources/telemetry/index.js.map +1 -0
  61. package/resources/telemetry/index.mjs +4 -0
  62. package/resources/telemetry/index.mjs.map +1 -0
  63. package/resources/telemetry/telemetry.d.mts +10 -0
  64. package/resources/telemetry/telemetry.d.mts.map +1 -0
  65. package/resources/telemetry/telemetry.d.ts +10 -0
  66. package/resources/telemetry/telemetry.d.ts.map +1 -0
  67. package/resources/telemetry/telemetry.js +17 -0
  68. package/resources/telemetry/telemetry.js.map +1 -0
  69. package/resources/telemetry/telemetry.mjs +12 -0
  70. package/resources/telemetry/telemetry.mjs.map +1 -0
  71. package/resources/telemetry.d.mts +2 -0
  72. package/resources/telemetry.d.mts.map +1 -0
  73. package/resources/telemetry.d.ts +2 -0
  74. package/resources/telemetry.d.ts.map +1 -0
  75. package/resources/telemetry.js +6 -0
  76. package/resources/telemetry.js.map +1 -0
  77. package/resources/telemetry.mjs +3 -0
  78. package/resources/telemetry.mjs.map +1 -0
  79. package/src/client.ts +9 -0
  80. package/src/resources/browser-pools.ts +5 -0
  81. package/src/resources/browsers/browsers.ts +37 -0
  82. package/src/resources/browsers/index.ts +2 -0
  83. package/src/resources/browsers/telemetry.ts +1 -1
  84. package/src/resources/credential-providers.ts +8 -4
  85. package/src/resources/index.ts +3 -0
  86. package/src/resources/invocations.ts +5 -0
  87. package/src/resources/telemetry/destinations.ts +188 -0
  88. package/src/resources/telemetry/index.ts +11 -0
  89. package/src/resources/telemetry/telemetry.ts +29 -0
  90. package/src/resources/telemetry.ts +3 -0
  91. package/src/version.ts +1 -1
  92. package/version.d.mts +1 -1
  93. package/version.d.ts +1 -1
  94. package/version.js +1 -1
  95. package/version.mjs +1 -1
@@ -0,0 +1,59 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../../core/resource.mjs";
3
+ import { OffsetPagination } from "../../core/pagination.mjs";
4
+ import { buildHeaders } from "../../internal/headers.mjs";
5
+ import { path } from "../../internal/utils/path.mjs";
6
+ /**
7
+ * Stream live telemetry events from a browser session, and manage the destinations sessions export them to.
8
+ */
9
+ export class Destinations extends APIResource {
10
+ /**
11
+ * Create an OTLP export destination in the resolved project. Names must be unique
12
+ * within the project.
13
+ */
14
+ create(body, options) {
15
+ return this._client.post('/telemetry/destinations', { body, ...options });
16
+ }
17
+ /**
18
+ * Retrieve a single OTLP destination in the resolved project by its ID or name.
19
+ */
20
+ retrieve(idOrName, options) {
21
+ return this._client.get(path `/telemetry/destinations/${idOrName}`, options);
22
+ }
23
+ /**
24
+ * Update an OTLP destination. Sessions already exporting to it pick up the new
25
+ * values without restarting, which makes this the way to rotate credentials
26
+ * without interrupting export.
27
+ *
28
+ * Names must be unique within the project. Renaming is refused with a 409 while a
29
+ * managed auth connection selects this destination by name, since that connection
30
+ * resolves the name on every login. Every other field, including `headers`, stays
31
+ * editable.
32
+ */
33
+ update(idOrName, body, options) {
34
+ return this._client.patch(path `/telemetry/destinations/${idOrName}`, { body, ...options });
35
+ }
36
+ /**
37
+ * List OTLP export destinations in the resolved project.
38
+ */
39
+ list(query = {}, options) {
40
+ return this._client.getAPIList('/telemetry/destinations', (OffsetPagination), {
41
+ query,
42
+ ...options,
43
+ });
44
+ }
45
+ /**
46
+ * Delete an OTLP destination. Sessions bound to it are still exporting, so the
47
+ * delete is refused with a 409 while any exist; either wait for those sessions to
48
+ * end or delete them first. It is refused the same way while a managed auth
49
+ * connection still selects it, because that connection re-resolves the destination
50
+ * on every login, and while a managed auth login using it is still in progress.
51
+ */
52
+ delete(idOrName, options) {
53
+ return this._client.delete(path `/telemetry/destinations/${idOrName}`, {
54
+ ...options,
55
+ headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
56
+ });
57
+ }
58
+ }
59
+ //# sourceMappingURL=destinations.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"destinations.mjs","sourceRoot":"","sources":["../../src/resources/telemetry/destinations.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAElD,OAAO,EAAE,gBAAgB,EAA4C,kCAA8B;AACnG,OAAO,EAAE,YAAY,EAAE,mCAA+B;AAEtD,OAAO,EAAE,IAAI,EAAE,sCAAkC;AAEjD;;GAEG;AACH,MAAM,OAAO,YAAa,SAAQ,WAAW;IAC3C;;;OAGG;IACH,MAAM,CAAC,IAA6B,EAAE,OAAwB;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,yBAAyB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5E,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,QAAgB,EAAE,OAAwB;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,2BAA2B,QAAQ,EAAE,EAAE,OAAO,CAAC,CAAC;IAC9E,CAAC;IAED;;;;;;;;;OASG;IACH,MAAM,CACJ,QAAgB,EAChB,IAA6B,EAC7B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAA,2BAA2B,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC7F,CAAC;IAED;;OAEG;IACH,IAAI,CACF,QAAkD,EAAE,EACpD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,yBAAyB,EAAE,CAAA,gBAAiC,CAAA,EAAE;YAC3F,KAAK;YACL,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;;;;;;OAMG;IACH,MAAM,CAAC,QAAgB,EAAE,OAAwB;QAC/C,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAA,2BAA2B,QAAQ,EAAE,EAAE;YACpE,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;CACF"}
@@ -0,0 +1,3 @@
1
+ export { Destinations, type OtlpDestination, type DestinationCreateParams, type DestinationUpdateParams, type DestinationListParams, type OtlpDestinationsOffsetPagination, } from "./destinations.mjs";
2
+ export { Telemetry } from "./telemetry.mjs";
3
+ //# sourceMappingURL=index.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/telemetry/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,YAAY,EACZ,KAAK,eAAe,EACpB,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,gCAAgC,GACtC,2BAAuB;AACxB,OAAO,EAAE,SAAS,EAAE,wBAAoB"}
@@ -0,0 +1,3 @@
1
+ export { Destinations, type OtlpDestination, type DestinationCreateParams, type DestinationUpdateParams, type DestinationListParams, type OtlpDestinationsOffsetPagination, } from "./destinations.js";
2
+ export { Telemetry } from "./telemetry.js";
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/telemetry/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,YAAY,EACZ,KAAK,eAAe,EACpB,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,gCAAgC,GACtC,0BAAuB;AACxB,OAAO,EAAE,SAAS,EAAE,uBAAoB"}
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Telemetry = exports.Destinations = void 0;
5
+ var destinations_1 = require("./destinations.js");
6
+ Object.defineProperty(exports, "Destinations", { enumerable: true, get: function () { return destinations_1.Destinations; } });
7
+ var telemetry_1 = require("./telemetry.js");
8
+ Object.defineProperty(exports, "Telemetry", { enumerable: true, get: function () { return telemetry_1.Telemetry; } });
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/telemetry/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAOwB;AANtB,4GAAA,YAAY,OAAA;AAOd,4CAAwC;AAA/B,sGAAA,SAAS,OAAA"}
@@ -0,0 +1,4 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ export { Destinations, } from "./destinations.mjs";
3
+ export { Telemetry } from "./telemetry.mjs";
4
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/telemetry/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EACL,YAAY,GAMb,2BAAuB;AACxB,OAAO,EAAE,SAAS,EAAE,wBAAoB"}
@@ -0,0 +1,10 @@
1
+ import { APIResource } from "../../core/resource.mjs";
2
+ import * as DestinationsAPI from "./destinations.mjs";
3
+ import { DestinationCreateParams, DestinationListParams, DestinationUpdateParams, Destinations, OtlpDestination, OtlpDestinationsOffsetPagination } from "./destinations.mjs";
4
+ export declare class Telemetry extends APIResource {
5
+ destinations: DestinationsAPI.Destinations;
6
+ }
7
+ export declare namespace Telemetry {
8
+ export { Destinations as Destinations, type OtlpDestination as OtlpDestination, type OtlpDestinationsOffsetPagination as OtlpDestinationsOffsetPagination, type DestinationCreateParams as DestinationCreateParams, type DestinationUpdateParams as DestinationUpdateParams, type DestinationListParams as DestinationListParams, };
9
+ }
10
+ //# sourceMappingURL=telemetry.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telemetry.d.mts","sourceRoot":"","sources":["../../src/resources/telemetry/telemetry.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,KAAK,eAAe,2BAAuB;AAClD,OAAO,EACL,uBAAuB,EACvB,qBAAqB,EACrB,uBAAuB,EACvB,YAAY,EACZ,eAAe,EACf,gCAAgC,EACjC,2BAAuB;AAExB,qBAAa,SAAU,SAAQ,WAAW;IACxC,YAAY,EAAE,eAAe,CAAC,YAAY,CAAkD;CAC7F;AAID,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,YAAY,IAAI,YAAY,EAC5B,KAAK,eAAe,IAAI,eAAe,EACvC,KAAK,gCAAgC,IAAI,gCAAgC,EACzE,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,qBAAqB,IAAI,qBAAqB,GACpD,CAAC;CACH"}
@@ -0,0 +1,10 @@
1
+ import { APIResource } from "../../core/resource.js";
2
+ import * as DestinationsAPI from "./destinations.js";
3
+ import { DestinationCreateParams, DestinationListParams, DestinationUpdateParams, Destinations, OtlpDestination, OtlpDestinationsOffsetPagination } from "./destinations.js";
4
+ export declare class Telemetry extends APIResource {
5
+ destinations: DestinationsAPI.Destinations;
6
+ }
7
+ export declare namespace Telemetry {
8
+ export { Destinations as Destinations, type OtlpDestination as OtlpDestination, type OtlpDestinationsOffsetPagination as OtlpDestinationsOffsetPagination, type DestinationCreateParams as DestinationCreateParams, type DestinationUpdateParams as DestinationUpdateParams, type DestinationListParams as DestinationListParams, };
9
+ }
10
+ //# sourceMappingURL=telemetry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telemetry.d.ts","sourceRoot":"","sources":["../../src/resources/telemetry/telemetry.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,+BAA4B;AAClD,OAAO,KAAK,eAAe,0BAAuB;AAClD,OAAO,EACL,uBAAuB,EACvB,qBAAqB,EACrB,uBAAuB,EACvB,YAAY,EACZ,eAAe,EACf,gCAAgC,EACjC,0BAAuB;AAExB,qBAAa,SAAU,SAAQ,WAAW;IACxC,YAAY,EAAE,eAAe,CAAC,YAAY,CAAkD;CAC7F;AAID,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,YAAY,IAAI,YAAY,EAC5B,KAAK,eAAe,IAAI,eAAe,EACvC,KAAK,gCAAgC,IAAI,gCAAgC,EACzE,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,qBAAqB,IAAI,qBAAqB,GACpD,CAAC;CACH"}
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Telemetry = void 0;
5
+ const tslib_1 = require("../../internal/tslib.js");
6
+ const resource_1 = require("../../core/resource.js");
7
+ const DestinationsAPI = tslib_1.__importStar(require("./destinations.js"));
8
+ const destinations_1 = require("./destinations.js");
9
+ class Telemetry extends resource_1.APIResource {
10
+ constructor() {
11
+ super(...arguments);
12
+ this.destinations = new DestinationsAPI.Destinations(this._client);
13
+ }
14
+ }
15
+ exports.Telemetry = Telemetry;
16
+ Telemetry.Destinations = destinations_1.Destinations;
17
+ //# sourceMappingURL=telemetry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telemetry.js","sourceRoot":"","sources":["../../src/resources/telemetry/telemetry.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,qDAAkD;AAClD,2EAAkD;AAClD,oDAOwB;AAExB,MAAa,SAAU,SAAQ,sBAAW;IAA1C;;QACE,iBAAY,GAAiC,IAAI,eAAe,CAAC,YAAY,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC9F,CAAC;CAAA;AAFD,8BAEC;AAED,SAAS,CAAC,YAAY,GAAG,2BAAY,CAAC"}
@@ -0,0 +1,12 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../../core/resource.mjs";
3
+ import * as DestinationsAPI from "./destinations.mjs";
4
+ import { Destinations, } from "./destinations.mjs";
5
+ export class Telemetry extends APIResource {
6
+ constructor() {
7
+ super(...arguments);
8
+ this.destinations = new DestinationsAPI.Destinations(this._client);
9
+ }
10
+ }
11
+ Telemetry.Destinations = Destinations;
12
+ //# sourceMappingURL=telemetry.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telemetry.mjs","sourceRoot":"","sources":["../../src/resources/telemetry/telemetry.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,KAAK,eAAe,2BAAuB;AAClD,OAAO,EAIL,YAAY,GAGb,2BAAuB;AAExB,MAAM,OAAO,SAAU,SAAQ,WAAW;IAA1C;;QACE,iBAAY,GAAiC,IAAI,eAAe,CAAC,YAAY,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC9F,CAAC;CAAA;AAED,SAAS,CAAC,YAAY,GAAG,YAAY,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./telemetry/index.mjs";
2
+ //# sourceMappingURL=telemetry.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telemetry.d.mts","sourceRoot":"","sources":["../src/resources/telemetry.ts"],"names":[],"mappings":"AAEA,sCAAkC"}
@@ -0,0 +1,2 @@
1
+ export * from "./telemetry/index.js";
2
+ //# sourceMappingURL=telemetry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telemetry.d.ts","sourceRoot":"","sources":["../src/resources/telemetry.ts"],"names":[],"mappings":"AAEA,qCAAkC"}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ const tslib_1 = require("../internal/tslib.js");
5
+ tslib_1.__exportStar(require("./telemetry/index.js"), exports);
6
+ //# sourceMappingURL=telemetry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telemetry.js","sourceRoot":"","sources":["../src/resources/telemetry.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,+DAAkC"}
@@ -0,0 +1,3 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ export * from "./telemetry/index.mjs";
3
+ //# sourceMappingURL=telemetry.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telemetry.mjs","sourceRoot":"","sources":["../src/resources/telemetry.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,sCAAkC"}
package/src/client.ts CHANGED
@@ -153,6 +153,8 @@ import {
153
153
  BrowserListResponse,
154
154
  BrowserListResponsesOffsetPagination,
155
155
  BrowserLoadExtensionsParams,
156
+ BrowserMemory,
157
+ BrowserMemoryRequest,
156
158
  BrowserNetworkConfig,
157
159
  BrowserPoolRef,
158
160
  BrowserProxy,
@@ -178,6 +180,7 @@ import {
178
180
  ProjectsOffsetPagination,
179
181
  UpdateProjectRequest,
180
182
  } from './resources/projects/projects';
183
+ import { Telemetry } from './resources/telemetry/telemetry';
181
184
  import { type Fetch } from './internal/builtin-types';
182
185
  import { HeadersLike, NullableHeaders, buildHeaders } from './internal/headers';
183
186
  import { FinalRequestOptions, RequestOptions } from './internal/request-options';
@@ -1018,6 +1021,7 @@ export class Kernel {
1018
1021
  */
1019
1022
  profiles: API.Profiles = new API.Profiles(this);
1020
1023
  auth: API.Auth = new API.Auth(this);
1024
+ telemetry: API.Telemetry = new API.Telemetry(this);
1021
1025
  /**
1022
1026
  * Create and manage proxy configurations for routing browser traffic.
1023
1027
  */
@@ -1062,6 +1066,7 @@ Kernel.Invocations = Invocations;
1062
1066
  Kernel.Browsers = Browsers;
1063
1067
  Kernel.Profiles = Profiles;
1064
1068
  Kernel.Auth = Auth;
1069
+ Kernel.Telemetry = Telemetry;
1065
1070
  Kernel.Proxies = Proxies;
1066
1071
  Kernel.Extensions = Extensions;
1067
1072
  Kernel.BrowserPools = BrowserPools;
@@ -1125,6 +1130,8 @@ export declare namespace Kernel {
1125
1130
 
1126
1131
  export {
1127
1132
  Browsers as Browsers,
1133
+ type BrowserMemory as BrowserMemory,
1134
+ type BrowserMemoryRequest as BrowserMemoryRequest,
1128
1135
  type BrowserNetworkConfig as BrowserNetworkConfig,
1129
1136
  type BrowserPoolRef as BrowserPoolRef,
1130
1137
  type BrowserProxy as BrowserProxy,
@@ -1157,6 +1164,8 @@ export declare namespace Kernel {
1157
1164
 
1158
1165
  export { Auth as Auth };
1159
1166
 
1167
+ export { Telemetry as Telemetry };
1168
+
1160
1169
  export {
1161
1170
  Proxies as Proxies,
1162
1171
  type ProxyCreateResponse as ProxyCreateResponse,
@@ -374,6 +374,11 @@ export interface BrowserPoolAcquireResponse {
374
374
  */
375
375
  headless: boolean;
376
376
 
377
+ /**
378
+ * Memory allocated to the browser session.
379
+ */
380
+ memory: BrowsersAPI.BrowserMemory;
381
+
377
382
  /**
378
383
  * Geographic region of the browser session. Fixed once the session is created.
379
384
  */
@@ -281,6 +281,16 @@ export type BrowserListResponsesOffsetPagination = OffsetPagination<BrowserListR
281
281
 
282
282
  export type ProfilesOffsetPagination = OffsetPagination<Profile>;
283
283
 
284
+ /**
285
+ * Memory allocated to the browser session.
286
+ */
287
+ export type BrowserMemory = '1GiB' | '2GiB' | '6GiB' | '8GiB' | '16GiB';
288
+
289
+ /**
290
+ * Memory requested for a headful, non-GPU browser session.
291
+ */
292
+ export type BrowserMemoryRequest = '8GiB' | '16GiB';
293
+
284
294
  /**
285
295
  * Network configuration for a browser session or browser pool.
286
296
  */
@@ -454,6 +464,11 @@ export interface BrowserCreateResponse {
454
464
  */
455
465
  headless: boolean;
456
466
 
467
+ /**
468
+ * Memory allocated to the browser session.
469
+ */
470
+ memory: BrowserMemory;
471
+
457
472
  /**
458
473
  * Geographic region of the browser session. Fixed once the session is created.
459
474
  */
@@ -609,6 +624,11 @@ export interface BrowserRetrieveResponse {
609
624
  */
610
625
  headless: boolean;
611
626
 
627
+ /**
628
+ * Memory allocated to the browser session.
629
+ */
630
+ memory: BrowserMemory;
631
+
612
632
  /**
613
633
  * Geographic region of the browser session. Fixed once the session is created.
614
634
  */
@@ -764,6 +784,11 @@ export interface BrowserUpdateResponse {
764
784
  */
765
785
  headless: boolean;
766
786
 
787
+ /**
788
+ * Memory allocated to the browser session.
789
+ */
790
+ memory: BrowserMemory;
791
+
767
792
  /**
768
793
  * Geographic region of the browser session. Fixed once the session is created.
769
794
  */
@@ -919,6 +944,11 @@ export interface BrowserListResponse {
919
944
  */
920
945
  headless: boolean;
921
946
 
947
+ /**
948
+ * Memory allocated to the browser session.
949
+ */
950
+ memory: BrowserMemory;
951
+
922
952
  /**
923
953
  * Geographic region of the browser session. Fixed once the session is created.
924
954
  */
@@ -1120,6 +1150,11 @@ export interface BrowserCreateParams {
1120
1150
  */
1121
1151
  kiosk_mode?: boolean;
1122
1152
 
1153
+ /**
1154
+ * Memory for a headful, non-GPU browser session. Defaults to 8GiB.
1155
+ */
1156
+ memory?: BrowserMemoryRequest;
1157
+
1123
1158
  /**
1124
1159
  * Optional human-readable name for the browser session, used to find it later in
1125
1160
  * the dashboard. Must be unique among active sessions within the project. Can be
@@ -1580,6 +1615,8 @@ Browsers.Playwright = Playwright;
1580
1615
 
1581
1616
  export declare namespace Browsers {
1582
1617
  export {
1618
+ type BrowserMemory as BrowserMemory,
1619
+ type BrowserMemoryRequest as BrowserMemoryRequest,
1583
1620
  type BrowserNetworkConfig as BrowserNetworkConfig,
1584
1621
  type BrowserPoolRef as BrowserPoolRef,
1585
1622
  type BrowserProxy as BrowserProxy,
@@ -2,6 +2,8 @@
2
2
 
3
3
  export {
4
4
  Browsers,
5
+ type BrowserMemory,
6
+ type BrowserMemoryRequest,
5
7
  type BrowserNetworkConfig,
6
8
  type BrowserPoolRef,
7
9
  type BrowserProxy,
@@ -10,7 +10,7 @@ import { RequestOptions } from '../../internal/request-options';
10
10
  import { path } from '../../internal/utils/path';
11
11
 
12
12
  /**
13
- * Stream live telemetry events from a browser session.
13
+ * Stream live telemetry events from a browser session, and manage the destinations sessions export them to.
14
14
  */
15
15
  export class Telemetry extends APIResource {
16
16
  /**
@@ -136,7 +136,8 @@ export interface CreateCredentialProviderRequest {
136
136
  token: string;
137
137
 
138
138
  /**
139
- * Human-readable name for this provider instance (unique per org)
139
+ * Human-readable name for this provider instance (unique per org). Surrounding
140
+ * whitespace is trimmed and the trimmed value must be non-empty.
140
141
  */
141
142
  name: string;
142
143
 
@@ -281,7 +282,8 @@ export interface UpdateCredentialProviderRequest {
281
282
  enabled?: boolean;
282
283
 
283
284
  /**
284
- * Human-readable name for this provider instance
285
+ * Human-readable name for this provider instance. Surrounding whitespace is
286
+ * trimmed and the trimmed value must be non-empty.
285
287
  */
286
288
  name?: string;
287
289
 
@@ -302,7 +304,8 @@ export interface CredentialProviderCreateParams {
302
304
  token: string;
303
305
 
304
306
  /**
305
- * Human-readable name for this provider instance (unique per org)
307
+ * Human-readable name for this provider instance (unique per org). Surrounding
308
+ * whitespace is trimmed and the trimmed value must be non-empty.
306
309
  */
307
310
  name: string;
308
311
 
@@ -334,7 +337,8 @@ export interface CredentialProviderUpdateParams {
334
337
  enabled?: boolean;
335
338
 
336
339
  /**
337
- * Human-readable name for this provider instance
340
+ * Human-readable name for this provider instance. Surrounding whitespace is
341
+ * trimmed and the trimmed value must be non-empty.
338
342
  */
339
343
  name?: string;
340
344
 
@@ -40,6 +40,8 @@ export {
40
40
  } from './browser-pools';
41
41
  export {
42
42
  Browsers,
43
+ type BrowserMemory,
44
+ type BrowserMemoryRequest,
43
45
  type BrowserNetworkConfig,
44
46
  type BrowserPoolRef,
45
47
  type BrowserProxy,
@@ -154,3 +156,4 @@ export {
154
156
  type ProxyCheckParams,
155
157
  type ProxyListResponsesOffsetPagination,
156
158
  } from './proxies';
159
+ export { Telemetry } from './telemetry/telemetry';
@@ -434,6 +434,11 @@ export namespace InvocationListBrowsersResponse {
434
434
  */
435
435
  headless: boolean;
436
436
 
437
+ /**
438
+ * Memory allocated to the browser session.
439
+ */
440
+ memory: BrowsersAPI.BrowserMemory;
441
+
437
442
  /**
438
443
  * Geographic region of the browser session. Fixed once the session is created.
439
444
  */
@@ -0,0 +1,188 @@
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 { OffsetPagination, type OffsetPaginationParams, PagePromise } from '../../core/pagination';
6
+ import { buildHeaders } from '../../internal/headers';
7
+ import { RequestOptions } from '../../internal/request-options';
8
+ import { path } from '../../internal/utils/path';
9
+
10
+ /**
11
+ * Stream live telemetry events from a browser session, and manage the destinations sessions export them to.
12
+ */
13
+ export class Destinations extends APIResource {
14
+ /**
15
+ * Create an OTLP export destination in the resolved project. Names must be unique
16
+ * within the project.
17
+ */
18
+ create(body: DestinationCreateParams, options?: RequestOptions): APIPromise<OtlpDestination> {
19
+ return this._client.post('/telemetry/destinations', { body, ...options });
20
+ }
21
+
22
+ /**
23
+ * Retrieve a single OTLP destination in the resolved project by its ID or name.
24
+ */
25
+ retrieve(idOrName: string, options?: RequestOptions): APIPromise<OtlpDestination> {
26
+ return this._client.get(path`/telemetry/destinations/${idOrName}`, options);
27
+ }
28
+
29
+ /**
30
+ * Update an OTLP destination. Sessions already exporting to it pick up the new
31
+ * values without restarting, which makes this the way to rotate credentials
32
+ * without interrupting export.
33
+ *
34
+ * Names must be unique within the project. Renaming is refused with a 409 while a
35
+ * managed auth connection selects this destination by name, since that connection
36
+ * resolves the name on every login. Every other field, including `headers`, stays
37
+ * editable.
38
+ */
39
+ update(
40
+ idOrName: string,
41
+ body: DestinationUpdateParams,
42
+ options?: RequestOptions,
43
+ ): APIPromise<OtlpDestination> {
44
+ return this._client.patch(path`/telemetry/destinations/${idOrName}`, { body, ...options });
45
+ }
46
+
47
+ /**
48
+ * List OTLP export destinations in the resolved project.
49
+ */
50
+ list(
51
+ query: DestinationListParams | null | undefined = {},
52
+ options?: RequestOptions,
53
+ ): PagePromise<OtlpDestinationsOffsetPagination, OtlpDestination> {
54
+ return this._client.getAPIList('/telemetry/destinations', OffsetPagination<OtlpDestination>, {
55
+ query,
56
+ ...options,
57
+ });
58
+ }
59
+
60
+ /**
61
+ * Delete an OTLP destination. Sessions bound to it are still exporting, so the
62
+ * delete is refused with a 409 while any exist; either wait for those sessions to
63
+ * end or delete them first. It is refused the same way while a managed auth
64
+ * connection still selects it, because that connection re-resolves the destination
65
+ * on every login, and while a managed auth login using it is still in progress.
66
+ */
67
+ delete(idOrName: string, options?: RequestOptions): APIPromise<void> {
68
+ return this._client.delete(path`/telemetry/destinations/${idOrName}`, {
69
+ ...options,
70
+ headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
71
+ });
72
+ }
73
+ }
74
+
75
+ export type OtlpDestinationsOffsetPagination = OffsetPagination<OtlpDestination>;
76
+
77
+ /**
78
+ * An OTLP endpoint to export browser session telemetry to. Reference one from
79
+ * `telemetry.export.otlp.destination` when creating a browser to export that
80
+ * session's captured telemetry to it.
81
+ */
82
+ export interface OtlpDestination {
83
+ id: string;
84
+
85
+ created_at: string;
86
+
87
+ /**
88
+ * OTLP/HTTP endpoint telemetry is sent to.
89
+ */
90
+ endpoint: string;
91
+
92
+ /**
93
+ * Headers sent with each export request. Names are returned in canonical form
94
+ * (`Authorization`, not `authorization`). Values are returned redacted as empty
95
+ * strings, so the keys are visible but the credentials are not.
96
+ */
97
+ headers: { [key: string]: string };
98
+
99
+ /**
100
+ * Unique within the project. Usable in place of the ID when selecting a
101
+ * destination, so it cannot be shaped like an ID.
102
+ */
103
+ name: string;
104
+
105
+ updated_at: string;
106
+
107
+ description?: string;
108
+ }
109
+
110
+ export interface DestinationCreateParams {
111
+ /**
112
+ * Base endpoint of the OTLP/HTTP collector, without a signal path. Kernel appends
113
+ * the signal path itself, so pass `https://api.honeycomb.io` rather than
114
+ * `https://api.honeycomb.io/v1/logs`. If your provider's docs give you a
115
+ * signal-specific URL, drop the trailing `/v1/logs`, `/v1/traces`, or
116
+ * `/v1/metrics` — an endpoint that already carries one is rejected.
117
+ *
118
+ * Must be http or https, must resolve to a public address, and must carry no query
119
+ * string or fragment. Examples: `https://api.honeycomb.io`,
120
+ * `https://otlp-gateway-prod-us-east-0.grafana.net/otlp`,
121
+ * `https://otlp.datadoghq.com` (Datadog's OTLP intake for US1, not its logs
122
+ * intake).
123
+ */
124
+ endpoint: string;
125
+
126
+ /**
127
+ * Unique within the project.
128
+ */
129
+ name: string;
130
+
131
+ description?: string;
132
+
133
+ /**
134
+ * Headers sent with each export request, typically an ingestion key. Encrypted at
135
+ * rest and returned redacted. Names and values must be valid HTTP header tokens,
136
+ * and the names and values together cannot exceed 8192 bytes. Names are matched
137
+ * case-insensitively and stored canonicalized, so supplying two spellings of one
138
+ * header is rejected.
139
+ */
140
+ headers?: { [key: string]: string };
141
+ }
142
+
143
+ export interface DestinationUpdateParams {
144
+ description?: string;
145
+
146
+ /**
147
+ * Base endpoint of the OTLP/HTTP collector, without a signal path. Same rules as
148
+ * on create.
149
+ */
150
+ endpoint?: string;
151
+
152
+ /**
153
+ * Edits stored headers key by key rather than replacing the map. A string value
154
+ * adds or replaces that header, `null` deletes it, and any key you omit is left as
155
+ * it is. Names are matched case-insensitively, so `authorization` replaces a
156
+ * stored `Authorization` rather than adding a second entry. This is the credential
157
+ * rotation path; sessions already exporting pick up the new values without
158
+ * restarting. Names and values must be valid HTTP header tokens, and the names and
159
+ * values together cannot exceed 8192 bytes.
160
+ */
161
+ headers?: { [key: string]: string | null };
162
+
163
+ name?: string;
164
+ }
165
+
166
+ export interface DestinationListParams extends OffsetPaginationParams {
167
+ /**
168
+ * Exact-match filter on destination name using the database collation. In
169
+ * production, matching is case- and accent-insensitive.
170
+ */
171
+ name?: string;
172
+
173
+ /**
174
+ * Case-insensitive substring match against destination name or endpoint. IDs match
175
+ * by exact value.
176
+ */
177
+ query?: string;
178
+ }
179
+
180
+ export declare namespace Destinations {
181
+ export {
182
+ type OtlpDestination as OtlpDestination,
183
+ type OtlpDestinationsOffsetPagination as OtlpDestinationsOffsetPagination,
184
+ type DestinationCreateParams as DestinationCreateParams,
185
+ type DestinationUpdateParams as DestinationUpdateParams,
186
+ type DestinationListParams as DestinationListParams,
187
+ };
188
+ }
@@ -0,0 +1,11 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ export {
4
+ Destinations,
5
+ type OtlpDestination,
6
+ type DestinationCreateParams,
7
+ type DestinationUpdateParams,
8
+ type DestinationListParams,
9
+ type OtlpDestinationsOffsetPagination,
10
+ } from './destinations';
11
+ export { Telemetry } from './telemetry';