arthron 0.0.1 → 1.0.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.
package/dist/index.d.cts CHANGED
@@ -1,11 +1,86 @@
1
- //#region src/error.d.ts
2
- type ErrorMessageResolver = (data: unknown, response: Response) => string | undefined;
1
+ //#region src/types/request.types.d.ts
2
+ /**
3
+ * What plugins see and return. `init.headers` is always a plain record with
4
+ * lowercased names — spread it, read it, add to it — and the pipeline puts
5
+ * it back into that shape after every request interceptor.
6
+ */
7
+ interface RequestContext {
8
+ url: string;
9
+ init: Omit<RequestInit, "headers"> & {
10
+ headers: Record<string, string>;
11
+ };
12
+ /** Per-call settings for plugins (`RequestOptions.meta`); never sent. */
13
+ meta: ArthronMeta;
14
+ }
15
+ /**
16
+ * Per-call settings for plugins, passed as `api.get(path, { meta })` and
17
+ * carried next to `init` — never sent to fetch. The built-in plugins read
18
+ * `retry` and `timeout`; your own add keys by augmentation:
19
+ *
20
+ * ```ts
21
+ * declare module "arthron" {
22
+ * interface ArthronMeta { skipAuth?: boolean }
23
+ * }
24
+ * ```
25
+ */
26
+ interface ArthronMeta {
27
+ /** `false` turns `retry()` off for this call; an object overrides its options. */
28
+ retry?: false | Omit<RetryOptions, "sleep">;
29
+ /** Deadline for this call in ms, overriding `timeout(ms)`. `Infinity` lifts it. */
30
+ timeout?: number;
31
+ }
32
+ type RetryOptions = {
33
+ /** Number of retries after the first attempt. Default 2 (3 requests total). */
34
+ retries?: number;
35
+ /** Statuses worth retrying. Network errors (status 0) always are. */
36
+ retryOn?: readonly number[];
37
+ /** Methods safe to repeat (QUERY is, per RFC 10008). Compared case-insensitively. */
38
+ methods?: readonly string[];
39
+ /**
40
+ * Backoff in ms for retry number `retry` (0-based). Default "full jitter":
41
+ * a random share of 300 · 2^retry, so clients that failed together do not
42
+ * retry together.
43
+ */
44
+ delay?: (retry: number, error: unknown) => number;
45
+ /**
46
+ * Your own verdict on one failure: `true` retries, `false` stops,
47
+ * `undefined` leaves it to `retryOn`/`methods`. It sees every error — a
48
+ * TimeoutError from a `timeout()` placed after `retry()` included — but
49
+ * cannot exceed `retries`, resend a `ReadableStream` body, or retry a call
50
+ * the caller aborted.
51
+ */
52
+ shouldRetry?: (error: unknown, attempt: number, ctx: RequestContext) => boolean | undefined;
53
+ /** Called before each wait, for logs and metrics. */
54
+ onRetry?: (error: unknown, attempt: number, waitMs: number) => void;
55
+ /** Injectable for tests. Default `setTimeout`; rejects with the abort reason. */
56
+ sleep?: (ms: number, signal?: AbortSignal | null) => Promise<void>;
57
+ /**
58
+ * Longest `Retry-After` (ms) worth honouring. Beyond it the request is not
59
+ * retried at all. Default 60 000.
60
+ */
61
+ maxRetryAfter?: number;
62
+ };
63
+ type QueryValue = string | number | boolean | null | undefined;
64
+ /**
65
+ * Query parameters. `null`/`undefined` values are skipped, an array becomes
66
+ * repeated keys (`ids=1&ids=2`), and a `URLSearchParams` is used as is.
67
+ */
68
+ type QueryParams = Record<string, QueryValue | readonly QueryValue[]> | URLSearchParams;
69
+ /**
70
+ * Headers as config and per-call options accept them: any `HeadersInit`, or a
71
+ * plain object whose `null`/`undefined` values delete that header from the
72
+ * layer underneath (a client default, an inherited header).
73
+ */
74
+ type HeadersOption = HeadersInit | Record<string, string | null | undefined>;
75
+ //#endregion
76
+ //#region src/error/arthron-error.d.ts
3
77
  type ArthronErrorInit = {
4
78
  message: string;
5
79
  status: number;
6
80
  statusText: string;
7
81
  headers: Headers;
8
82
  data: unknown;
83
+ detail?: string | undefined;
9
84
  request: RequestContext;
10
85
  response?: Response;
11
86
  cause?: unknown;
@@ -17,25 +92,50 @@ type ArthronErrorInit = {
17
92
  */
18
93
  export declare class ArthronError extends Error {
19
94
  readonly name = "ArthronError";
95
+ /** HTTP status of the failed response; `0` when fetch itself failed (network). */
20
96
  readonly status: number;
21
97
  readonly statusText: string;
98
+ /** Response headers; empty for network failures. Not enumerable — kept out of logs. */
22
99
  readonly headers: Headers;
100
+ /** Parsed body: JSON if it parses, else the text, else `undefined`. */
23
101
  readonly data: unknown;
102
+ /**
103
+ * The server's own explanation, picked out of `data` (by default
104
+ * `message` → `error` → `error.message` → `detail`; see the `errorDetail`
105
+ * config). `undefined` when the body had none. Untrusted server text: show
106
+ * it to users as text, never as HTML. `message`, by contrast, is written by
107
+ * arthron — method, URL without query, status — and is meant for logs.
108
+ */
109
+ readonly detail: string | undefined;
110
+ /**
111
+ * The context that was sent — url and init after request interceptors.
112
+ * Not enumerable: it holds credentials, so `JSON.stringify`, `console.error`
113
+ * and error trackers leave it out. Read it directly when you need it.
114
+ */
24
115
  readonly request: RequestContext;
116
+ /** The failed Response, still readable — its body holds what arthron read (at most 64 KiB). Absent for network failures. Not enumerable. */
25
117
  readonly response: Response | undefined;
118
+ /** The underlying error for network failures. */
26
119
  readonly cause: unknown;
27
120
  constructor(init: ArthronErrorInit);
121
+ /** `instanceof ArthronError` holds for an error from any copy of the package. */
122
+ static [Symbol.hasInstance](value: unknown): boolean;
123
+ /** What serializers see: no headers, no body, no query or userinfo. */
124
+ toJSON(): {
125
+ name: string;
126
+ message: string;
127
+ detail: string | undefined;
128
+ status: number;
129
+ statusText: string;
130
+ method: string;
131
+ url: string;
132
+ data: unknown;
133
+ };
28
134
  }
135
+ /** `true` for errors arthron produced: a `!ok` response or a network failure. Cancellations and plugin bugs are not ArthronErrors. */
29
136
  export declare function isArthronError(error: unknown): error is ArthronError;
30
137
  //#endregion
31
- //#region src/url.d.ts
32
- type QueryParams = Record<string, string | number | boolean | null | undefined>;
33
- //#endregion
34
- //#region src/types.d.ts
35
- type RequestContext = {
36
- url: string;
37
- init: RequestInit;
38
- };
138
+ //#region src/types/plugin.types.d.ts
39
139
  /** Runs before each attempt. Returns the context to send (may be a new object). */
40
140
  type RequestInterceptor = (ctx: RequestContext) => RequestContext | Promise<RequestContext>;
41
141
  /** Runs after a successful attempt. The body is single-use — `clone()` to peek. */
@@ -49,111 +149,294 @@ type ErrorInterceptor = (err: ArthronError, ctx: RequestContext) => ArthronError
49
149
  * failure was a cancellation or a bug in a plugin.
50
150
  */
51
151
  type Middleware = (ctx: RequestContext, next: (ctx: RequestContext) => Promise<Response>) => Promise<Response>;
52
- type Plugin = {
53
- /** For logs and debugging only. */
152
+ interface Plugin {
153
+ /**
154
+ * Identity within a client: `use`/`extend` replace the plugin of the same
155
+ * name in place, `without(name)` removes it. The built-ins are named
156
+ * "retry", "timeout" and "logging". Leave it out to always append.
157
+ */
54
158
  name?: string;
55
159
  middleware?: Middleware;
56
160
  request?: RequestInterceptor;
57
161
  response?: ResponseInterceptor;
58
162
  error?: ErrorInterceptor;
163
+ }
164
+ //#endregion
165
+ //#region src/types/response.types.d.ts
166
+ interface ArthronPromise extends Promise<Response> {
167
+ /** The body as JSON. `T` is a cast — nothing checks it. */
168
+ json<T = unknown>(): Promise<T>;
169
+ /**
170
+ * The body as JSON, validated by a Standard Schema (Zod, Valibot, ArkType…)
171
+ * and typed by it. A mismatch rejects with a `SchemaError`.
172
+ */
173
+ json<S extends StandardSchemaV1>(schema: S): Promise<InferOutput<S>>;
174
+ text(): Promise<string>;
175
+ blob(): Promise<Blob>;
176
+ arrayBuffer(): Promise<ArrayBuffer>;
177
+ formData(): Promise<FormData>;
178
+ /** Iterate a `text/event-stream` body as events. */
179
+ sse(options?: SseOptions): AsyncIterable<SseEvent>;
180
+ /** Iterate a newline-delimited JSON body, one parsed value per line. */
181
+ ndjson<T = unknown>(options?: NdjsonOptions): AsyncIterable<T>;
182
+ }
183
+ /** One server-sent event, as described by the WHATWG EventSource spec. */
184
+ type SseEvent = {
185
+ /** The `event:` field, when the server sent one. */
186
+ event?: string;
187
+ /** All `data:` lines of the block, joined with `\n`. */
188
+ data: string;
189
+ /** The `id:` field of this event's own block, when it had one. */
190
+ id?: string;
191
+ /**
192
+ * The last event ID so far, as EventSource's `lastEventId`: it persists
193
+ * across events (a block with only `id:` updates it too) and is "" until
194
+ * the server sends one. Send it as `Last-Event-ID` to resume a stream.
195
+ */
196
+ lastEventId: string;
197
+ /** The reconnection time in ms the server last set with `retry:`; carried on every event after it. */
198
+ retry?: number;
59
199
  };
60
- type RequestOptions = Omit<RequestInit, "body" | "method"> & {
61
- params?: QueryParams;
200
+ type NdjsonOptions = {
201
+ /**
202
+ * Longest line accepted, in characters. A longer one rejects the iteration
203
+ * with a RangeError and cancels the body. Default 8 Mi.
204
+ */
205
+ maxLineLength?: number;
62
206
  };
63
- type RequestInitWithBody = RequestOptions & {
64
- method: string;
65
- body?: unknown;
207
+ type SseOptions = NdjsonOptions & {
208
+ /**
209
+ * Most `data` one event may collect before its blank line, in characters.
210
+ * More rejects the iteration with a RangeError and cancels the body.
211
+ * Default 8 Mi.
212
+ */
213
+ maxEventSize?: number;
214
+ };
215
+ /**
216
+ * The Standard Schema interface (https://standardschema.dev), vendored as
217
+ * types only so arthron keeps zero dependencies. Zod, Valibot, ArkType and
218
+ * others implement it, so their schemas can be passed to `.json(schema)`.
219
+ */
220
+ interface StandardSchemaV1<Input = unknown, Output = Input> {
221
+ readonly "~standard": {
222
+ readonly version: 1;
223
+ readonly vendor: string;
224
+ readonly validate: (value: unknown) => SchemaResult<Output> | Promise<SchemaResult<Output>>;
225
+ readonly types?: {
226
+ readonly input: Input;
227
+ readonly output: Output;
228
+ } | undefined;
229
+ };
230
+ }
231
+ type SchemaResult<Output> = {
232
+ readonly value: Output;
233
+ readonly issues?: undefined;
234
+ } | {
235
+ readonly issues: readonly SchemaIssue[];
66
236
  };
67
- type ArthronConfig = {
237
+ interface SchemaIssue {
238
+ readonly message: string;
239
+ readonly path?: readonly (PropertyKey | {
240
+ readonly key: PropertyKey;
241
+ })[] | undefined;
242
+ }
243
+ /** The type a schema produces. */
244
+ type InferOutput<S extends StandardSchemaV1> = NonNullable<S["~standard"]["types"]>["output"];
245
+ type ErrorDetailResolver = (data: unknown, response: Response) => string | undefined;
246
+ //#endregion
247
+ //#region src/client/client.types.d.ts
248
+ /**
249
+ * The methods arthron knows by name; any other string is sent as written.
250
+ * The standard ones go out uppercased whatever their case — fetch itself
251
+ * only normalizes six of them, so a lowercase "patch" would draw a 405.
252
+ */
253
+ type HttpMethod = "GET" | "HEAD" | "POST" | "PUT" | "PATCH" | "DELETE" | "OPTIONS" | "QUERY" | (string & {});
254
+ /**
255
+ * Per-call options. Public types are interfaces, so a plugin package can add
256
+ * its own options by augmentation (`declare module "arthron"`).
257
+ */
258
+ interface RequestOptions extends Omit<RequestInit, "body" | "method" | "headers"> {
259
+ /** Per-call headers; a `null`/`undefined` value drops a client default. */
260
+ headers?: HeadersOption;
261
+ params?: QueryParams;
262
+ /**
263
+ * Values for `{name}` placeholders in the path, each encoded into its own
264
+ * segment: `get("/users/{id}", { path: { id } })`. Interpolating ids into
265
+ * the path string yourself lets "../" or "?" escape the segment.
266
+ */
267
+ path?: Record<string, string | number>;
268
+ /** Settings for plugins on this call only (see `ArthronMeta`). Not sent. */
269
+ meta?: ArthronMeta;
270
+ /** Which non-ok responses reject on this call; overrides the client's `throwOn`. */
271
+ throwOn?: (res: Response) => boolean;
272
+ }
273
+ /** `request()`'s options: any method, with the same body rules as `post`. */
274
+ interface RequestInitWithBody extends RequestOptions {
275
+ method: HttpMethod;
276
+ body?: unknown;
277
+ }
278
+ /**
279
+ * The fetch options a client can set as defaults: the same `RequestInit`
280
+ * fields per-call options take, minus what only makes sense per call —
281
+ * `body`, `method`, `signal` (one client-wide signal, once aborted, would
282
+ * fail every later call) and `window`. `headers` has its own merge rules.
283
+ */
284
+ type FetchDefaults = Omit<RequestInit, "body" | "method" | "headers" | "signal" | "window">;
285
+ /**
286
+ * Client config. Besides arthron's own keys it takes any fetch option as a
287
+ * default (`credentials`, `cache`, `redirect`, `mode`, …), flat like per-call
288
+ * options; a per-call value wins.
289
+ */
290
+ interface ArthronConfig extends FetchDefaults {
68
291
  /** Prefix for relative paths. Without it only absolute URLs are accepted. */
69
292
  baseURL?: string;
70
- /** Default headers. Per-call headers win, compared case-insensitively. */
71
- headers?: HeadersInit;
72
- /** Forwarded to fetch as-is. Not set unless you set it. */
73
- credentials?: RequestCredentials;
293
+ /**
294
+ * Let an absolute URL on another origin than `baseURL` through. Off by
295
+ * default, so a path from user input or an API response cannot send the
296
+ * client's headers elsewhere; config `headers` are never sent to another
297
+ * origin even when this is on.
298
+ */
299
+ allowAbsoluteUrls?: boolean;
300
+ /** Default headers. Per-call headers win, compared case-insensitively; `extend` can drop one with `null`. */
301
+ headers?: HeadersOption;
74
302
  /** Injection point for tests and polyfills. Defaults to `globalThis.fetch`. */
75
303
  fetch?: typeof fetch;
76
304
  use?: Plugin[];
77
305
  /** How to pick a message out of an error body. */
78
- errorMessage?: ErrorMessageResolver;
79
- };
80
- type ArthronPromise = Promise<Response> & {
81
- json<T = unknown>(): Promise<T>;
82
- text(): Promise<string>;
83
- blob(): Promise<Blob>;
84
- arrayBuffer(): Promise<ArrayBuffer>;
85
- formData(): Promise<FormData>;
86
- };
87
- type Arthron = {
306
+ errorDetail?: ErrorDetailResolver;
307
+ /**
308
+ * Which non-ok responses reject with an ArthronError — return `false` to
309
+ * get the Response instead (a 404 that is data, say). An ok response never
310
+ * rejects. Default: every non-ok response except an opaque one
311
+ * (`mode: "no-cors"`) and the 3xx of `redirect: "manual"`.
312
+ */
313
+ throwOn?: (res: Response) => boolean;
314
+ }
315
+ interface Arthron {
88
316
  get(path: string, init?: RequestOptions): ArthronPromise;
89
317
  delete(path: string, init?: RequestOptions): ArthronPromise;
90
318
  head(path: string, init?: RequestOptions): ArthronPromise;
91
319
  post(path: string, body?: unknown, init?: RequestOptions): ArthronPromise;
92
320
  put(path: string, body?: unknown, init?: RequestOptions): ArthronPromise;
93
321
  patch(path: string, body?: unknown, init?: RequestOptions): ArthronPromise;
322
+ /** RFC 10008 QUERY: safe and idempotent like GET, but the query travels in the body. */
323
+ query(path: string, body?: unknown, init?: RequestOptions): ArthronPromise;
324
+ /** Any method — the extension point for verbs without their own helper. */
94
325
  request(path: string, init: RequestInitWithBody): ArthronPromise;
95
- /** New client with these plugins appended. The receiver is untouched. */
326
+ /**
327
+ * New client with these plugins added: a named one replaces the plugin of
328
+ * that name in place, an unnamed one appends. The receiver is untouched.
329
+ */
96
330
  use(...plugins: Plugin[]): Arthron;
97
- /** New client with config shallow-merged, headers merged, plugins appended. */
331
+ /** New client with config shallow-merged, headers merged, plugins added as `use` adds them. */
98
332
  extend(config: Partial<ArthronConfig>): Arthron;
99
- };
333
+ /** New client without the plugins of these names. The receiver is untouched. */
334
+ without(...names: string[]): Arthron;
335
+ }
100
336
  //#endregion
101
- //#region src/client.d.ts
337
+ //#region src/client/client.d.ts
102
338
  /**
103
339
  * Build a client from config. The result is immutable — `use` and `extend`
104
340
  * return new clients and never touch the one they were called on.
105
341
  */
106
342
  export declare function arthron(config?: ArthronConfig): Arthron;
107
343
  //#endregion
108
- //#region src/define.d.ts
344
+ //#region src/pipeline/define-plugin.d.ts
345
+ /** Identity helper: gives a middleware written in its own file the right parameter types. */
109
346
  export declare const defineMiddleware: (middleware: Middleware) => Middleware;
347
+ /** Identity helpers for each interceptor kind — `defineInterceptor.request(fn)` etc. */
110
348
  export declare const defineInterceptor: {
111
349
  request: (interceptor: RequestInterceptor) => RequestInterceptor;
112
350
  response: (interceptor: ResponseInterceptor) => ResponseInterceptor;
113
351
  error: (interceptor: ErrorInterceptor) => ErrorInterceptor;
114
352
  };
353
+ /** Identity helper: type-checks a plugin object literal without an annotation. */
115
354
  export declare const definePlugin: (plugin: Plugin) => Plugin;
116
355
  //#endregion
117
- //#region src/plugins/logging.d.ts
356
+ //#region src/plugins/logging/logging.types.d.ts
357
+ type LogEventBase = {
358
+ method: string;
359
+ path: string;
360
+ };
361
+ type LogEvent = ({
362
+ phase: "start";
363
+ } & LogEventBase) | ({
364
+ phase: "success";
365
+ status: number;
366
+ ms: number;
367
+ } & LogEventBase) | ({
368
+ phase: "error";
369
+ /** HTTP status for an ArthronError (0 = network); undefined for anything else. */
370
+ status: number | undefined;
371
+ ms: number;
372
+ error: unknown;
373
+ } & LogEventBase);
118
374
  type LoggingOptions = {
119
375
  /** Default `true`. The library never reads `NODE_ENV` — pass `isDev` yourself. */
120
376
  enabled?: boolean;
121
377
  logger?: Pick<Console, "log" | "error">;
378
+ /** Receive structured events instead of the default console lines. */
379
+ onEvent?: (event: LogEvent) => void;
122
380
  /** Clock in ms. Injectable for tests. */
123
381
  now?: () => number;
124
382
  };
383
+ //#endregion
384
+ //#region src/plugins/logging/logging.d.ts
125
385
  /**
126
- * One line when a request starts, one when it settles, with status and
386
+ * One event when a request starts, one when it settles, with status and
127
387
  * elapsed time. Wraps the whole call, so retries are included in the time.
128
- * The query string is dropped — it tends to carry tokens.
388
+ * Default output is a console line per event; pass `onEvent` to get the
389
+ * structured event instead. Cancellations are not reported.
129
390
  */
130
391
  export declare function logging(options?: LoggingOptions): Plugin;
131
392
  //#endregion
132
- //#region src/plugins/retry.d.ts
133
- type RetryOptions = {
134
- /** Number of retries after the first attempt. Default 2 (3 requests total). */
135
- retries?: number;
136
- /** Statuses worth retrying. Network errors (status 0) always are. */
137
- retryOn?: readonly number[];
138
- /** Methods safe to repeat. Compared case-insensitively. */
139
- methods?: readonly string[];
140
- /** Backoff in ms for retry number `retry` (0-based). Default 300 · 2^retry. */
141
- delay?: (retry: number, error: ArthronError) => number;
142
- /** Injectable for tests. Default `setTimeout`; rejects with the abort reason. */
143
- sleep?: (ms: number, signal?: AbortSignal | null) => Promise<void>;
144
- /**
145
- * Longest `Retry-After` (ms) worth honouring. Beyond it the request is not
146
- * retried at all. Default 60 000. Also guards `setTimeout`'s 2^31-1 ms cap,
147
- * past which timers fire immediately.
148
- */
149
- maxRetryAfter?: number;
150
- };
393
+ //#region src/plugins/retry/retry.d.ts
151
394
  /**
152
395
  * Retry on network errors and the configured statuses by calling `next`
153
396
  * again — the whole attempt (request interceptors included) is re-run.
154
397
  * Only `ArthronError` is considered; cancellation and plugin bugs pass through.
398
+ * A call can turn it off or override its options with `meta.retry`.
155
399
  */
156
400
  export declare function retry(options?: RetryOptions): Plugin;
157
401
  //#endregion
158
- export type { Arthron, ArthronConfig, ArthronPromise, ErrorInterceptor, ErrorMessageResolver, LoggingOptions, Middleware, Plugin, QueryParams, RequestContext, RequestInterceptor, RequestOptions, ResponseInterceptor, RetryOptions };
402
+ //#region src/plugins/timeout/timeout.types.d.ts
403
+ type TimeoutOptions = {
404
+ /**
405
+ * Also abort when no data has arrived for this many ms — while waiting for
406
+ * the headers and between body chunks. Unlike the total deadline, a stream
407
+ * that keeps flowing is never cut off: `timeout(Infinity, { idle: 30_000 })`.
408
+ */
409
+ idle?: number;
410
+ };
411
+ //#endregion
412
+ //#region src/plugins/timeout/timeout.d.ts
413
+ /**
414
+ * Abort the request when it takes longer than `ms` — counted from the start
415
+ * of the attempt until the body has been fully read, so a server that sends
416
+ * headers and then stalls still trips it. With `idle`, also abort once no
417
+ * data has arrived for that long. Rejects with a `TimeoutError` (a
418
+ * `DOMException`, like `AbortSignal.timeout()` would give); it is not an
419
+ * `ArthronError`, so error interceptors and `retry` leave it alone.
420
+ *
421
+ * A call can change the total deadline with `meta.timeout`.
422
+ *
423
+ * Deadlines are timers on an AbortController — not `AbortSignal.timeout`,
424
+ * since the idle one restarts — joined to the caller's signal with
425
+ * `AbortSignal.any`.
426
+ */
427
+ export declare function timeout(ms: number, options?: TimeoutOptions): Plugin;
428
+ //#endregion
429
+ //#region src/response/schema-validation.d.ts
430
+ /**
431
+ * `.json(schema)` got a body that does not match. Not an ArthronError: the
432
+ * request succeeded — the data is what is wrong.
433
+ */
434
+ export declare class SchemaError extends Error {
435
+ readonly name = "SchemaError";
436
+ /** Every problem the validator reported, with the path to it. */
437
+ readonly issues: readonly SchemaIssue[];
438
+ constructor(issues: readonly SchemaIssue[]);
439
+ }
440
+ //#endregion
441
+ export type { Arthron, ArthronConfig, ArthronMeta, ArthronPromise, ErrorDetailResolver, ErrorInterceptor, HeadersOption, HttpMethod, InferOutput, LogEvent, LoggingOptions, Middleware, NdjsonOptions, Plugin, QueryParams, RequestContext, RequestInitWithBody, RequestInterceptor, RequestOptions, ResponseInterceptor, RetryOptions, SchemaIssue, SseEvent, SseOptions, StandardSchemaV1, TimeoutOptions };
159
442
  //# sourceMappingURL=index.d.cts.map