@nirvana-labs/nirvana 1.4.1 → 1.4.2

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.4.2 (2025-06-04)
4
+
5
+ Full Changelog: [v1.4.1...v1.4.2](https://github.com/nirvana-labs/nirvana-typescript/compare/v1.4.1...v1.4.2)
6
+
7
+ ### Chores
8
+
9
+ * **docs:** use top-level-await in example snippets ([2737ebc](https://github.com/nirvana-labs/nirvana-typescript/commit/2737ebc21d10b1730cbdb1fa916cbd2155a504b9))
10
+ * **internal:** fix readablestream types in node 20 ([bf215df](https://github.com/nirvana-labs/nirvana-typescript/commit/bf215df5c71769f4f29cf5b3e2857235b626f090))
11
+
3
12
  ## 1.4.1 (2025-06-03)
4
13
 
5
14
  Full Changelog: [v1.4.0...v1.4.1](https://github.com/nirvana-labs/nirvana-typescript/compare/v1.4.0...v1.4.1)
package/README.md CHANGED
@@ -24,25 +24,19 @@ const client = new NirvanaLabs({
24
24
  apiKey: process.env['NIRVANA_LABS_API_KEY'], // This is the default and can be omitted
25
25
  });
26
26
 
27
- async function main() {
28
- const operation = await client.compute.vms.create({
29
- boot_volume: { size: 100 },
30
- cpu_config: { vcpu: 2 },
31
- memory_config: { size: 2 },
32
- name: 'my-vm',
33
- os_image_name: 'ubuntu-noble-2025-04-03',
34
- public_ip_enabled: true,
35
- region: 'us-wdc-1',
36
- ssh_key: {
37
- public_key: 'ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDBIASkmwNiLcdlW6927Zjt1Hf7Kw/PpEZ4Zm+wU9wn2',
38
- },
39
- subnet_id: '123e4567-e89b-12d3-a456-426614174000',
40
- });
41
-
42
- console.log(operation.id);
43
- }
27
+ const operation = await client.compute.vms.create({
28
+ boot_volume: { size: 100 },
29
+ cpu_config: { vcpu: 2 },
30
+ memory_config: { size: 2 },
31
+ name: 'my-vm',
32
+ os_image_name: 'ubuntu-noble-2025-04-03',
33
+ public_ip_enabled: true,
34
+ region: 'us-wdc-1',
35
+ ssh_key: { public_key: 'ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDBIASkmwNiLcdlW6927Zjt1Hf7Kw/PpEZ4Zm+wU9wn2' },
36
+ subnet_id: '123e4567-e89b-12d3-a456-426614174000',
37
+ });
44
38
 
45
- main();
39
+ console.log(operation.id);
46
40
  ```
47
41
 
48
42
  ### Request & Response types
@@ -57,24 +51,18 @@ const client = new NirvanaLabs({
57
51
  apiKey: process.env['NIRVANA_LABS_API_KEY'], // This is the default and can be omitted
58
52
  });
59
53
 
60
- async function main() {
61
- const params: NirvanaLabs.Compute.VMCreateParams = {
62
- boot_volume: { size: 100 },
63
- cpu_config: { vcpu: 2 },
64
- memory_config: { size: 2 },
65
- name: 'my-vm',
66
- os_image_name: 'ubuntu-noble-2025-04-03',
67
- public_ip_enabled: true,
68
- region: 'us-wdc-1',
69
- ssh_key: {
70
- public_key: 'ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDBIASkmwNiLcdlW6927Zjt1Hf7Kw/PpEZ4Zm+wU9wn2',
71
- },
72
- subnet_id: '123e4567-e89b-12d3-a456-426614174000',
73
- };
74
- const operation: NirvanaLabs.Operation = await client.compute.vms.create(params);
75
- }
76
-
77
- main();
54
+ const params: NirvanaLabs.Compute.VMCreateParams = {
55
+ boot_volume: { size: 100 },
56
+ cpu_config: { vcpu: 2 },
57
+ memory_config: { size: 2 },
58
+ name: 'my-vm',
59
+ os_image_name: 'ubuntu-noble-2025-04-03',
60
+ public_ip_enabled: true,
61
+ region: 'us-wdc-1',
62
+ ssh_key: { public_key: 'ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDBIASkmwNiLcdlW6927Zjt1Hf7Kw/PpEZ4Zm+wU9wn2' },
63
+ subnet_id: '123e4567-e89b-12d3-a456-426614174000',
64
+ };
65
+ const operation: NirvanaLabs.Operation = await client.compute.vms.create(params);
78
66
  ```
79
67
 
80
68
  Documentation for each method, request param, and response field are available in docstrings and will appear on hover in most modern editors.
@@ -87,33 +75,29 @@ a subclass of `APIError` will be thrown:
87
75
 
88
76
  <!-- prettier-ignore -->
89
77
  ```ts
90
- async function main() {
91
- const operation = await client.compute.vms
92
- .create({
93
- boot_volume: { size: 100 },
94
- cpu_config: { vcpu: 2 },
95
- memory_config: { size: 2 },
96
- name: 'my-vm',
97
- os_image_name: 'ubuntu-noble-2025-04-03',
98
- public_ip_enabled: true,
99
- region: 'us-wdc-1',
100
- ssh_key: {
101
- public_key: 'ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDBIASkmwNiLcdlW6927Zjt1Hf7Kw/PpEZ4Zm+wU9wn2',
102
- },
103
- subnet_id: '123e4567-e89b-12d3-a456-426614174000',
104
- })
105
- .catch(async (err) => {
106
- if (err instanceof NirvanaLabs.APIError) {
107
- console.log(err.status); // 400
108
- console.log(err.name); // BadRequestError
109
- console.log(err.headers); // {server: 'nginx', ...}
110
- } else {
111
- throw err;
112
- }
113
- });
114
- }
115
-
116
- main();
78
+ const operation = await client.compute.vms
79
+ .create({
80
+ boot_volume: { size: 100 },
81
+ cpu_config: { vcpu: 2 },
82
+ memory_config: { size: 2 },
83
+ name: 'my-vm',
84
+ os_image_name: 'ubuntu-noble-2025-04-03',
85
+ public_ip_enabled: true,
86
+ region: 'us-wdc-1',
87
+ ssh_key: {
88
+ public_key: 'ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDBIASkmwNiLcdlW6927Zjt1Hf7Kw/PpEZ4Zm+wU9wn2',
89
+ },
90
+ subnet_id: '123e4567-e89b-12d3-a456-426614174000',
91
+ })
92
+ .catch(async (err) => {
93
+ if (err instanceof NirvanaLabs.APIError) {
94
+ console.log(err.status); // 400
95
+ console.log(err.name); // BadRequestError
96
+ console.log(err.headers); // {server: 'nginx', ...}
97
+ } else {
98
+ throw err;
99
+ }
100
+ });
117
101
  ```
118
102
 
119
103
  Error codes are as follows:
@@ -1,28 +1,17 @@
1
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
1
  /**
4
2
  * Shims for types that we can't always rely on being available globally.
5
3
  *
6
4
  * Note: these only exist at the type-level, there is no corresponding runtime
7
5
  * version for any of these symbols.
8
6
  */
9
-
10
- /**
11
- * In order to properly access the global `NodeJS` type, if it's available, we
12
- * need to make use of declaration shadowing. Without this, any checks for the
13
- * presence of `NodeJS.ReadableStream` will fail.
14
- */
15
- declare namespace NodeJS {
16
- interface ReadableStream {}
17
- }
18
-
19
- type HasProperties<T> = keyof T extends never ? false : true;
20
-
21
- // @ts-ignore
22
- type _ReadableStream<R = any> =
23
- // @ts-ignore
24
- HasProperties<NodeJS.ReadableStream> extends true ? NodeJS.ReadableStream<R> : ReadableStream<R>;
25
-
26
- // @ts-ignore
27
- declare const _ReadableStream: unknown extends typeof ReadableStream ? never : typeof ReadableStream;
28
- export { _ReadableStream as ReadableStream };
7
+ type NeverToAny<T> = T extends never ? any : T;
8
+ /** @ts-ignore */
9
+ type _DOMReadableStream<R = any> = globalThis.ReadableStream<R>;
10
+ /** @ts-ignore */
11
+ type _NodeReadableStream<R = any> = import('stream/web').ReadableStream<R>;
12
+ type _ConditionalNodeReadableStream<R = any> = typeof globalThis extends {
13
+ ReadableStream: any;
14
+ } ? never : _NodeReadableStream<R>;
15
+ type _ReadableStream<R = any> = NeverToAny<([0] extends [1 & _DOMReadableStream<R>] ? never : _DOMReadableStream<R>) | ([0] extends [1 & _ConditionalNodeReadableStream<R>] ? never : _ConditionalNodeReadableStream<R>)>;
16
+ export type { _ReadableStream as ReadableStream };
17
+ //# sourceMappingURL=shim-types.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shim-types.d.mts","sourceRoot":"","sources":["../src/internal/shim-types.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AAEH,KAAK,UAAU,CAAC,CAAC,IAAI,CAAC,SAAS,KAAK,GAAG,GAAG,GAAG,CAAC,CAAC;AAE/C,iBAAiB;AACjB,KAAK,kBAAkB,CAAC,CAAC,GAAG,GAAG,IAAI,UAAU,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;AAEhE,iBAAiB;AACjB,KAAK,mBAAmB,CAAC,CAAC,GAAG,GAAG,IAAI,OAAO,YAAY,EAAE,cAAc,CAAC,CAAC,CAAC,CAAC;AAE3E,KAAK,8BAA8B,CAAC,CAAC,GAAG,GAAG,IACzC,OAAO,UAAU,SAAS;IAAE,cAAc,EAAE,GAAG,CAAA;CAAE,GAAG,KAAK,GAAG,mBAAmB,CAAC,CAAC,CAAC,CAAC;AAErF,KAAK,eAAe,CAAC,CAAC,GAAG,GAAG,IAAI,UAAU,CACtC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,GAAG,kBAAkB,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,GAAG,kBAAkB,CAAC,CAAC,CAAC,CAAC,GACzE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,GAAG,8BAA8B,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,GAAG,8BAA8B,CAAC,CAAC,CAAC,CAAC,CACpG,CAAC;AAEF,YAAY,EAAE,eAAe,IAAI,cAAc,EAAE,CAAC"}
@@ -1,28 +1,17 @@
1
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
1
  /**
4
2
  * Shims for types that we can't always rely on being available globally.
5
3
  *
6
4
  * Note: these only exist at the type-level, there is no corresponding runtime
7
5
  * version for any of these symbols.
8
6
  */
9
-
10
- /**
11
- * In order to properly access the global `NodeJS` type, if it's available, we
12
- * need to make use of declaration shadowing. Without this, any checks for the
13
- * presence of `NodeJS.ReadableStream` will fail.
14
- */
15
- declare namespace NodeJS {
16
- interface ReadableStream {}
17
- }
18
-
19
- type HasProperties<T> = keyof T extends never ? false : true;
20
-
21
- // @ts-ignore
22
- type _ReadableStream<R = any> =
23
- // @ts-ignore
24
- HasProperties<NodeJS.ReadableStream> extends true ? NodeJS.ReadableStream<R> : ReadableStream<R>;
25
-
26
- // @ts-ignore
27
- declare const _ReadableStream: unknown extends typeof ReadableStream ? never : typeof ReadableStream;
28
- export { _ReadableStream as ReadableStream };
7
+ type NeverToAny<T> = T extends never ? any : T;
8
+ /** @ts-ignore */
9
+ type _DOMReadableStream<R = any> = globalThis.ReadableStream<R>;
10
+ /** @ts-ignore */
11
+ type _NodeReadableStream<R = any> = import('stream/web').ReadableStream<R>;
12
+ type _ConditionalNodeReadableStream<R = any> = typeof globalThis extends {
13
+ ReadableStream: any;
14
+ } ? never : _NodeReadableStream<R>;
15
+ type _ReadableStream<R = any> = NeverToAny<([0] extends [1 & _DOMReadableStream<R>] ? never : _DOMReadableStream<R>) | ([0] extends [1 & _ConditionalNodeReadableStream<R>] ? never : _ConditionalNodeReadableStream<R>)>;
16
+ export type { _ReadableStream as ReadableStream };
17
+ //# sourceMappingURL=shim-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shim-types.d.ts","sourceRoot":"","sources":["../src/internal/shim-types.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AAEH,KAAK,UAAU,CAAC,CAAC,IAAI,CAAC,SAAS,KAAK,GAAG,GAAG,GAAG,CAAC,CAAC;AAE/C,iBAAiB;AACjB,KAAK,kBAAkB,CAAC,CAAC,GAAG,GAAG,IAAI,UAAU,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;AAEhE,iBAAiB;AACjB,KAAK,mBAAmB,CAAC,CAAC,GAAG,GAAG,IAAI,OAAO,YAAY,EAAE,cAAc,CAAC,CAAC,CAAC,CAAC;AAE3E,KAAK,8BAA8B,CAAC,CAAC,GAAG,GAAG,IACzC,OAAO,UAAU,SAAS;IAAE,cAAc,EAAE,GAAG,CAAA;CAAE,GAAG,KAAK,GAAG,mBAAmB,CAAC,CAAC,CAAC,CAAC;AAErF,KAAK,eAAe,CAAC,CAAC,GAAG,GAAG,IAAI,UAAU,CACtC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,GAAG,kBAAkB,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,GAAG,kBAAkB,CAAC,CAAC,CAAC,CAAC,GACzE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,GAAG,8BAA8B,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,GAAG,8BAA8B,CAAC,CAAC,CAAC,CAAC,CACpG,CAAC;AAEF,YAAY,EAAE,eAAe,IAAI,cAAc,EAAE,CAAC"}
@@ -0,0 +1,4 @@
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
+ //# sourceMappingURL=shim-types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shim-types.js","sourceRoot":"","sources":["../src/internal/shim-types.ts"],"names":[],"mappings":";AAAA,sFAAsF"}
@@ -0,0 +1,3 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ export {};
3
+ //# sourceMappingURL=shim-types.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shim-types.mjs","sourceRoot":"","sources":["../src/internal/shim-types.ts"],"names":[],"mappings":"AAAA,sFAAsF"}
@@ -1,5 +1,5 @@
1
- import { type Fetch } from "./builtin-types.mjs";
2
- import { type ReadableStream } from "./shim-types.mjs";
1
+ import type { Fetch } from "./builtin-types.mjs";
2
+ import type { ReadableStream } from "./shim-types.mjs";
3
3
  export declare function getDefaultFetch(): Fetch;
4
4
  type ReadableStreamArgs = ConstructorParameters<typeof ReadableStream>;
5
5
  export declare function makeReadableStream(...args: ReadableStreamArgs): ReadableStream;
@@ -1 +1 @@
1
- {"version":3,"file":"shims.d.mts","sourceRoot":"","sources":["../src/internal/shims.ts"],"names":[],"mappings":"OASO,EAAE,KAAK,KAAK,EAAE;OACd,EAAE,KAAK,cAAc,EAAE;AAE9B,wBAAgB,eAAe,IAAI,KAAK,CAQvC;AAED,KAAK,kBAAkB,GAAG,qBAAqB,CAAC,OAAO,cAAc,CAAC,CAAC;AAEvE,wBAAgB,kBAAkB,CAAC,GAAG,IAAI,EAAE,kBAAkB,GAAG,cAAc,CAW9E;AAED,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CAAC,GAAG,aAAa,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAkBjG;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,CAAC,CAAC,EAAE,MAAM,EAAE,GAAG,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAyBtF;AAED;;;GAGG;AACH,wBAAsB,oBAAoB,CAAC,MAAM,EAAE,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC,CAYrE"}
1
+ {"version":3,"file":"shims.d.mts","sourceRoot":"","sources":["../src/internal/shims.ts"],"names":[],"mappings":"OASO,KAAK,EAAE,KAAK,EAAE;OACd,KAAK,EAAE,cAAc,EAAE;AAE9B,wBAAgB,eAAe,IAAI,KAAK,CAQvC;AAED,KAAK,kBAAkB,GAAG,qBAAqB,CAAC,OAAO,cAAc,CAAC,CAAC;AAEvE,wBAAgB,kBAAkB,CAAC,GAAG,IAAI,EAAE,kBAAkB,GAAG,cAAc,CAW9E;AAED,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CAAC,GAAG,aAAa,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAkBjG;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,CAAC,CAAC,EAAE,MAAM,EAAE,GAAG,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAyBtF;AAED;;;GAGG;AACH,wBAAsB,oBAAoB,CAAC,MAAM,EAAE,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC,CAYrE"}
@@ -1,5 +1,5 @@
1
- import { type Fetch } from "./builtin-types.js";
2
- import { type ReadableStream } from "./shim-types.js";
1
+ import type { Fetch } from "./builtin-types.js";
2
+ import type { ReadableStream } from "./shim-types.js";
3
3
  export declare function getDefaultFetch(): Fetch;
4
4
  type ReadableStreamArgs = ConstructorParameters<typeof ReadableStream>;
5
5
  export declare function makeReadableStream(...args: ReadableStreamArgs): ReadableStream;
@@ -1 +1 @@
1
- {"version":3,"file":"shims.d.ts","sourceRoot":"","sources":["../src/internal/shims.ts"],"names":[],"mappings":"OASO,EAAE,KAAK,KAAK,EAAE;OACd,EAAE,KAAK,cAAc,EAAE;AAE9B,wBAAgB,eAAe,IAAI,KAAK,CAQvC;AAED,KAAK,kBAAkB,GAAG,qBAAqB,CAAC,OAAO,cAAc,CAAC,CAAC;AAEvE,wBAAgB,kBAAkB,CAAC,GAAG,IAAI,EAAE,kBAAkB,GAAG,cAAc,CAW9E;AAED,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CAAC,GAAG,aAAa,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAkBjG;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,CAAC,CAAC,EAAE,MAAM,EAAE,GAAG,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAyBtF;AAED;;;GAGG;AACH,wBAAsB,oBAAoB,CAAC,MAAM,EAAE,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC,CAYrE"}
1
+ {"version":3,"file":"shims.d.ts","sourceRoot":"","sources":["../src/internal/shims.ts"],"names":[],"mappings":"OASO,KAAK,EAAE,KAAK,EAAE;OACd,KAAK,EAAE,cAAc,EAAE;AAE9B,wBAAgB,eAAe,IAAI,KAAK,CAQvC;AAED,KAAK,kBAAkB,GAAG,qBAAqB,CAAC,OAAO,cAAc,CAAC,CAAC;AAEvE,wBAAgB,kBAAkB,CAAC,GAAG,IAAI,EAAE,kBAAkB,GAAG,cAAc,CAW9E;AAED,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CAAC,GAAG,aAAa,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAkBjG;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,CAAC,CAAC,EAAE,MAAM,EAAE,GAAG,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAyBtF;AAED;;;GAGG;AACH,wBAAsB,oBAAoB,CAAC,MAAM,EAAE,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC,CAYrE"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nirvana-labs/nirvana",
3
- "version": "1.4.1",
3
+ "version": "1.4.2",
4
4
  "description": "The official TypeScript library for the Nirvana Labs API",
5
5
  "author": "Nirvana Labs <engineering@nirvanalabs.io>",
6
6
  "types": "./index.d.ts",
@@ -0,0 +1,26 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ /**
4
+ * Shims for types that we can't always rely on being available globally.
5
+ *
6
+ * Note: these only exist at the type-level, there is no corresponding runtime
7
+ * version for any of these symbols.
8
+ */
9
+
10
+ type NeverToAny<T> = T extends never ? any : T;
11
+
12
+ /** @ts-ignore */
13
+ type _DOMReadableStream<R = any> = globalThis.ReadableStream<R>;
14
+
15
+ /** @ts-ignore */
16
+ type _NodeReadableStream<R = any> = import('stream/web').ReadableStream<R>;
17
+
18
+ type _ConditionalNodeReadableStream<R = any> =
19
+ typeof globalThis extends { ReadableStream: any } ? never : _NodeReadableStream<R>;
20
+
21
+ type _ReadableStream<R = any> = NeverToAny<
22
+ | ([0] extends [1 & _DOMReadableStream<R>] ? never : _DOMReadableStream<R>)
23
+ | ([0] extends [1 & _ConditionalNodeReadableStream<R>] ? never : _ConditionalNodeReadableStream<R>)
24
+ >;
25
+
26
+ export type { _ReadableStream as ReadableStream };
@@ -7,8 +7,8 @@
7
7
  * messages in cases where an environment isn't fully supported.
8
8
  */
9
9
 
10
- import { type Fetch } from './builtin-types';
11
- import { type ReadableStream } from './shim-types';
10
+ import type { Fetch } from './builtin-types';
11
+ import type { ReadableStream } from './shim-types';
12
12
 
13
13
  export function getDefaultFetch(): Fetch {
14
14
  if (typeof fetch !== 'undefined') {
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '1.4.1'; // x-release-please-version
1
+ export const VERSION = '1.4.2'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "1.4.1";
1
+ export declare const VERSION = "1.4.2";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "1.4.1";
1
+ export declare const VERSION = "1.4.2";
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 = '1.4.1'; // x-release-please-version
4
+ exports.VERSION = '1.4.2'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '1.4.1'; // x-release-please-version
1
+ export const VERSION = '1.4.2'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map
@@ -1,28 +0,0 @@
1
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- /**
4
- * Shims for types that we can't always rely on being available globally.
5
- *
6
- * Note: these only exist at the type-level, there is no corresponding runtime
7
- * version for any of these symbols.
8
- */
9
-
10
- /**
11
- * In order to properly access the global `NodeJS` type, if it's available, we
12
- * need to make use of declaration shadowing. Without this, any checks for the
13
- * presence of `NodeJS.ReadableStream` will fail.
14
- */
15
- declare namespace NodeJS {
16
- interface ReadableStream {}
17
- }
18
-
19
- type HasProperties<T> = keyof T extends never ? false : true;
20
-
21
- // @ts-ignore
22
- type _ReadableStream<R = any> =
23
- // @ts-ignore
24
- HasProperties<NodeJS.ReadableStream> extends true ? NodeJS.ReadableStream<R> : ReadableStream<R>;
25
-
26
- // @ts-ignore
27
- declare const _ReadableStream: unknown extends typeof ReadableStream ? never : typeof ReadableStream;
28
- export { _ReadableStream as ReadableStream };