@openclaw/slack 2026.6.5 → 2026.6.6-beta.1

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 (106) hide show
  1. package/dist/api.js +2 -2
  2. package/dist/{channel-C15EZbTc.js → channel-i43aT1rv.js} +1 -1
  3. package/dist/channel-plugin-api.js +1 -1
  4. package/dist/contract-api.js +1 -5
  5. package/dist/{monitor-C1P_IgPU.js → monitor-Szm2LjsM.js} +1 -1
  6. package/dist/{pipeline.runtime-DDELeqeP.js → pipeline.runtime-Dvqs0AT-.js} +1 -1
  7. package/dist/{provider-Cxqi3uh_.js → provider-LH_j-bLA.js} +2 -1
  8. package/dist/runtime-api.js +2 -2
  9. package/node_modules/@types/node/README.md +1 -1
  10. package/node_modules/@types/node/http2.d.ts +3 -0
  11. package/node_modules/@types/node/package.json +2 -2
  12. package/node_modules/@types/ws/node_modules/@types/node/LICENSE +21 -0
  13. package/node_modules/@types/ws/node_modules/@types/node/README.md +15 -0
  14. package/node_modules/@types/ws/node_modules/@types/node/assert/strict.d.ts +59 -0
  15. package/node_modules/@types/ws/node_modules/@types/node/assert.d.ts +950 -0
  16. package/node_modules/@types/ws/node_modules/@types/node/async_hooks.d.ts +711 -0
  17. package/node_modules/@types/ws/node_modules/@types/node/buffer.buffer.d.ts +466 -0
  18. package/node_modules/@types/ws/node_modules/@types/node/buffer.d.ts +1765 -0
  19. package/node_modules/@types/ws/node_modules/@types/node/child_process.d.ts +1366 -0
  20. package/node_modules/@types/ws/node_modules/@types/node/cluster.d.ts +432 -0
  21. package/node_modules/@types/ws/node_modules/@types/node/compatibility/iterators.d.ts +21 -0
  22. package/node_modules/@types/ws/node_modules/@types/node/console.d.ts +93 -0
  23. package/node_modules/@types/ws/node_modules/@types/node/constants.d.ts +14 -0
  24. package/node_modules/@types/ws/node_modules/@types/node/crypto.d.ts +4058 -0
  25. package/node_modules/@types/ws/node_modules/@types/node/dgram.d.ts +537 -0
  26. package/node_modules/@types/ws/node_modules/@types/node/diagnostics_channel.d.ts +552 -0
  27. package/node_modules/@types/ws/node_modules/@types/node/dns/promises.d.ts +497 -0
  28. package/node_modules/@types/ws/node_modules/@types/node/dns.d.ts +876 -0
  29. package/node_modules/@types/ws/node_modules/@types/node/domain.d.ts +150 -0
  30. package/node_modules/@types/ws/node_modules/@types/node/events.d.ts +1008 -0
  31. package/node_modules/@types/ws/node_modules/@types/node/fs/promises.d.ts +1468 -0
  32. package/node_modules/@types/ws/node_modules/@types/node/fs.d.ts +4780 -0
  33. package/node_modules/@types/ws/node_modules/@types/node/globals.d.ts +150 -0
  34. package/node_modules/@types/ws/node_modules/@types/node/globals.typedarray.d.ts +101 -0
  35. package/node_modules/@types/ws/node_modules/@types/node/http.d.ts +2147 -0
  36. package/node_modules/@types/ws/node_modules/@types/node/http2.d.ts +2485 -0
  37. package/node_modules/@types/ws/node_modules/@types/node/https.d.ts +400 -0
  38. package/node_modules/@types/ws/node_modules/@types/node/index.d.ts +117 -0
  39. package/node_modules/@types/ws/node_modules/@types/node/inspector/promises.d.ts +35 -0
  40. package/node_modules/@types/ws/node_modules/@types/node/inspector.d.ts +264 -0
  41. package/node_modules/@types/ws/node_modules/@types/node/inspector.generated.d.ts +4406 -0
  42. package/node_modules/@types/ws/node_modules/@types/node/module.d.ts +755 -0
  43. package/node_modules/@types/ws/node_modules/@types/node/net.d.ts +970 -0
  44. package/node_modules/@types/ws/node_modules/@types/node/os.d.ts +498 -0
  45. package/node_modules/@types/ws/node_modules/@types/node/package.json +155 -0
  46. package/node_modules/@types/ws/node_modules/@types/node/path/posix.d.ts +8 -0
  47. package/node_modules/@types/ws/node_modules/@types/node/path/win32.d.ts +8 -0
  48. package/node_modules/@types/ws/node_modules/@types/node/path.d.ts +178 -0
  49. package/node_modules/@types/ws/node_modules/@types/node/perf_hooks.d.ts +612 -0
  50. package/node_modules/@types/ws/node_modules/@types/node/process.d.ts +2204 -0
  51. package/node_modules/@types/ws/node_modules/@types/node/punycode.d.ts +89 -0
  52. package/node_modules/@types/ws/node_modules/@types/node/querystring.d.ts +139 -0
  53. package/node_modules/@types/ws/node_modules/@types/node/quic.d.ts +897 -0
  54. package/node_modules/@types/ws/node_modules/@types/node/readline/promises.d.ts +158 -0
  55. package/node_modules/@types/ws/node_modules/@types/node/readline.d.ts +507 -0
  56. package/node_modules/@types/ws/node_modules/@types/node/repl.d.ts +420 -0
  57. package/node_modules/@types/ws/node_modules/@types/node/sea.d.ts +47 -0
  58. package/node_modules/@types/ws/node_modules/@types/node/sqlite.d.ts +1068 -0
  59. package/node_modules/@types/ws/node_modules/@types/node/stream/consumers.d.ts +114 -0
  60. package/node_modules/@types/ws/node_modules/@types/node/stream/iter.d.ts +301 -0
  61. package/node_modules/@types/ws/node_modules/@types/node/stream/promises.d.ts +211 -0
  62. package/node_modules/@types/ws/node_modules/@types/node/stream/web.d.ts +300 -0
  63. package/node_modules/@types/ws/node_modules/@types/node/stream.d.ts +1774 -0
  64. package/node_modules/@types/ws/node_modules/@types/node/string_decoder.d.ts +27 -0
  65. package/node_modules/@types/ws/node_modules/@types/node/test/reporters.d.ts +59 -0
  66. package/node_modules/@types/ws/node_modules/@types/node/test.d.ts +2279 -0
  67. package/node_modules/@types/ws/node_modules/@types/node/timers/promises.d.ts +93 -0
  68. package/node_modules/@types/ws/node_modules/@types/node/timers.d.ts +149 -0
  69. package/node_modules/@types/ws/node_modules/@types/node/tls.d.ts +1193 -0
  70. package/node_modules/@types/ws/node_modules/@types/node/trace_events.d.ts +103 -0
  71. package/node_modules/@types/ws/node_modules/@types/node/ts5.6/buffer.buffer.d.ts +462 -0
  72. package/node_modules/@types/ws/node_modules/@types/node/ts5.6/compatibility/float16array.d.ts +71 -0
  73. package/node_modules/@types/ws/node_modules/@types/node/ts5.6/globals.typedarray.d.ts +36 -0
  74. package/node_modules/@types/ws/node_modules/@types/node/ts5.6/index.d.ts +119 -0
  75. package/node_modules/@types/ws/node_modules/@types/node/ts5.7/compatibility/float16array.d.ts +72 -0
  76. package/node_modules/@types/ws/node_modules/@types/node/ts5.7/index.d.ts +119 -0
  77. package/node_modules/@types/ws/node_modules/@types/node/tty.d.ts +225 -0
  78. package/node_modules/@types/ws/node_modules/@types/node/url.d.ts +556 -0
  79. package/node_modules/@types/ws/node_modules/@types/node/util/types.d.ts +558 -0
  80. package/node_modules/@types/ws/node_modules/@types/node/util.d.ts +1677 -0
  81. package/node_modules/@types/ws/node_modules/@types/node/v8.d.ts +980 -0
  82. package/node_modules/@types/ws/node_modules/@types/node/vm.d.ts +1136 -0
  83. package/node_modules/@types/ws/node_modules/@types/node/wasi.d.ts +131 -0
  84. package/node_modules/@types/ws/node_modules/@types/node/web-globals/abortcontroller.d.ts +59 -0
  85. package/node_modules/@types/ws/node_modules/@types/node/web-globals/blob.d.ts +23 -0
  86. package/node_modules/@types/ws/node_modules/@types/node/web-globals/console.d.ts +9 -0
  87. package/node_modules/@types/ws/node_modules/@types/node/web-globals/crypto.d.ts +39 -0
  88. package/node_modules/@types/ws/node_modules/@types/node/web-globals/domexception.d.ts +68 -0
  89. package/node_modules/@types/ws/node_modules/@types/node/web-globals/encoding.d.ts +11 -0
  90. package/node_modules/@types/ws/node_modules/@types/node/web-globals/events.d.ts +106 -0
  91. package/node_modules/@types/ws/node_modules/@types/node/web-globals/fetch.d.ts +69 -0
  92. package/node_modules/@types/ws/node_modules/@types/node/web-globals/importmeta.d.ts +13 -0
  93. package/node_modules/@types/ws/node_modules/@types/node/web-globals/messaging.d.ts +23 -0
  94. package/node_modules/@types/ws/node_modules/@types/node/web-globals/navigator.d.ts +25 -0
  95. package/node_modules/@types/ws/node_modules/@types/node/web-globals/performance.d.ts +45 -0
  96. package/node_modules/@types/ws/node_modules/@types/node/web-globals/storage.d.ts +24 -0
  97. package/node_modules/@types/ws/node_modules/@types/node/web-globals/streams.d.ts +115 -0
  98. package/node_modules/@types/ws/node_modules/@types/node/web-globals/timers.d.ts +44 -0
  99. package/node_modules/@types/ws/node_modules/@types/node/web-globals/url.d.ts +24 -0
  100. package/node_modules/@types/ws/node_modules/@types/node/worker_threads.d.ts +671 -0
  101. package/node_modules/@types/ws/node_modules/@types/node/zlib/iter.d.ts +131 -0
  102. package/node_modules/@types/ws/node_modules/@types/node/zlib.d.ts +589 -0
  103. package/node_modules/semver/classes/semver.js +19 -2
  104. package/node_modules/semver/package.json +1 -1
  105. package/npm-shrinkwrap.json +18 -9
  106. package/package.json +4 -4
