@replanejs/sdk 0.8.19 → 0.9.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/README.md +78 -83
- package/dist/index.cjs +268 -262
- package/dist/index.d.cts +201 -184
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.ts +201 -184
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +267 -259
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -78,38 +78,42 @@ interface ReplaneSnapshot<_T extends object = object> {
|
|
|
78
78
|
value: unknown;
|
|
79
79
|
overrides: RenderedOverride[];
|
|
80
80
|
}>;
|
|
81
|
-
/** Default context used for override evaluation */
|
|
82
|
-
context?: ReplaneContext;
|
|
83
81
|
}
|
|
84
82
|
/**
|
|
85
|
-
*
|
|
83
|
+
* Options for the Replane constructor
|
|
86
84
|
*/
|
|
87
|
-
interface
|
|
88
|
-
/**
|
|
89
|
-
|
|
90
|
-
/** Subscribe to config changes.
|
|
91
|
-
* @param callback - A function to call when an config is changed. The callback will be called with the new config value.
|
|
92
|
-
* @returns A function to unsubscribe from the config changes.
|
|
85
|
+
interface ReplaneOptions<T extends object> {
|
|
86
|
+
/**
|
|
87
|
+
* Optional logger (defaults to console).
|
|
93
88
|
*/
|
|
94
|
-
|
|
95
|
-
/**
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
* @returns A function to unsubscribe from the config changes.
|
|
89
|
+
logger?: ReplaneLogger;
|
|
90
|
+
/**
|
|
91
|
+
* Default context for all config evaluations.
|
|
92
|
+
* Can be overridden per-request in `client.get()`.
|
|
99
93
|
*/
|
|
100
|
-
|
|
94
|
+
context?: ReplaneContext;
|
|
101
95
|
/**
|
|
102
|
-
*
|
|
103
|
-
*
|
|
96
|
+
* Default values to use before connection is established.
|
|
97
|
+
* These values are used immediately and can be overwritten by server data.
|
|
98
|
+
* @example
|
|
99
|
+
* {
|
|
100
|
+
* defaults: {
|
|
101
|
+
* config1: "value1",
|
|
102
|
+
* config2: 42,
|
|
103
|
+
* },
|
|
104
|
+
* }
|
|
104
105
|
*/
|
|
105
|
-
|
|
106
|
-
/**
|
|
107
|
-
|
|
106
|
+
defaults?: { [K in keyof T]?: T[K] };
|
|
107
|
+
/**
|
|
108
|
+
* Snapshot from a server-side client's getSnapshot() call.
|
|
109
|
+
* Used for SSR/hydration scenarios.
|
|
110
|
+
*/
|
|
111
|
+
snapshot?: ReplaneSnapshot<T>;
|
|
108
112
|
}
|
|
109
113
|
/**
|
|
110
|
-
* Options for
|
|
114
|
+
* Options for connecting to the Replane server
|
|
111
115
|
*/
|
|
112
|
-
interface
|
|
116
|
+
interface ConnectOptions {
|
|
113
117
|
/**
|
|
114
118
|
* Base URL of the Replane instance (no trailing slash).
|
|
115
119
|
* @example
|
|
@@ -126,24 +130,20 @@ interface ReplaneClientOptions<T extends object> {
|
|
|
126
130
|
*/
|
|
127
131
|
sdkKey: string;
|
|
128
132
|
/**
|
|
129
|
-
*
|
|
130
|
-
*/
|
|
131
|
-
fetchFn?: typeof fetch;
|
|
132
|
-
/**
|
|
133
|
-
* Optional timeout in ms for the request.
|
|
134
|
-
* @default 2000
|
|
135
|
-
*/
|
|
136
|
-
requestTimeoutMs?: number;
|
|
137
|
-
/**
|
|
138
|
-
* Optional timeout in ms for the SDK initialization.
|
|
133
|
+
* Optional timeout in ms for the initial connection.
|
|
139
134
|
* @default 5000
|
|
140
135
|
*/
|
|
141
|
-
|
|
136
|
+
connectTimeoutMs?: number;
|
|
142
137
|
/**
|
|
143
138
|
* Delay between retries in ms.
|
|
144
139
|
* @default 200
|
|
145
140
|
*/
|
|
146
141
|
retryDelayMs?: number;
|
|
142
|
+
/**
|
|
143
|
+
* Optional timeout in ms for individual requests.
|
|
144
|
+
* @default 2000
|
|
145
|
+
*/
|
|
146
|
+
requestTimeoutMs?: number;
|
|
147
147
|
/**
|
|
148
148
|
* Timeout in ms for SSE connection inactivity.
|
|
149
149
|
* If no events (including pings) are received within this time, the connection will be re-established.
|
|
@@ -151,181 +151,186 @@ interface ReplaneClientOptions<T extends object> {
|
|
|
151
151
|
*/
|
|
152
152
|
inactivityTimeoutMs?: number;
|
|
153
153
|
/**
|
|
154
|
-
*
|
|
155
|
-
*/
|
|
156
|
-
logger?: ReplaneLogger;
|
|
157
|
-
/**
|
|
158
|
-
* Default context for all config evaluations.
|
|
159
|
-
* Can be overridden per-request in `client.get()`.
|
|
160
|
-
*/
|
|
161
|
-
context?: ReplaneContext;
|
|
162
|
-
/**
|
|
163
|
-
* Required configs for the client.
|
|
164
|
-
* If a config is not present, the client will throw an error during initialization.
|
|
165
|
-
* @example
|
|
166
|
-
* {
|
|
167
|
-
* required: {
|
|
168
|
-
* config1: true,
|
|
169
|
-
* config2: true,
|
|
170
|
-
* config3: false,
|
|
171
|
-
* },
|
|
172
|
-
* }
|
|
173
|
-
*
|
|
174
|
-
* @example
|
|
175
|
-
* {
|
|
176
|
-
* required: ["config1", "config2", "config3"],
|
|
177
|
-
* }
|
|
178
|
-
*/
|
|
179
|
-
required?: { [K in keyof T]: boolean } | Array<keyof T>;
|
|
180
|
-
/**
|
|
181
|
-
* Default values to use if the initial request to fetch configs fails or times out.
|
|
182
|
-
* These values are used immediately while waiting for server connection.
|
|
183
|
-
* @example
|
|
184
|
-
* {
|
|
185
|
-
* defaults: {
|
|
186
|
-
* config1: "value1",
|
|
187
|
-
* config2: 42,
|
|
188
|
-
* },
|
|
189
|
-
* }
|
|
154
|
+
* Custom fetch implementation (useful for tests / polyfills).
|
|
190
155
|
*/
|
|
191
|
-
|
|
156
|
+
fetchFn?: typeof fetch;
|
|
192
157
|
/**
|
|
193
158
|
* Agent identifier sent in User-Agent header.
|
|
194
159
|
* Defaults to SDK identifier (e.g., "replane-js/x.y.z").
|
|
195
160
|
*/
|
|
196
161
|
agent?: string;
|
|
197
|
-
/**
|
|
198
|
-
* Callback invoked when a connection error occurs during SSE streaming.
|
|
199
|
-
* This is called on each retry attempt, useful for tracking connection health.
|
|
200
|
-
* The SDK will automatically retry connections, so this is informational.
|
|
201
|
-
* @param error - The error that caused the connection failure
|
|
202
|
-
*/
|
|
203
|
-
onConnectionError?: (error: unknown) => void;
|
|
204
|
-
/**
|
|
205
|
-
* Callback invoked when the SSE connection is successfully established.
|
|
206
|
-
* This is called on initial connection and on every successful reconnection.
|
|
207
|
-
* Useful for tracking connection health and reconnection metrics.
|
|
208
|
-
*/
|
|
209
|
-
onConnected?: () => void;
|
|
210
|
-
}
|
|
211
|
-
/**
|
|
212
|
-
* Options for restoring a Replane client from a snapshot
|
|
213
|
-
*/
|
|
214
|
-
interface RestoreReplaneClientOptions<T extends object> {
|
|
215
|
-
/**
|
|
216
|
-
* Snapshot from a server-side client's getSnapshot() call.
|
|
217
|
-
*/
|
|
218
|
-
snapshot: ReplaneSnapshot<T>;
|
|
219
|
-
/**
|
|
220
|
-
* Optional connection options for live updates.
|
|
221
|
-
* If provided, the client will connect to the Replane server for real-time config updates.
|
|
222
|
-
* If not provided, the client will only use the snapshot data (no live updates).
|
|
223
|
-
*/
|
|
224
|
-
connection?: {
|
|
225
|
-
/**
|
|
226
|
-
* Base URL of the Replane instance (no trailing slash).
|
|
227
|
-
*/
|
|
228
|
-
baseUrl: string;
|
|
229
|
-
/**
|
|
230
|
-
* Project SDK key for authorization.
|
|
231
|
-
*/
|
|
232
|
-
sdkKey: string;
|
|
233
|
-
/**
|
|
234
|
-
* Custom fetch implementation (useful for tests / polyfills).
|
|
235
|
-
*/
|
|
236
|
-
fetchFn?: typeof fetch;
|
|
237
|
-
/**
|
|
238
|
-
* Optional timeout in ms for the request.
|
|
239
|
-
* @default 2000
|
|
240
|
-
*/
|
|
241
|
-
requestTimeoutMs?: number;
|
|
242
|
-
/**
|
|
243
|
-
* Delay between retries in ms.
|
|
244
|
-
* @default 200
|
|
245
|
-
*/
|
|
246
|
-
retryDelayMs?: number;
|
|
247
|
-
/**
|
|
248
|
-
* Timeout in ms for SSE connection inactivity.
|
|
249
|
-
* @default 30000
|
|
250
|
-
*/
|
|
251
|
-
inactivityTimeoutMs?: number;
|
|
252
|
-
/**
|
|
253
|
-
* Optional logger (defaults to console).
|
|
254
|
-
*/
|
|
255
|
-
logger?: ReplaneLogger;
|
|
256
|
-
/**
|
|
257
|
-
* Agent identifier sent in User-Agent header.
|
|
258
|
-
* Defaults to SDK identifier (e.g., "replane-js/x.y.z").
|
|
259
|
-
*/
|
|
260
|
-
agent?: string;
|
|
261
|
-
/**
|
|
262
|
-
* Callback invoked when a connection error occurs during SSE streaming.
|
|
263
|
-
* This is called on each retry attempt, useful for tracking connection health.
|
|
264
|
-
* The SDK will automatically retry connections, so this is informational.
|
|
265
|
-
* @param error - The error that caused the connection failure
|
|
266
|
-
*/
|
|
267
|
-
onConnectionError?: (error: unknown) => void;
|
|
268
|
-
/**
|
|
269
|
-
* Callback invoked when the SSE connection is successfully established.
|
|
270
|
-
* This is called on initial connection and on every successful reconnection.
|
|
271
|
-
* Useful for tracking connection health and reconnection metrics.
|
|
272
|
-
*/
|
|
273
|
-
onConnected?: () => void;
|
|
274
|
-
};
|
|
275
|
-
/**
|
|
276
|
-
* Override the context from the snapshot.
|
|
277
|
-
*/
|
|
278
|
-
context?: ReplaneContext;
|
|
279
162
|
}
|
|
280
163
|
/**
|
|
281
|
-
* Internal options after processing
|
|
164
|
+
* Internal options after processing connect options
|
|
282
165
|
*/
|
|
283
166
|
//#endregion
|
|
284
167
|
//#region src/client.d.ts
|
|
285
168
|
/**
|
|
286
|
-
*
|
|
169
|
+
* The Replane client for managing dynamic configuration.
|
|
287
170
|
*
|
|
288
171
|
* @example
|
|
289
172
|
* ```typescript
|
|
290
|
-
*
|
|
291
|
-
*
|
|
292
|
-
*
|
|
173
|
+
* // Create client with defaults
|
|
174
|
+
* const client = new Replane({
|
|
175
|
+
* defaults: { myConfig: 'defaultValue' }
|
|
176
|
+
* });
|
|
177
|
+
*
|
|
178
|
+
* // Use immediately (returns defaults)
|
|
179
|
+
* const value = client.get('myConfig');
|
|
180
|
+
*
|
|
181
|
+
* // Connect for real-time updates
|
|
182
|
+
* await client.connect({
|
|
183
|
+
* baseUrl: 'https://app.replane.dev',
|
|
184
|
+
* sdkKey: 'your-sdk-key'
|
|
293
185
|
* });
|
|
294
|
-
* const value = client.get('my-config');
|
|
295
186
|
* ```
|
|
296
|
-
*/
|
|
297
|
-
declare function createReplaneClient<T extends object = Record<string, unknown>>(sdkOptions: ReplaneClientOptions<T>): Promise<ReplaneClient<T>>;
|
|
298
|
-
/**
|
|
299
|
-
* Create a Replane client that uses in-memory storage.
|
|
300
|
-
* Useful for testing or when you have static config values.
|
|
301
187
|
*
|
|
302
188
|
* @example
|
|
303
189
|
* ```typescript
|
|
304
|
-
*
|
|
305
|
-
* const
|
|
190
|
+
* // SSR/Hydration: Create from snapshot
|
|
191
|
+
* const client = new Replane({
|
|
192
|
+
* snapshot: serverSnapshot
|
|
193
|
+
* });
|
|
194
|
+
* await client.connect({ baseUrl, sdkKey });
|
|
306
195
|
* ```
|
|
307
|
-
*/
|
|
308
|
-
declare function createInMemoryReplaneClient<T extends object = Record<string, unknown>>(initialData: T): ReplaneClient<T>;
|
|
309
|
-
/**
|
|
310
|
-
* Restore a Replane client from a snapshot.
|
|
311
|
-
* This is useful for SSR/hydration scenarios where the server has already fetched configs.
|
|
312
196
|
*
|
|
313
197
|
* @example
|
|
314
198
|
* ```typescript
|
|
315
|
-
* //
|
|
316
|
-
* const
|
|
317
|
-
*
|
|
318
|
-
* // Pass snapshot to client via props/serialization
|
|
319
|
-
*
|
|
320
|
-
* // On the client:
|
|
321
|
-
* const client = restoreReplaneClient({
|
|
322
|
-
* snapshot,
|
|
323
|
-
* connection: { sdkKey, baseUrl }
|
|
199
|
+
* // In-memory mode (no connection)
|
|
200
|
+
* const client = new Replane({
|
|
201
|
+
* defaults: { feature: true, limit: 100 }
|
|
324
202
|
* });
|
|
325
|
-
*
|
|
203
|
+
* // Don't call connect() - works entirely in-memory
|
|
326
204
|
* ```
|
|
327
205
|
*/
|
|
328
|
-
declare
|
|
206
|
+
declare class Replane<T extends object = Record<string, unknown>> {
|
|
207
|
+
private configs;
|
|
208
|
+
private context;
|
|
209
|
+
private logger;
|
|
210
|
+
private storage;
|
|
211
|
+
private configSubscriptions;
|
|
212
|
+
private clientSubscriptions;
|
|
213
|
+
/**
|
|
214
|
+
* Create a new Replane client.
|
|
215
|
+
*
|
|
216
|
+
* The client is usable immediately after construction with defaults or snapshot data.
|
|
217
|
+
* Call `connect()` to establish a real-time connection for live updates.
|
|
218
|
+
*
|
|
219
|
+
* @param options - Configuration options
|
|
220
|
+
*/
|
|
221
|
+
constructor(options?: ReplaneOptions<T>);
|
|
222
|
+
/**
|
|
223
|
+
* Connect to the Replane server for real-time config updates.
|
|
224
|
+
*
|
|
225
|
+
* This method establishes an SSE connection to receive live config updates.
|
|
226
|
+
* If already connected, it will disconnect first and reconnect with new options.
|
|
227
|
+
*
|
|
228
|
+
* @param options - Connection options including baseUrl and sdkKey
|
|
229
|
+
* @returns Promise that resolves when the initial connection is established
|
|
230
|
+
* @throws {ReplaneError} If connection times out and no defaults are available
|
|
231
|
+
*
|
|
232
|
+
* @example
|
|
233
|
+
* ```typescript
|
|
234
|
+
* await client.connect({
|
|
235
|
+
* baseUrl: 'https://app.replane.dev',
|
|
236
|
+
* sdkKey: 'rp_xxx'
|
|
237
|
+
* });
|
|
238
|
+
* ```
|
|
239
|
+
*/
|
|
240
|
+
connect(options: ConnectOptions): Promise<void>;
|
|
241
|
+
/**
|
|
242
|
+
* Disconnect from the Replane server.
|
|
243
|
+
*
|
|
244
|
+
* Stops the SSE connection and cleans up resources.
|
|
245
|
+
* The client remains usable with cached config values.
|
|
246
|
+
* Can call `connect()` again to reconnect.
|
|
247
|
+
*/
|
|
248
|
+
disconnect(): void;
|
|
249
|
+
/**
|
|
250
|
+
* Get a config value by name.
|
|
251
|
+
*
|
|
252
|
+
* Evaluates any overrides based on the client context and per-call context.
|
|
253
|
+
*
|
|
254
|
+
* @param configName - The name of the config to retrieve
|
|
255
|
+
* @param options - Optional settings for this call
|
|
256
|
+
* @returns The config value
|
|
257
|
+
* @throws {ReplaneError} If config not found and no default provided
|
|
258
|
+
*
|
|
259
|
+
* @example
|
|
260
|
+
* ```typescript
|
|
261
|
+
* // Simple get
|
|
262
|
+
* const value = client.get('myConfig');
|
|
263
|
+
*
|
|
264
|
+
* // With default fallback
|
|
265
|
+
* const value = client.get('myConfig', { default: 'fallback' });
|
|
266
|
+
*
|
|
267
|
+
* // With per-call context for override evaluation
|
|
268
|
+
* const value = client.get('myConfig', { context: { userId: '123' } });
|
|
269
|
+
* ```
|
|
270
|
+
*/
|
|
271
|
+
get<K extends keyof T>(configName: K, options?: GetConfigOptions<T[K]>): T[K];
|
|
272
|
+
/**
|
|
273
|
+
* Subscribe to config changes.
|
|
274
|
+
*
|
|
275
|
+
* @param callback - Function called when any config changes
|
|
276
|
+
* @returns Unsubscribe function
|
|
277
|
+
*
|
|
278
|
+
* @example
|
|
279
|
+
* ```typescript
|
|
280
|
+
* const unsubscribe = client.subscribe((change) => {
|
|
281
|
+
* console.log(`Config ${change.name} changed to ${change.value}`);
|
|
282
|
+
* });
|
|
283
|
+
*
|
|
284
|
+
* // Later: stop listening
|
|
285
|
+
* unsubscribe();
|
|
286
|
+
* ```
|
|
287
|
+
*/
|
|
288
|
+
subscribe(callback: (config: MapConfig<T>) => void): () => void;
|
|
289
|
+
/**
|
|
290
|
+
* Subscribe to a specific config's changes.
|
|
291
|
+
*
|
|
292
|
+
* @param configName - The config to watch
|
|
293
|
+
* @param callback - Function called when the config changes
|
|
294
|
+
* @returns Unsubscribe function
|
|
295
|
+
*
|
|
296
|
+
* @example
|
|
297
|
+
* ```typescript
|
|
298
|
+
* const unsubscribe = client.subscribe('myConfig', (change) => {
|
|
299
|
+
* console.log(`myConfig changed to ${change.value}`);
|
|
300
|
+
* });
|
|
301
|
+
* ```
|
|
302
|
+
*/
|
|
303
|
+
subscribe<K extends keyof T>(configName: K, callback: (config: {
|
|
304
|
+
name: K;
|
|
305
|
+
value: T[K];
|
|
306
|
+
}) => void): () => void;
|
|
307
|
+
/**
|
|
308
|
+
* Get a serializable snapshot of the current client state.
|
|
309
|
+
*
|
|
310
|
+
* Useful for SSR/hydration scenarios where you want to pass
|
|
311
|
+
* configs from server to client.
|
|
312
|
+
*
|
|
313
|
+
* @returns Snapshot object that can be serialized to JSON
|
|
314
|
+
*
|
|
315
|
+
* @example
|
|
316
|
+
* ```typescript
|
|
317
|
+
* // On server
|
|
318
|
+
* const snapshot = client.getSnapshot();
|
|
319
|
+
* const json = JSON.stringify(snapshot);
|
|
320
|
+
*
|
|
321
|
+
* // On client
|
|
322
|
+
* const client = new Replane({ snapshot: JSON.parse(json) });
|
|
323
|
+
* ```
|
|
324
|
+
*/
|
|
325
|
+
getSnapshot(): ReplaneSnapshot<T>;
|
|
326
|
+
/**
|
|
327
|
+
* Check if the client is currently connected.
|
|
328
|
+
*/
|
|
329
|
+
get isConnected(): boolean;
|
|
330
|
+
private startStreaming;
|
|
331
|
+
private processConfigUpdates;
|
|
332
|
+
private toFinalOptions;
|
|
333
|
+
}
|
|
329
334
|
//# sourceMappingURL=client.d.ts.map
|
|
330
335
|
//#endregion
|
|
331
336
|
//#region src/error.d.ts
|
|
@@ -359,15 +364,27 @@ declare class ReplaneError extends Error {
|
|
|
359
364
|
//#endregion
|
|
360
365
|
//#region src/snapshot.d.ts
|
|
361
366
|
/**
|
|
362
|
-
*
|
|
367
|
+
* Options for getReplaneSnapshot with caching support.
|
|
363
368
|
*/
|
|
364
|
-
interface GetReplaneSnapshotOptions<T extends object> extends
|
|
369
|
+
interface GetReplaneSnapshotOptions<T extends object> extends ConnectOptions {
|
|
365
370
|
/**
|
|
366
371
|
* Cache TTL in milliseconds. When set, the client is cached and reused
|
|
367
372
|
* for instant subsequent calls within this duration.
|
|
368
373
|
* @default 60_000 (1 minute)
|
|
369
374
|
*/
|
|
370
375
|
keepAliveMs?: number;
|
|
376
|
+
/**
|
|
377
|
+
* Optional logger (defaults to console).
|
|
378
|
+
*/
|
|
379
|
+
logger?: ReplaneLogger;
|
|
380
|
+
/**
|
|
381
|
+
* Default context for all config evaluations.
|
|
382
|
+
*/
|
|
383
|
+
context?: ReplaneContext;
|
|
384
|
+
/**
|
|
385
|
+
* Default values to use if the initial request to fetch configs fails or times out.
|
|
386
|
+
*/
|
|
387
|
+
defaults?: { [K in keyof T]?: T[K] };
|
|
371
388
|
}
|
|
372
389
|
/**
|
|
373
390
|
* Creates a Replane client and returns a snapshot.
|
|
@@ -389,5 +406,5 @@ declare function getReplaneSnapshot<T extends object>(options: GetReplaneSnapsho
|
|
|
389
406
|
*/
|
|
390
407
|
|
|
391
408
|
//#endregion
|
|
392
|
-
export { type
|
|
409
|
+
export { type ConnectOptions, type GetConfigOptions, type GetReplaneSnapshotOptions, Replane, type ReplaneContext, ReplaneError, ReplaneErrorCode, type ReplaneLogger, type ReplaneOptions, type ReplaneSnapshot, getReplaneSnapshot };
|
|
393
410
|
//# sourceMappingURL=index.d.cts.map
|
package/dist/index.d.cts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.cts","names":[],"sources":["../src/types.ts","../src/client-types.ts","../src/client.ts","../src/error.ts","../src/snapshot.ts"],"sourcesContent":[],"mappings":";;UAqBU,iBAAA;;ECfE,QAAA,EAAA,MAAA;EAKK,KAAA,EAAA,OAAA;AAUjB;UDaU,qBAAA,CCbuB;EAAA,QAIrB,EAAA,cAAA;EAAc,QAKd,EAAA,MAAA;EAAC,cAAA,EAAA,MAAA;EAMD,YAAS,EAAA,MAAA;EAAA,IAAA,EAAA,MAAA;;UDMX,YAAA,CCJA;EAAC,QACA,EAAA,KAAA;EAAC,UAAC,EDKC,iBCLD,EAAA;;AAEJ,UDMC,WAAA,CCND;EAMQ,QAAA,EAAA,IAAA;EAAe,UAAA,EDElB,iBCFkB,EAAA;;UDKtB,YAAA,CCHC;EAAK,
|
|
1
|
+
{"version":3,"file":"index.d.cts","names":[],"sources":["../src/types.ts","../src/client-types.ts","../src/client.ts","../src/error.ts","../src/snapshot.ts"],"sourcesContent":[],"mappings":";;UAqBU,iBAAA;;ECfE,QAAA,EAAA,MAAA;EAKK,KAAA,EAAA,OAAA;AAUjB;UDaU,qBAAA,CCbuB;EAAA,QAIrB,EAAA,cAAA;EAAc,QAKd,EAAA,MAAA;EAAC,cAAA,EAAA,MAAA;EAMD,YAAS,EAAA,MAAA;EAAA,IAAA,EAAA,MAAA;;UDMX,YAAA,CCJA;EAAC,QACA,EAAA,KAAA;EAAC,UAAC,EDKC,iBCLD,EAAA;;AAEJ,UDMC,WAAA,CCND;EAMQ,QAAA,EAAA,IAAA;EAAe,UAAA,EDElB,iBCFkB,EAAA;;UDKtB,YAAA,CCHC;EAAK,QAAA,EAAA,KAAA;EAUC,SAAA,EDLJ,iBCKkB;;AAIpB,KDNC,iBAAA,GACR,iBCKO,GDJP,qBCIO,GDHP,YCGO,GDFP,WCEO,GDDP,YCCO;AAKC,UDJK,gBAAA,CCIL;EAAc,IAaV,EAAA,MAAA;EAAC,UAAI,EDfP,iBCeO,EAAA;EAAC,KAAC,EAAA,OAAA;;;;AD9DjB;AAEqB;AAaI;AAUA;AAQrB,KC9CE,cAAA,GAAiB,MDgDhB,CAAA,MAAA,EAAA,MAAiB,GAAA,MAAA,GAAA,OAAA,GAAA,IAAA,GAAA,SAAA,CAAA;AAG9B;;;AAEI,UChDa,aAAA,CDgDb;EAAqB,KACrB,CAAA,GAAA,IAAA,EAAA,OAAA,EAAA,CAAA,EAAA,IAAA;EAAY,IACZ,CAAA,GAAA,IAAA,EAAA,OAAA,EAAA,CAAA,EAAA,IAAA;EAAW,IACX,CAAA,GAAA,IAAA,EAAA,OAAA,EAAA,CAAA,EAAA,IAAA;EAAY,KAAA,CAAA,GAAA,IAAA,EAAA,OAAA,EAAA,CAAA,EAAA,IAAA;AAEhB;;;;AC1DY,UAeK,gBAfY,CAAA,CAAA,CAAA,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