@openclaw/slack 2026.10.5-beta.1 → 2026.10.5-beta.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.
Files changed (108) hide show
  1. package/node_modules/@slack/bolt/node_modules/@slack/socket-mode/dist/package.json +4 -4
  2. package/node_modules/@slack/bolt/node_modules/@slack/socket-mode/dist/src/SlackWebSocket.d.ts.map +1 -1
  3. package/node_modules/@slack/bolt/node_modules/@slack/socket-mode/dist/src/SlackWebSocket.js +9 -17
  4. package/node_modules/@slack/bolt/node_modules/@slack/socket-mode/dist/src/SlackWebSocket.js.map +1 -1
  5. package/node_modules/@slack/bolt/node_modules/@slack/socket-mode/package.json +4 -4
  6. package/node_modules/@slack/bolt/node_modules/@types/node/README.md +2 -2
  7. package/node_modules/@slack/bolt/node_modules/@types/node/crypto.d.ts +2 -2
  8. package/node_modules/@slack/bolt/node_modules/@types/node/dgram.d.ts +1 -1
  9. package/node_modules/@slack/bolt/node_modules/@types/node/package.json +2 -17
  10. package/node_modules/@slack/bolt/node_modules/@types/node/zlib.d.ts +6 -0
  11. package/node_modules/@slack/web-api/node_modules/@types/node/README.md +1 -1
  12. package/node_modules/@slack/web-api/node_modules/@types/node/crypto.d.ts +2 -2
  13. package/node_modules/@slack/web-api/node_modules/@types/node/dgram.d.ts +1 -1
  14. package/node_modules/@slack/web-api/node_modules/@types/node/package.json +2 -2
  15. package/node_modules/@slack/web-api/node_modules/@types/node/zlib.d.ts +6 -0
  16. package/package.json +4 -4
  17. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/LICENSE +0 -21
  18. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/README.md +0 -15
  19. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/assert/strict.d.ts +0 -68
  20. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/assert.d.ts +0 -1077
  21. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/async_hooks.d.ts +0 -711
  22. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/buffer.buffer.d.ts +0 -471
  23. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/buffer.d.ts +0 -1800
  24. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/child_process.d.ts +0 -1361
  25. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/cluster.d.ts +0 -432
  26. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/console.d.ts +0 -93
  27. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/constants.d.ts +0 -14
  28. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/crypto.d.ts +0 -3964
  29. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/dgram.d.ts +0 -652
  30. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/diagnostics_channel.d.ts +0 -794
  31. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/dns/promises.d.ts +0 -497
  32. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/dns.d.ts +0 -876
  33. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/domain.d.ts +0 -150
  34. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/events.d.ts +0 -1008
  35. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/ffi.d.ts +0 -500
  36. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/fs/promises.d.ts +0 -1477
  37. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/fs.d.ts +0 -4803
  38. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/globals.d.ts +0 -150
  39. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/globals.typedarray.d.ts +0 -101
  40. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/http.d.ts +0 -2218
  41. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/http2.d.ts +0 -2498
  42. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/https.d.ts +0 -400
  43. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/index.d.ts +0 -116
  44. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/inspector/promises.d.ts +0 -35
  45. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/inspector.d.ts +0 -265
  46. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/inspector.generated.d.ts +0 -4406
  47. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/module.d.ts +0 -726
  48. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/net.d.ts +0 -1074
  49. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/os.d.ts +0 -498
  50. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/package.json +0 -155
  51. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/path/posix.d.ts +0 -8
  52. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/path/win32.d.ts +0 -8
  53. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/path.d.ts +0 -178
  54. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/perf_hooks.d.ts +0 -617
  55. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/process.d.ts +0 -2269
  56. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/punycode.d.ts +0 -89
  57. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/querystring.d.ts +0 -139
  58. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/quic.d.ts +0 -2191
  59. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/readline/promises.d.ts +0 -158
  60. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/readline.d.ts +0 -508
  61. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/repl.d.ts +0 -420
  62. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/sea.d.ts +0 -47
  63. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/sqlite.d.ts +0 -1140
  64. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/stream/consumers.d.ts +0 -114
  65. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/stream/iter.d.ts +0 -449
  66. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/stream/promises.d.ts +0 -211
  67. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/stream/web.d.ts +0 -320
  68. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/stream.d.ts +0 -1806
  69. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/string_decoder.d.ts +0 -27
  70. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/test/reporters.d.ts +0 -60
  71. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/test.d.ts +0 -2558
  72. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/timers/promises.d.ts +0 -93
  73. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/timers.d.ts +0 -149
  74. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/tls.d.ts +0 -1232
  75. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/trace_events.d.ts +0 -103
  76. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/ts5.6/buffer.buffer.d.ts +0 -467
  77. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/ts5.6/compatibility/float16array.d.ts +0 -71
  78. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/ts5.6/globals.typedarray.d.ts +0 -36
  79. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/ts5.6/index.d.ts +0 -118
  80. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/ts5.7/compatibility/float16array.d.ts +0 -72
  81. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/ts5.7/index.d.ts +0 -118
  82. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/tty.d.ts +0 -226
  83. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/url.d.ts +0 -556
  84. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/util/types.d.ts +0 -558
  85. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/util.d.ts +0 -1677
  86. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/v8.d.ts +0 -1059
  87. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/vfs.d.ts +0 -211
  88. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/vm.d.ts +0 -1137
  89. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/wasi.d.ts +0 -131
  90. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/abortcontroller.d.ts +0 -59
  91. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/blob.d.ts +0 -23
  92. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/console.d.ts +0 -9
  93. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/crypto.d.ts +0 -39
  94. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/domexception.d.ts +0 -83
  95. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/encoding.d.ts +0 -11
  96. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/events.d.ts +0 -106
  97. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/fetch.d.ts +0 -69
  98. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/importmeta.d.ts +0 -13
  99. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/messaging.d.ts +0 -23
  100. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/navigator.d.ts +0 -25
  101. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/performance.d.ts +0 -45
  102. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/storage.d.ts +0 -24
  103. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/streams.d.ts +0 -119
  104. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/timers.d.ts +0 -44
  105. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/web-globals/url.d.ts +0 -24
  106. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/worker_threads.d.ts +0 -672
  107. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/zlib/iter.d.ts +0 -131
  108. package/node_modules/@slack/web-api/node_modules/@slack/logger/node_modules/@types/node/zlib.d.ts +0 -606