@@ -0,0 +1,497 @@
1
+ declare module "node:dns/promises" {
2
+ import {
3
+ AnyRecord,
4
+ CaaRecord,
5
+ LookupAddress,
6
+ LookupAllOptions,
7
+ LookupOneOptions,
8
+ LookupOptions,
9
+ MxRecord,
10
+ NaptrRecord,
11
+ RecordWithTtl,
12
+ ResolveOptions,
13
+ ResolverOptions,
14
+ ResolveWithTtlOptions,
15
+ SoaRecord,
16
+ SrvRecord,
17
+ TlsaRecord,
18
+ } from "node:dns";
19
+ /**
20
+ * Returns an array of IP address strings, formatted according to [RFC 5952](https://tools.ietf.org/html/rfc5952#section-6),
21
+ * that are currently configured for DNS resolution. A string will include a port
22
+ * section if a custom port is used.
23
+ *
24
+ * ```js
25
+ * [
26
+ * '4.4.4.4',
27
+ * '2001:4860:4860::8888',
28
+ * '4.4.4.4:1053',
29
+ * '[2001:4860:4860::8888]:1053',
30
+ * ]
31
+ * ```
32
+ * @since v10.6.0
33
+ */
34
+ function getServers(): string[];
35
+ /**
36
+ * Resolves a host name (e.g. `'nodejs.org'`) into the first found A (IPv4) or
37
+ * AAAA (IPv6) record. All `option` properties are optional. If `options` is an
38
+ * integer, then it must be `4` or `6` – if `options` is not provided, then IPv4
39
+ * and IPv6 addresses are both returned if found.
40
+ *
41
+ * With the `all` option set to `true`, the `Promise` is resolved with `addresses` being an array of objects with the properties `address` and `family`.
42
+ *
43
+ * On error, the `Promise` is rejected with an [`Error`](https://nodejs.org/docs/latest-v20.x/api/errors.html#class-error) object, where `err.code` is the error code.
44
+ * Keep in mind that `err.code` will be set to `'ENOTFOUND'` not only when
45
+ * the host name does not exist but also when the lookup fails in other ways
46
+ * such as no available file descriptors.
47
+ *
48
+ * [`dnsPromises.lookup()`](https://nodejs.org/docs/latest-v20.x/api/dns.html#dnspromiseslookuphostname-options) does not necessarily have anything to do with the DNS
49
+ * protocol. The implementation uses an operating system facility that can
50
+ * associate names with addresses and vice versa. This implementation can have
51
+ * subtle but important consequences on the behavior of any Node.js program. Please
52
+ * take some time to consult the [Implementation considerations section](https://nodejs.org/docs/latest-v20.x/api/dns.html#implementation-considerations) before
53
+ * using `dnsPromises.lookup()`.
54
+ *
55
+ * Example usage:
56
+ *
57
+ * ```js
58
+ * import dns from 'node:dns';
59
+ * const dnsPromises = dns.promises;
60
+ * const options = {
61
+ * family: 6,
62
+ * hints: dns.ADDRCONFIG | dns.V4MAPPED,
63
+ * };
64
+ *
65
+ * dnsPromises.lookup('example.com', options).then((result) => {
66
+ * console.log('address: %j family: IPv%s', result.address, result.family);
67
+ * // address: "2606:2800:220:1:248:1893:25c8:1946" family: IPv6
68
+ * });
69
+ *
70
+ * // When options.all is true, the result will be an Array.
71
+ * options.all = true;
72
+ * dnsPromises.lookup('example.com', options).then((result) => {
73
+ * console.log('addresses: %j', result);
74
+ * // addresses: [{"address":"2606:2800:220:1:248:1893:25c8:1946","family":6}]
75
+ * });
76
+ * ```
77
+ * @since v10.6.0
78
+ */
79
+ function lookup(hostname: string, family: number): Promise<LookupAddress>;
80
+ function lookup(hostname: string, options: LookupOneOptions): Promise<LookupAddress>;
81
+ function lookup(hostname: string, options: LookupAllOptions): Promise<LookupAddress[]>;
82
+ function lookup(hostname: string, options: LookupOptions): Promise<LookupAddress | LookupAddress[]>;
83
+ function lookup(hostname: string): Promise<LookupAddress>;
84
+ /**
85
+ * Resolves the given `address` and `port` into a host name and service using
86
+ * the operating system's underlying `getnameinfo` implementation.
87
+ *
88
+ * If `address` is not a valid IP address, a `TypeError` will be thrown.
89
+ * The `port` will be coerced to a number. If it is not a legal port, a `TypeError` will be thrown.
90
+ *
91
+ * On error, the `Promise` is rejected with an [`Error`](https://nodejs.org/docs/latest-v20.x/api/errors.html#class-error) object, where `err.code` is the error code.
92
+ *
93
+ * ```js
94
+ * import dnsPromises from 'node:dns';
95
+ * dnsPromises.lookupService('127.0.0.1', 22).then((result) => {
96
+ * console.log(result.hostname, result.service);
97
+ * // Prints: localhost ssh
98
+ * });
99
+ * ```
100
+ * @since v10.6.0
101
+ */
102
+ function lookupService(
103
+ address: string,
104
+ port: number,
105
+ ): Promise<{
106
+ hostname: string;
107
+ service: string;
108
+ }>;
109
+ /**
110
+ * Uses the DNS protocol to resolve a host name (e.g. `'nodejs.org'`) into an array
111
+ * of the resource records. When successful, the `Promise` is resolved with an
112
+ * array of resource records. The type and structure of individual results vary
113
+ * based on `rrtype`:
114
+ *
115
+ * <omitted>
116
+ *
117
+ * On error, the `Promise` is rejected with an [`Error`](https://nodejs.org/docs/latest-v20.x/api/errors.html#class-error) object, where `err.code`
118
+ * is one of the [DNS error codes](https://nodejs.org/docs/latest-v20.x/api/dns.html#error-codes).
119
+ * @since v10.6.0
120
+ * @param hostname Host name to resolve.
121
+ * @param [rrtype='A'] Resource record type.
122
+ */
123
+ function resolve(hostname: string): Promise<string[]>;
124
+ function resolve(hostname: string, rrtype: "A" | "AAAA" | "CNAME" | "NS" | "PTR"): Promise<string[]>;
125
+ function resolve(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
126
+ function resolve(hostname: string, rrtype: "CAA"): Promise<CaaRecord[]>;
127
+ function resolve(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
128
+ function resolve(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
129
+ function resolve(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
130
+ function resolve(hostname: string, rrtype: "SRV"): Promise<SrvRecord[]>;
131
+ function resolve(hostname: string, rrtype: "TLSA"): Promise<TlsaRecord[]>;
132
+ function resolve(hostname: string, rrtype: "TXT"): Promise<string[][]>;
133
+ function resolve(hostname: string, rrtype: string): Promise<
134
+ | string[]
135
+ | CaaRecord[]
136
+ | MxRecord[]
137
+ | NaptrRecord[]
138
+ | SoaRecord
139
+ | SrvRecord[]
140
+ | TlsaRecord[]
141
+ | string[][]
142
+ | AnyRecord[]
143
+ >;
144
+ /**
145
+ * Uses the DNS protocol to resolve IPv4 addresses (`A` records) for the `hostname`. On success, the `Promise` is resolved with an array of IPv4
146
+ * addresses (e.g. `['74.125.79.104', '74.125.79.105', '74.125.79.106']`).
147
+ * @since v10.6.0
148
+ * @param hostname Host name to resolve.
149
+ */
150
+ function resolve4(hostname: string): Promise<string[]>;
151
+ function resolve4(hostname: string, options: ResolveWithTtlOptions): Promise<RecordWithTtl[]>;
152
+ function resolve4(hostname: string, options: ResolveOptions): Promise<string[] | RecordWithTtl[]>;
153
+ /**
154
+ * Uses the DNS protocol to resolve IPv6 addresses (`AAAA` records) for the `hostname`. On success, the `Promise` is resolved with an array of IPv6
155
+ * addresses.
156
+ * @since v10.6.0
157
+ * @param hostname Host name to resolve.
158
+ */
159
+ function resolve6(hostname: string): Promise<string[]>;
160
+ function resolve6(hostname: string, options: ResolveWithTtlOptions): Promise<RecordWithTtl[]>;
161
+ function resolve6(hostname: string, options: ResolveOptions): Promise<string[] | RecordWithTtl[]>;
162
+ /**
163
+ * Uses the DNS protocol to resolve all records (also known as `ANY` or `*` query).
164
+ * On success, the `Promise` is resolved with an array containing various types of
165
+ * records. Each object has a property `type` that indicates the type of the
166
+ * current record. And depending on the `type`, additional properties will be
167
+ * present on the object:
168
+ *
169
+ * <omitted>
170
+ *
171
+ * Here is an example of the result object:
172
+ *
173
+ * ```js
174
+ * [ { type: 'A', address: '127.0.0.1', ttl: 299 },
175
+ * { type: 'CNAME', value: 'example.com' },
176
+ * { type: 'MX', exchange: 'alt4.aspmx.l.example.com', priority: 50 },
177
+ * { type: 'NS', value: 'ns1.example.com' },
178
+ * { type: 'TXT', entries: [ 'v=spf1 include:_spf.example.com ~all' ] },
179
+ * { type: 'SOA',
180
+ * nsname: 'ns1.example.com',
181
+ * hostmaster: 'admin.example.com',
182
+ * serial: 156696742,
183
+ * refresh: 900,
184
+ * retry: 900,
185
+ * expire: 1800,
186
+ * minttl: 60 } ]
187
+ * ```
188
+ * @since v10.6.0
189
+ */
190
+ function resolveAny(hostname: string): Promise<AnyRecord[]>;
191
+ /**
192
+ * Uses the DNS protocol to resolve `CAA` records for the `hostname`. On success,
193
+ * the `Promise` is resolved with an array of objects containing available
194
+ * certification authority authorization records available for the `hostname` (e.g. `[{critical: 0, iodef: 'mailto:pki@example.com'},{critical: 128, issue: 'pki.example.com'}]`).
195
+ * @since v15.0.0, v14.17.0
196
+ */
197
+ function resolveCaa(hostname: string): Promise<CaaRecord[]>;
198
+ /**
199
+ * Uses the DNS protocol to resolve `CNAME` records for the `hostname`. On success,
200
+ * the `Promise` is resolved with an array of canonical name records available for
201
+ * the `hostname` (e.g. `['bar.example.com']`).
202
+ * @since v10.6.0
203
+ */
204
+ function resolveCname(hostname: string): Promise<string[]>;
205
+ /**
206
+ * Uses the DNS protocol to resolve mail exchange records (`MX` records) for the `hostname`. On success, the `Promise` is resolved with an array of objects
207
+ * containing both a `priority` and `exchange` property (e.g.`[{priority: 10, exchange: 'mx.example.com'}, ...]`).
208
+ * @since v10.6.0
209
+ */
210
+ function resolveMx(hostname: string): Promise<MxRecord[]>;
211
+ /**
212
+ * Uses the DNS protocol to resolve regular expression-based records (`NAPTR` records) for the `hostname`. On success, the `Promise` is resolved with an array
213
+ * of objects with the following properties:
214
+ *
215
+ * * `flags`
216
+ * * `service`
217
+ * * `regexp`
218
+ * * `replacement`
219
+ * * `order`
220
+ * * `preference`
221
+ *
222
+ * ```js
223
+ * {
224
+ * flags: 's',
225
+ * service: 'SIP+D2U',
226
+ * regexp: '',
227
+ * replacement: '_sip._udp.example.com',
228
+ * order: 30,
229
+ * preference: 100
230
+ * }
231
+ * ```
232
+ * @since v10.6.0
233
+ */
234
+ function resolveNaptr(hostname: string): Promise<NaptrRecord[]>;
235
+ /**
236
+ * Uses the DNS protocol to resolve name server records (`NS` records) for the `hostname`. On success, the `Promise` is resolved with an array of name server
237
+ * records available for `hostname` (e.g.`['ns1.example.com', 'ns2.example.com']`).
238
+ * @since v10.6.0
239
+ */
240
+ function resolveNs(hostname: string): Promise<string[]>;
241
+ /**
242
+ * Uses the DNS protocol to resolve pointer records (`PTR` records) for the `hostname`. On success, the `Promise` is resolved with an array of strings
243
+ * containing the reply records.
244
+ * @since v10.6.0
245
+ */
246
+ function resolvePtr(hostname: string): Promise<string[]>;
247
+ /**
248
+ * Uses the DNS protocol to resolve a start of authority record (`SOA` record) for
249
+ * the `hostname`. On success, the `Promise` is resolved with an object with the
250
+ * following properties:
251
+ *
252
+ * * `nsname`
253
+ * * `hostmaster`
254
+ * * `serial`
255
+ * * `refresh`
256
+ * * `retry`
257
+ * * `expire`
258
+ * * `minttl`
259
+ *
260
+ * ```js
261
+ * {
262
+ * nsname: 'ns.example.com',
263
+ * hostmaster: 'root.example.com',
264
+ * serial: 2013101809,
265
+ * refresh: 10000,
266
+ * retry: 2400,
267
+ * expire: 604800,
268
+ * minttl: 3600
269
+ * }
270
+ * ```
271
+ * @since v10.6.0
272
+ */
273
+ function resolveSoa(hostname: string): Promise<SoaRecord>;
274
+ /**
275
+ * Uses the DNS protocol to resolve service records (`SRV` records) for the `hostname`. On success, the `Promise` is resolved with an array of objects with
276
+ * the following properties:
277
+ *
278
+ * * `priority`
279
+ * * `weight`
280
+ * * `port`
281
+ * * `name`
282
+ *
283
+ * ```js
284
+ * {
285
+ * priority: 10,
286
+ * weight: 5,
287
+ * port: 21223,
288
+ * name: 'service.example.com'
289
+ * }
290
+ * ```
291
+ * @since v10.6.0
292
+ */
293
+ function resolveSrv(hostname: string): Promise<SrvRecord[]>;
294
+ /**
295
+ * Uses the DNS protocol to resolve certificate associations (`TLSA` records) for
296
+ * the `hostname`. On success, the `Promise` is resolved with an array of objectsAdd commentMore actions
297
+ * with these properties:
298
+ *
299
+ * * `certUsage`
300
+ * * `selector`
301
+ * * `match`
302
+ * * `data`
303
+ *
304
+ * ```js
305
+ * {
306
+ * certUsage: 3,
307
+ * selector: 1,
308
+ * match: 1,
309
+ * data: [ArrayBuffer]
310
+ * }
311
+ * ```
312
+ * @since v23.9.0, v22.15.0
313
+ */
314
+ function resolveTlsa(hostname: string): Promise<TlsaRecord[]>;
315
+ /**
316
+ * Uses the DNS protocol to resolve text queries (`TXT` records) for the `hostname`. On success, the `Promise` is resolved with a two-dimensional array
317
+ * of the text records available for `hostname` (e.g.`[ ['v=spf1 ip4:0.0.0.0 ', '~all' ] ]`). Each sub-array contains TXT chunks of
318
+ * one record. Depending on the use case, these could be either joined together or
319
+ * treated separately.
320
+ * @since v10.6.0
321
+ */
322
+ function resolveTxt(hostname: string): Promise<string[][]>;
323
+ /**
324
+ * Performs a reverse DNS query that resolves an IPv4 or IPv6 address to an
325
+ * array of host names.
326
+ *
327
+ * On error, the `Promise` is rejected with an [`Error`](https://nodejs.org/docs/latest-v20.x/api/errors.html#class-error) object, where `err.code`
328
+ * is one of the [DNS error codes](https://nodejs.org/docs/latest-v20.x/api/dns.html#error-codes).
329
+ * @since v10.6.0
330
+ */
331
+ function reverse(ip: string): Promise<string[]>;
332
+ /**
333
+ * Get the default value for `verbatim` in {@link lookup} and [dnsPromises.lookup()](https://nodejs.org/docs/latest-v20.x/api/dns.html#dnspromiseslookuphostname-options).
334
+ * The value could be:
335
+ *
336
+ * * `ipv4first`: for `verbatim` defaulting to `false`.
337
+ * * `verbatim`: for `verbatim` defaulting to `true`.
338
+ * @since v20.1.0
339
+ */
340
+ function getDefaultResultOrder(): "ipv4first" | "verbatim";
341
+ /**
342
+ * Sets the IP address and port of servers to be used when performing DNS
343
+ * resolution. The `servers` argument is an array of [RFC 5952](https://tools.ietf.org/html/rfc5952#section-6) formatted
344
+ * addresses. If the port is the IANA default DNS port (53) it can be omitted.
345
+ *
346
+ * ```js
347
+ * dnsPromises.setServers([
348
+ * '4.4.4.4',
349
+ * '[2001:4860:4860::8888]',
350
+ * '4.4.4.4:1053',
351
+ * '[2001:4860:4860::8888]:1053',
352
+ * ]);
353
+ * ```
354
+ *
355
+ * An error will be thrown if an invalid address is provided.
356
+ *
357
+ * The `dnsPromises.setServers()` method must not be called while a DNS query is in
358
+ * progress.
359
+ *
360
+ * This method works much like [resolve.conf](https://man7.org/linux/man-pages/man5/resolv.conf.5.html).
361
+ * That is, if attempting to resolve with the first server provided results in a `NOTFOUND` error, the `resolve()` method will _not_ attempt to resolve with
362
+ * subsequent servers provided. Fallback DNS servers will only be used if the
363
+ * earlier ones time out or result in some other error.
364
+ * @since v10.6.0
365
+ * @param servers array of `RFC 5952` formatted addresses
366
+ */
367
+ function setServers(servers: readonly string[]): void;
368
+ /**
369
+ * Set the default value of `order` in `dns.lookup()` and `{@link lookup}`. The value could be:
370
+ *
371
+ * * `ipv4first`: sets default `order` to `ipv4first`.
372
+ * * `ipv6first`: sets default `order` to `ipv6first`.
373
+ * * `verbatim`: sets default `order` to `verbatim`.
374
+ *
375
+ * The default is `verbatim` and [dnsPromises.setDefaultResultOrder()](https://nodejs.org/docs/latest-v20.x/api/dns.html#dnspromisessetdefaultresultorderorder)
376
+ * have higher priority than [`--dns-result-order`](https://nodejs.org/docs/latest-v20.x/api/cli.html#--dns-result-orderorder).
377
+ * When using [worker threads](https://nodejs.org/docs/latest-v20.x/api/worker_threads.html), [`dnsPromises.setDefaultResultOrder()`](https://nodejs.org/docs/latest-v20.x/api/dns.html#dnspromisessetdefaultresultorderorder)
378
+ * from the main thread won't affect the default dns orders in workers.
379
+ * @since v16.4.0, v14.18.0
380
+ * @param order must be `'ipv4first'`, `'ipv6first'` or `'verbatim'`.
381
+ */
382
+ function setDefaultResultOrder(order: "ipv4first" | "ipv6first" | "verbatim"): void;
383
+ // Error codes
384
+ const NODATA: "ENODATA";
385
+ const FORMERR: "EFORMERR";
386
+ const SERVFAIL: "ESERVFAIL";
387
+ const NOTFOUND: "ENOTFOUND";
388
+ const NOTIMP: "ENOTIMP";
389
+ const REFUSED: "EREFUSED";
390
+ const BADQUERY: "EBADQUERY";
391
+ const BADNAME: "EBADNAME";
392
+ const BADFAMILY: "EBADFAMILY";
393
+ const BADRESP: "EBADRESP";
394
+ const CONNREFUSED: "ECONNREFUSED";
395
+ const TIMEOUT: "ETIMEOUT";
396
+ const EOF: "EOF";
397
+ const FILE: "EFILE";
398
+ const NOMEM: "ENOMEM";
399
+ const DESTRUCTION: "EDESTRUCTION";
400
+ const BADSTR: "EBADSTR";
401
+ const BADFLAGS: "EBADFLAGS";
402
+ const NONAME: "ENONAME";
403
+ const BADHINTS: "EBADHINTS";
404
+ const NOTINITIALIZED: "ENOTINITIALIZED";
405
+ const LOADIPHLPAPI: "ELOADIPHLPAPI";
406
+ const ADDRGETNETWORKPARAMS: "EADDRGETNETWORKPARAMS";
407
+ const CANCELLED: "ECANCELLED";
408
+
409
+ /**
410
+ * An independent resolver for DNS requests.
411
+ *
412
+ * Creating a new resolver uses the default server settings. Setting
413
+ * the servers used for a resolver using [`resolver.setServers()`](https://nodejs.org/docs/latest-v20.x/api/dns.html#dnspromisessetserversservers) does not affect
414
+ * other resolvers:
415
+ *
416
+ * ```js
417
+ * import { promises } from 'node:dns';
418
+ * const resolver = new promises.Resolver();
419
+ * resolver.setServers(['4.4.4.4']);
420
+ *
421
+ * // This request will use the server at 4.4.4.4, independent of global settings.
422
+ * resolver.resolve4('example.org').then((addresses) => {
423
+ * // ...
424
+ * });
425
+ *
426
+ * // Alternatively, the same code can be written using async-await style.
427
+ * (async function() {
428
+ * const addresses = await resolver.resolve4('example.org');
429
+ * })();
430
+ * ```
431
+ *
432
+ * The following methods from the `dnsPromises` API are available:
433
+ *
434
+ * * `resolver.getServers()`
435
+ * * `resolver.resolve()`
436
+ * * `resolver.resolve4()`
437
+ * * `resolver.resolve6()`
438
+ * * `resolver.resolveAny()`
439
+ * * `resolver.resolveCaa()`
440
+ * * `resolver.resolveCname()`
441
+ * * `resolver.resolveMx()`
442
+ * * `resolver.resolveNaptr()`
443
+ * * `resolver.resolveNs()`
444
+ * * `resolver.resolvePtr()`
445
+ * * `resolver.resolveSoa()`
446
+ * * `resolver.resolveSrv()`
447
+ * * `resolver.resolveTxt()`
448
+ * * `resolver.reverse()`
449
+ * * `resolver.setServers()`
450
+ * @since v10.6.0
451
+ */
452
+ class Resolver {
453
+ constructor(options?: ResolverOptions);
454
+ /**
455
+ * Cancel all outstanding DNS queries made by this resolver. The corresponding
456
+ * callbacks will be called with an error with code `ECANCELLED`.
457
+ * @since v8.3.0
458
+ */
459
+ cancel(): void;
460
+ getServers: typeof getServers;
461
+ resolve: typeof resolve;
462
+ resolve4: typeof resolve4;
463
+ resolve6: typeof resolve6;
464
+ resolveAny: typeof resolveAny;
465
+ resolveCaa: typeof resolveCaa;
466
+ resolveCname: typeof resolveCname;
467
+ resolveMx: typeof resolveMx;
468
+ resolveNaptr: typeof resolveNaptr;
469
+ resolveNs: typeof resolveNs;
470
+ resolvePtr: typeof resolvePtr;
471
+ resolveSoa: typeof resolveSoa;
472
+ resolveSrv: typeof resolveSrv;
473
+ resolveTlsa: typeof resolveTlsa;
474
+ resolveTxt: typeof resolveTxt;
475
+ reverse: typeof reverse;
476
+ /**
477
+ * The resolver instance will send its requests from the specified IP address.
478
+ * This allows programs to specify outbound interfaces when used on multi-homed
479
+ * systems.
480
+ *
481
+ * If a v4 or v6 address is not specified, it is set to the default and the
482
+ * operating system will choose a local address automatically.
483
+ *
484
+ * The resolver will use the v4 local address when making requests to IPv4 DNS
485
+ * servers, and the v6 local address when making requests to IPv6 DNS servers.
486
+ * The `rrtype` of resolution requests has no impact on the local address used.
487
+ * @since v15.1.0, v14.17.0
488
+ * @param [ipv4='0.0.0.0'] A string representation of an IPv4 address.
489
+ * @param [ipv6='::0'] A string representation of an IPv6 address.
490
+ */
491
+ setLocalAddress(ipv4?: string, ipv6?: string): void;
492
+ setServers: typeof setServers;
493
+ }
494
+ }
495
+ declare module "dns/promises" {
496
+ export * from "node:dns/promises";
497
+ }