@@ -1,211 +0,0 @@
1
- declare module "node:stream/promises" {
2
- import { Abortable } from "node:events";
3
- import {
4
- FinishedOptions as _FinishedOptions,
5
- PipelineDestination,
6
- PipelineSource,
7
- PipelineTransform,
8
- } from "node:stream";
9
- import { ReadableStream, WritableStream } from "node:stream/web";
10
- interface FinishedOptions extends _FinishedOptions {
11
- /**
12
- * If true, removes the listeners registered by this function before the promise is fulfilled.
13
- * @default false
14
- */
15
- cleanup?: boolean | undefined;
16
- }
17
- /**
18
- * ```js
19
- * import { finished } from 'node:stream/promises';
20
- * import { createReadStream } from 'node:fs';
21
- *
22
- * const rs = createReadStream('archive.tar');
23
- *
24
- * async function run() {
25
- * await finished(rs);
26
- * console.log('Stream is done reading.');
27
- * }
28
- *
29
- * run().catch(console.error);
30
- * rs.resume(); // Drain the stream.
31
- * ```
32
- *
33
- * The `finished` API also provides a [callback version](https://nodejs.org/docs/latest-v26.x/api/stream.html#streamfinishedstream-options-callback).
34
- *
35
- * `stream.finished()` leaves dangling event listeners (in particular
36
- * `'error'`, `'end'`, `'finish'` and `'close'`) after the returned promise is
37
- * resolved or rejected. The reason for this is so that unexpected `'error'`
38
- * events (due to incorrect stream implementations) do not cause unexpected
39
- * crashes. If this is unwanted behavior then `options.cleanup` should be set to
40
- * `true`:
41
- *
42
- * ```js
43
- * await finished(rs, { cleanup: true });
44
- * ```
45
- * @since v15.0.0
46
- * @returns Fulfills when the stream is no longer readable or writable.
47
- */
48
- function finished(
49
- stream: NodeJS.ReadableStream | NodeJS.WritableStream | ReadableStream | WritableStream,
50
- options?: FinishedOptions,
51
- ): Promise<void>;
52
- interface PipelineOptions extends Abortable {
53
- end?: boolean | undefined;
54
- }
55
- type PipelineResult<S extends PipelineDestination<any, any>> = S extends (...args: any[]) => PromiseLike<infer R>
56
- ? Promise<R>
57
- : Promise<void>;
58
- /**
59
- * ```js
60
- * import { pipeline } from 'node:stream/promises';
61
- * import { createReadStream, createWriteStream } from 'node:fs';
62
- * import { createGzip } from 'node:zlib';
63
- *
64
- * await pipeline(
65
- * createReadStream('archive.tar'),
66
- * createGzip(),
67
- * createWriteStream('archive.tar.gz'),
68
- * );
69
- * console.log('Pipeline succeeded.');
70
- * ```
71
- *
72
- * To use an `AbortSignal`, pass it inside an options object, as the last argument.
73
- * When the signal is aborted, `destroy` will be called on the underlying pipeline,
74
- * with an `AbortError`.
75
- *
76
- * ```js
77
- * import { pipeline } from 'node:stream/promises';
78
- * import { createReadStream, createWriteStream } from 'node:fs';
79
- * import { createGzip } from 'node:zlib';
80
- *
81
- * const ac = new AbortController();
82
- * const { signal } = ac;
83
- * setImmediate(() => ac.abort());
84
- * try {
85
- * await pipeline(
86
- * createReadStream('archive.tar'),
87
- * createGzip(),
88
- * createWriteStream('archive.tar.gz'),
89
- * { signal },
90
- * );
91
- * } catch (err) {
92
- * console.error(err); // AbortError
93
- * }
94
- * ```
95
- *
96
- * The `pipeline` API also supports async generators:
97
- *
98
- * ```js
99
- * import { pipeline } from 'node:stream/promises';
100
- * import { createReadStream, createWriteStream } from 'node:fs';
101
- *
102
- * await pipeline(
103
- * createReadStream('lowercase.txt'),
104
- * async function* (source, { signal }) {
105
- * source.setEncoding('utf8'); // Work with strings rather than `Buffer`s.
106
- * for await (const chunk of source) {
107
- * yield await processChunk(chunk, { signal });
108
- * }
109
- * },
110
- * createWriteStream('uppercase.txt'),
111
- * );
112
- * console.log('Pipeline succeeded.');
113
- * ```
114
- *
115
- * Remember to handle the `signal` argument passed into the async generator.
116
- * Especially in the case where the async generator is the source for the
117
- * pipeline (i.e. first argument) or the pipeline will never complete.
118
- *
119
- * ```js
120
- * import { pipeline } from 'node:stream/promises';
121
- * import fs from 'node:fs';
122
- * await pipeline(
123
- * async function* ({ signal }) {
124
- * await someLongRunningfn({ signal });
125
- * yield 'asd';
126
- * },
127
- * fs.createWriteStream('uppercase.txt'),
128
- * );
129
- * console.log('Pipeline succeeded.');
130
- * ```
131
- *
132
- * The `pipeline` API provides [callback version](https://nodejs.org/docs/latest-v26.x/api/stream.html#streampipelinesource-transforms-destination-callback):
133
- * @since v15.0.0
134
- * @returns Fulfills when the pipeline is complete.
135
- */
136
- function pipeline<A extends PipelineSource<any>, B extends PipelineDestination<A, any>>(
137
- source: A,
138
- destination: B,
139
- options?: PipelineOptions,
140
- ): PipelineResult<B>;
141
- function pipeline<
142
- A extends PipelineSource<any>,
143
- T1 extends PipelineTransform<A, any>,
144
- B extends PipelineDestination<T1, any>,
145
- >(
146
- source: A,
147
- transform1: T1,
148
- destination: B,
149
- options?: PipelineOptions,
150
- ): PipelineResult<B>;
151
- function pipeline<
152
- A extends PipelineSource<any>,
153
- T1 extends PipelineTransform<A, any>,
154
- T2 extends PipelineTransform<T1, any>,
155
- B extends PipelineDestination<T2, any>,
156
- >(
157
- source: A,
158
- transform1: T1,
159
- transform2: T2,
160
- destination: B,
161
- options?: PipelineOptions,
162
- ): PipelineResult<B>;
163
- function pipeline<
164
- A extends PipelineSource<any>,
165
- T1 extends PipelineTransform<A, any>,
166
- T2 extends PipelineTransform<T1, any>,
167
- T3 extends PipelineTransform<T2, any>,
168
- B extends PipelineDestination<T3, any>,
169
- >(
170
- source: A,
171
- transform1: T1,
172
- transform2: T2,
173
- transform3: T3,
174
- destination: B,
175
- options?: PipelineOptions,
176
- ): PipelineResult<B>;
177
- function pipeline<
178
- A extends PipelineSource<any>,
179
- T1 extends PipelineTransform<A, any>,
180
- T2 extends PipelineTransform<T1, any>,
181
- T3 extends PipelineTransform<T2, any>,
182
- T4 extends PipelineTransform<T3, any>,
183
- B extends PipelineDestination<T4, any>,
184
- >(
185
- source: A,
186
- transform1: T1,
187
- transform2: T2,
188
- transform3: T3,
189
- transform4: T4,
190
- destination: B,
191
- options?: PipelineOptions,
192
- ): PipelineResult<B>;
193
- function pipeline(
194
- streams: readonly [PipelineSource<any>, ...PipelineTransform<any, any>[], PipelineDestination<any, any>],
195
- options?: PipelineOptions,
196
- ): Promise<void>;
197
- function pipeline(
198
- ...streams: [PipelineSource<any>, ...PipelineTransform<any, any>[], PipelineDestination<any, any>]
199
- ): Promise<void>;
200
- function pipeline(
201
- ...streams: [
202
- PipelineSource<any>,
203
- ...PipelineTransform<any, any>[],
204
- PipelineDestination<any, any>,
205
- options: PipelineOptions,
206
- ]
207
- ): Promise<void>;
208
- }
209
- declare module "stream/promises" {
210
- export * from "node:stream/promises";
211
- }
@@ -1,320 +0,0 @@
1
- declare module "node:stream/web" {
2
- import { TextDecoderCommon, TextDecoderOptions, TextEncoderCommon } from "node:util";
3
- type CompressionFormat = "brotli" | "deflate" | "deflate-raw" | "gzip";
4
- type ReadableStreamController<T> = ReadableStreamDefaultController<T> | ReadableByteStreamController;
5
- type ReadableStreamReader<T> = ReadableStreamDefaultReader<T> | ReadableStreamBYOBReader;
6
- type ReadableStreamReaderMode = "byob";
7
- type ReadableStreamReadResult<T> = ReadableStreamReadValueResult<T> | ReadableStreamReadDoneResult<T>;
8
- type ReadableStreamType = "bytes";
9
- interface GenericTransformStream {
10
- readonly readable: ReadableStream;
11
- readonly writable: WritableStream;
12
- }
13
- interface QueuingStrategy<T = any> {
14
- highWaterMark?: number;
15
- size?: QueuingStrategySize<T>;
16
- }
17
- interface QueuingStrategyInit {
18
- highWaterMark: number;
19
- }
20
- interface QueuingStrategySize<T = any> {
21
- (chunk: T): number;
22
- }
23
- interface ReadableStreamBYOBReaderReadOptions {
24
- min?: number;
25
- }
26
- interface ReadableStreamGenericReader {
27
- readonly closed: Promise<void>;
28
- cancel(reason?: any): Promise<void>;
29
- }
30
- interface ReadableStreamGetReaderOptions {
31
- mode?: ReadableStreamReaderMode;
32
- }
33
- interface ReadableStreamIteratorOptions {
34
- preventCancel?: boolean;
35
- }
36
- interface ReadableStreamReadDoneResult<T> {
37
- done: true;
38
- value: T | undefined;
39
- }
40
- interface ReadableStreamReadValueResult<T> {
41
- done: false;
42
- value: T;
43
- }
44
- interface ReadableWritablePair<R = any, W = any> {
45
- readable: ReadableStream<R>;
46
- writable: WritableStream<W>;
47
- }
48
- interface StreamPipeOptions {
49
- preventAbort?: boolean;
50
- preventCancel?: boolean;
51
- preventClose?: boolean;
52
- signal?: AbortSignal;
53
- }
54
- interface Transformer<I = any, O = any> {
55
- cancel?: TransformerCancelCallback;
56
- flush?: TransformerFlushCallback<O>;
57
- readableType?: undefined;
58
- start?: TransformerStartCallback<O>;
59
- transform?: TransformerTransformCallback<I, O>;
60
- writableType?: undefined;
61
- }
62
- interface TransformerCancelCallback {
63
- (reason: any): void | PromiseLike<void>;
64
- }
65
- interface TransformerFlushCallback<O> {
66
- (controller: TransformStreamDefaultController<O>): void | PromiseLike<void>;
67
- }
68
- interface TransformerStartCallback<O> {
69
- (controller: TransformStreamDefaultController<O>): any;
70
- }
71
- interface TransformerTransformCallback<I, O> {
72
- (chunk: I, controller: TransformStreamDefaultController<O>): void | PromiseLike<void>;
73
- }
74
- interface UnderlyingByteSource {
75
- autoAllocateChunkSize?: number;
76
- cancel?: UnderlyingSourceCancelCallback;
77
- pull?: (controller: ReadableByteStreamController) => void | PromiseLike<void>;
78
- start?: (controller: ReadableByteStreamController) => any;
79
- type: "bytes";
80
- }
81
- interface UnderlyingDefaultSource<R = any> {
82
- cancel?: UnderlyingSourceCancelCallback;
83
- pull?: (controller: ReadableStreamDefaultController<R>) => void | PromiseLike<void>;
84
- start?: (controller: ReadableStreamDefaultController<R>) => any;
85
- type?: undefined;
86
- }
87
- interface UnderlyingSink<W = any> {
88
- abort?: UnderlyingSinkAbortCallback;
89
- close?: UnderlyingSinkCloseCallback;
90
- start?: UnderlyingSinkStartCallback;
91
- type?: undefined;
92
- write?: UnderlyingSinkWriteCallback<W>;
93
- }
94
- interface UnderlyingSinkAbortCallback {
95
- (reason?: any): void | PromiseLike<void>;
96
- }
97
- interface UnderlyingSinkCloseCallback {
98
- (): void | PromiseLike<void>;
99
- }
100
- interface UnderlyingSinkStartCallback {
101
- (controller: WritableStreamDefaultController): any;
102
- }
103
- interface UnderlyingSinkWriteCallback<W> {
104
- (chunk: W, controller: WritableStreamDefaultController): void | PromiseLike<void>;
105
- }
106
- interface UnderlyingSource<R = any> {
107
- autoAllocateChunkSize?: number;
108
- cancel?: UnderlyingSourceCancelCallback;
109
- pull?: UnderlyingSourcePullCallback<R>;
110
- start?: UnderlyingSourceStartCallback<R>;
111
- type?: ReadableStreamType;
112
- }
113
- interface UnderlyingSourceCancelCallback {
114
- (reason?: any): void | PromiseLike<void>;
115
- }
116
- interface UnderlyingSourcePullCallback<R> {
117
- (controller: ReadableStreamController<R>): void | PromiseLike<void>;
118
- }
119
- interface UnderlyingSourceStartCallback<R> {
120
- (controller: ReadableStreamController<R>): any;
121
- }
122
- interface ByteLengthQueuingStrategy extends QueuingStrategy<NodeJS.ArrayBufferView> {
123
- readonly highWaterMark: number;
124
- readonly size: QueuingStrategySize<NodeJS.ArrayBufferView>;
125
- }
126
- var ByteLengthQueuingStrategy: {
127
- prototype: ByteLengthQueuingStrategy;
128
- new(init: QueuingStrategyInit): ByteLengthQueuingStrategy;
129
- };
130
- interface CompressionStream extends GenericTransformStream {
131
- readonly readable: ReadableStream<NodeJS.NonSharedUint8Array>;
132
- readonly writable: WritableStream<NodeJS.BufferSource>;
133
- }
134
- var CompressionStream: {
135
- prototype: CompressionStream;
136
- new(format: CompressionFormat): CompressionStream;
137
- };
138
- interface CountQueuingStrategy extends QueuingStrategy {
139
- readonly highWaterMark: number;
140
- readonly size: QueuingStrategySize;
141
- }
142
- var CountQueuingStrategy: {
143
- prototype: CountQueuingStrategy;
144
- new(init: QueuingStrategyInit): CountQueuingStrategy;
145
- };
146
- interface DecompressionStream extends GenericTransformStream {
147
- readonly readable: ReadableStream<NodeJS.NonSharedUint8Array>;
148
- readonly writable: WritableStream<NodeJS.BufferSource>;
149
- }
150
- var DecompressionStream: {
151
- prototype: DecompressionStream;
152
- new(format: CompressionFormat): DecompressionStream;
153
- };
154
- interface ReadableByteStreamController {
155
- readonly byobRequest: ReadableStreamBYOBRequest | null;
156
- readonly desiredSize: number | null;
157
- close(): void;
158
- enqueue(chunk: NodeJS.NonSharedArrayBufferView): void;
159
- error(e?: any): void;
160
- }
161
- var ReadableByteStreamController: {
162
- prototype: ReadableByteStreamController;
163
- new(): ReadableByteStreamController;
164
- };
165
- interface ReadableStream<R = any> {
166
- readonly locked: boolean;
167
- cancel(reason?: any): Promise<void>;
168
- getReader(options: { mode: "byob" }): ReadableStreamBYOBReader;
169
- getReader(): ReadableStreamDefaultReader<R>;
170
- getReader(options?: ReadableStreamGetReaderOptions): ReadableStreamReader<R>;
171
- pipeThrough<T>(transform: ReadableWritablePair<T, R>, options?: StreamPipeOptions): ReadableStream<T>;
172
- pipeTo(destination: WritableStream<R>, options?: StreamPipeOptions): Promise<void>;
173
- tee(): [ReadableStream<R>, ReadableStream<R>];
174
- [Symbol.asyncIterator](options?: ReadableStreamIteratorOptions): ReadableStreamAsyncIterator<R>;
175
- values(options?: ReadableStreamIteratorOptions): ReadableStreamAsyncIterator<R>;
176
- }
177
- var ReadableStream: {
178
- prototype: ReadableStream;
179
- new(
180
- underlyingSource: UnderlyingByteSource,
181
- strategy?: { highWaterMark?: number },
182
- ): ReadableStream<NodeJS.NonSharedUint8Array>;
183
- new<R = any>(underlyingSource: UnderlyingDefaultSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
184
- new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
185
- from<R = any>(iterable: Iterable<R> | AsyncIterable<R>): ReadableStream<R>;
186
- };
187
- interface ReadableStreamAsyncIterator<T> extends NodeJS.AsyncIterator<T, BuiltinIteratorReturn, unknown> {
188
- [Symbol.asyncIterator](): ReadableStreamAsyncIterator<T>;
189
- }
190
- interface ReadableStreamBYOBReader extends ReadableStreamGenericReader {
191
- read<T extends NodeJS.NonSharedArrayBufferView>(
192
- view: T,
193
- options?: ReadableStreamBYOBReaderReadOptions,
194
- ): Promise<ReadableStreamReadResult<T>>;
195
- releaseLock(): void;
196
- }
197
- var ReadableStreamBYOBReader: {
198
- prototype: ReadableStreamBYOBReader;
199
- new(stream: ReadableStream<NodeJS.NonSharedUint8Array>): ReadableStreamBYOBReader;
200
- };
201
- interface ReadableStreamBYOBRequest {
202
- readonly view: NodeJS.NonSharedArrayBufferView | null;
203
- respond(bytesWritten: number): void;
204
- respondWithNewView(view: NodeJS.NonSharedArrayBufferView): void;
205
- }
206
- var ReadableStreamBYOBRequest: {
207
- prototype: ReadableStreamBYOBRequest;
208
- new(): ReadableStreamBYOBRequest;
209
- };
210
- interface ReadableStreamDefaultController<R = any> {
211
- readonly desiredSize: number | null;
212
- close(): void;
213
- enqueue(chunk: R): void;
214
- error(e?: any): void;
215
- }
216
- var ReadableStreamDefaultController: {
217
- prototype: ReadableStreamDefaultController;
218
- new(): ReadableStreamDefaultController;
219
- };
220
- interface ReadableStreamDefaultReader<R = any> extends ReadableStreamGenericReader {
221
- read(): Promise<ReadableStreamReadResult<R>>;
222
- releaseLock(): void;
223
- }
224
- var ReadableStreamDefaultReader: {
225
- prototype: ReadableStreamDefaultReader;
226
- new<R = any>(stream: ReadableStream<R>): ReadableStreamDefaultReader<R>;
227
- };
228
- interface TextDecoderStream extends GenericTransformStream, TextDecoderCommon {
229
- readonly readable: ReadableStream<string>;
230
- readonly writable: WritableStream<NodeJS.BufferSource>;
231
- }
232
- var TextDecoderStream: {
233
- prototype: TextDecoderStream;
234
- new(label?: string, options?: TextDecoderOptions): TextDecoderStream;
235
- };
236
- interface TextEncoderStream extends GenericTransformStream, TextEncoderCommon {
237
- readonly readable: ReadableStream<NodeJS.NonSharedUint8Array>;
238
- readonly writable: WritableStream<string>;
239
- }
240
- var TextEncoderStream: {
241
- prototype: TextEncoderStream;
242
- new(): TextEncoderStream;
243
- };
244
- interface TransformStream<I = any, O = any> {
245
- readonly readable: ReadableStream<O>;
246
- readonly writable: WritableStream<I>;
247
- }
248
- var TransformStream: {
249
- prototype: TransformStream;
250
- new<I = any, O = any>(
251
- transformer?: Transformer<I, O>,
252
- writableStrategy?: QueuingStrategy<I>,
253
- readableStrategy?: QueuingStrategy<O>,
254
- ): TransformStream<I, O>;
255
- };
256
- interface TransformStreamDefaultController<O = any> {
257
- readonly desiredSize: number | null;
258
- enqueue(chunk: O): void;
259
- error(reason?: any): void;
260
- terminate(): void;
261
- }
262
- var TransformStreamDefaultController: {
263
- prototype: TransformStreamDefaultController;
264
- new(): TransformStreamDefaultController;
265
- };
266
- interface WritableStream<W = any> {
267
- readonly locked: boolean;
268
- abort(reason?: any): Promise<void>;
269
- close(): Promise<void>;
270
- getWriter(): WritableStreamDefaultWriter<W>;
271
- }
272
- var WritableStream: {
273
- prototype: WritableStream;
274
- new<W = any>(underlyingSink?: UnderlyingSink<W>, strategy?: QueuingStrategy<W>): WritableStream<W>;
275
- };
276
- interface WritableStreamDefaultController {
277
- readonly signal: AbortSignal;
278
- error(e?: any): void;
279
- }
280
- var WritableStreamDefaultController: {
281
- prototype: WritableStreamDefaultController;
282
- new(): WritableStreamDefaultController;
283
- };
284
- interface WritableStreamDefaultWriter<W = any> {
285
- readonly closed: Promise<void>;
286
- readonly desiredSize: number | null;
287
- readonly ready: Promise<void>;
288
- abort(reason?: any): Promise<void>;
289
- close(): Promise<void>;
290
- releaseLock(): void;
291
- write(chunk: W): Promise<void>;
292
- }
293
- var WritableStreamDefaultWriter: {
294
- prototype: WritableStreamDefaultWriter;
295
- new<W = any>(stream: WritableStream<W>): WritableStreamDefaultWriter<W>;
296
- };
297
- // Node.js extensions
298
- /**
299
- * Runs the WHATWG `ReadableStreamTee` abstract operation on `stream`.
300
- *
301
- * This differs from `readableStream.tee()` only when `cloneForBranch2` is
302
- * `true`. The `tee()` method always passes `false`, while other web platform
303
- * specifications, such as Fetch body cloning, pass `true` so that the second
304
- * branch receives cloned chunks and consumption of one branch cannot mutate chunks
305
- * seen by the other.
306
- * @since v26.5.0
307
- * @experimental
308
- * @param cloneForBranch2 When `true`, chunks enqueued into the second
309
- * branch are cloned from chunks enqueued into the first branch. **Default:**
310
- * `false`.
311
- * @returns Two `ReadableStream` branches.
312
- */
313
- function ReadableStreamTee<R>(
314
- stream: ReadableStream<R>,
315
- cloneForBranch2?: boolean,
316
- ): [ReadableStream<R>, ReadableStream<R>];
317
- }
318
- declare module "stream/web" {
319
- export * from "node:stream/web";
320
- }