@sats-connect/core 0.15.0-aec2448 → 0.16.0-2dd02aa

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.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  // src/request/index.ts
2
- import * as v55 from "valibot";
2
+ import * as v48 from "valibot";
3
3
 
4
4
  // src/provider/types.ts
5
5
  import * as v4 from "valibot";
@@ -242,973 +242,961 @@ var sanitizeAddressPurposeRequest = (method, params) => {
242
242
  return { method, params };
243
243
  };
244
244
 
245
- // src/request/types/btcMethods.ts
246
- import * as v20 from "valibot";
245
+ // src/request/types/btcMethods/common.ts
246
+ var MessageSigningProtocols = /* @__PURE__ */ ((MessageSigningProtocols2) => {
247
+ MessageSigningProtocols2["ECDSA"] = "ECDSA";
248
+ MessageSigningProtocols2["BIP322"] = "BIP322";
249
+ return MessageSigningProtocols2;
250
+ })(MessageSigningProtocols || {});
247
251
 
248
- // src/request/types/walletMethods/addNetwork.ts
252
+ // src/request/types/btcMethods/getAccounts.ts
249
253
  import * as v5 from "valibot";
250
- var addNetworkMethodName = "wallet_addNetwork";
251
- var addNetworkParamsSchema = v5.variant("chain", [
252
- v5.object({
253
- chain: v5.literal("bitcoin"),
254
- type: v5.enum(BitcoinNetworkType),
255
- name: v5.string(),
256
- rpcUrl: v5.string(),
257
- rpcFallbackUrl: v5.optional(v5.string()),
258
- indexerUrl: v5.optional(v5.string()),
259
- blockExplorerUrl: v5.optional(v5.string()),
260
- switch: v5.optional(v5.boolean())
261
- }),
262
- v5.object({
263
- chain: v5.literal("stacks"),
264
- name: v5.string(),
265
- type: v5.enum(StacksNetworkType),
266
- rpcUrl: v5.string(),
267
- blockExplorerUrl: v5.optional(v5.string()),
268
- switch: v5.optional(v5.boolean())
269
- }),
254
+ var getAccountsMethodName = "getAccounts";
255
+ var getAccountsParamsSchema = v5.object({
256
+ /**
257
+ * The purposes for which to generate addresses. See
258
+ * {@linkcode AddressPurpose} for available purposes.
259
+ */
260
+ purposes: v5.array(v5.enum(AddressPurpose)),
261
+ /**
262
+ * A message to be displayed to the user in the request prompt.
263
+ */
264
+ message: v5.optional(v5.string())
265
+ });
266
+ var getAccountsResultSchema = v5.array(
270
267
  v5.object({
271
- chain: v5.literal("starknet"),
272
- name: v5.string(),
273
- type: v5.enum(StarknetNetworkType),
274
- rpcUrl: v5.string(),
275
- blockExplorerUrl: v5.optional(v5.string()),
276
- switch: v5.optional(v5.boolean())
268
+ ...addressSchema.entries,
269
+ ...v5.object({
270
+ walletType: walletTypeSchema
271
+ }).entries
277
272
  })
278
- ]);
279
- var addNetworkRequestMessageSchema = v5.object({
273
+ );
274
+ var getAccountsRequestMessageSchema = v5.object({
280
275
  ...rpcRequestMessageSchema.entries,
281
276
  ...v5.object({
282
- method: v5.literal(addNetworkMethodName),
283
- params: addNetworkParamsSchema,
277
+ method: v5.literal(getAccountsMethodName),
278
+ params: getAccountsParamsSchema,
284
279
  id: v5.string()
285
280
  }).entries
286
281
  });
287
- var addNetworkResultSchema = v5.object({
288
- id: v5.string()
289
- });
290
282
 
291
- // src/request/types/walletMethods/changeNetwork.ts
283
+ // src/request/types/btcMethods/getAddresses.ts
284
+ import * as v7 from "valibot";
285
+
286
+ // src/request/types/walletMethods.ts
292
287
  import * as v6 from "valibot";
293
- var changeNetworkMethodName = "wallet_changeNetwork";
294
- var changeNetworkParamsSchema = v6.object({
295
- name: v6.enum(BitcoinNetworkType)
288
+ var accountActionsSchema = v6.object({
289
+ read: v6.optional(v6.boolean())
296
290
  });
297
- var changeNetworkResultSchema = v6.nullish(v6.null());
298
- var changeNetworkRequestMessageSchema = v6.object({
291
+ var walletActionsSchema = v6.object({
292
+ readNetwork: v6.optional(v6.boolean())
293
+ });
294
+ var accountPermissionSchema = v6.object({
295
+ type: v6.literal("account"),
296
+ resourceId: v6.string(),
297
+ clientId: v6.string(),
298
+ actions: accountActionsSchema
299
+ });
300
+ var walletPermissionSchema = v6.object({
301
+ type: v6.literal("wallet"),
302
+ resourceId: v6.string(),
303
+ clientId: v6.string(),
304
+ actions: walletActionsSchema
305
+ });
306
+ var PermissionRequestParams = v6.variant("type", [
307
+ v6.object({
308
+ ...v6.omit(accountPermissionSchema, ["clientId"]).entries
309
+ }),
310
+ v6.object({
311
+ ...v6.omit(walletPermissionSchema, ["clientId"]).entries
312
+ })
313
+ ]);
314
+ var permission = v6.variant("type", [accountPermissionSchema, walletPermissionSchema]);
315
+ var requestPermissionsMethodName = "wallet_requestPermissions";
316
+ var requestPermissionsParamsSchema = v6.nullish(v6.array(PermissionRequestParams));
317
+ var requestPermissionsResultSchema = v6.literal(true);
318
+ var requestPermissionsRequestMessageSchema = v6.object({
299
319
  ...rpcRequestMessageSchema.entries,
300
320
  ...v6.object({
301
- method: v6.literal(changeNetworkMethodName),
302
- params: changeNetworkParamsSchema,
321
+ method: v6.literal(requestPermissionsMethodName),
322
+ params: requestPermissionsParamsSchema,
303
323
  id: v6.string()
304
324
  }).entries
305
325
  });
306
-
307
- // src/request/types/walletMethods/changeNetworkById.ts
308
- import * as v7 from "valibot";
309
- var changeNetworkByIdMethodName = "wallet_changeNetworkById";
310
- var changeNetworkByIdParamsSchema = v7.object({
311
- id: v7.string()
312
- });
313
- var changeNetworkByIdResultSchema = v7.nullish(v7.null());
314
- var changeNetworkByIdRequestMessageSchema = v7.object({
326
+ var renouncePermissionsMethodName = "wallet_renouncePermissions";
327
+ var renouncePermissionsParamsSchema = v6.nullish(v6.null());
328
+ var renouncePermissionsResultSchema = v6.nullish(v6.null());
329
+ var renouncePermissionsRequestMessageSchema = v6.object({
315
330
  ...rpcRequestMessageSchema.entries,
316
- ...v7.object({
317
- method: v7.literal(changeNetworkByIdMethodName),
318
- params: changeNetworkByIdParamsSchema,
319
- id: v7.string()
331
+ ...v6.object({
332
+ method: v6.literal(renouncePermissionsMethodName),
333
+ params: renouncePermissionsParamsSchema,
334
+ id: v6.string()
320
335
  }).entries
321
336
  });
322
-
323
- // src/request/types/walletMethods/common.ts
324
- import * as v8 from "valibot";
325
- var accountActionsSchema = v8.object({
326
- read: v8.optional(v8.boolean())
327
- });
328
- var walletActionsSchema = v8.object({
329
- readNetwork: v8.optional(v8.boolean())
337
+ var disconnectMethodName = "wallet_disconnect";
338
+ var disconnectParamsSchema = v6.nullish(v6.null());
339
+ var disconnectResultSchema = v6.nullish(v6.null());
340
+ var disconnectRequestMessageSchema = v6.object({
341
+ ...rpcRequestMessageSchema.entries,
342
+ ...v6.object({
343
+ method: v6.literal(disconnectMethodName),
344
+ params: disconnectParamsSchema,
345
+ id: v6.string()
346
+ }).entries
330
347
  });
331
- var accountPermissionSchema = v8.object({
332
- type: v8.literal("account"),
333
- resourceId: v8.string(),
334
- clientId: v8.string(),
335
- actions: accountActionsSchema
348
+ var getWalletTypeMethodName = "wallet_getWalletType";
349
+ var getWalletTypeParamsSchema = v6.nullish(v6.null());
350
+ var getWalletTypeResultSchema = walletTypeSchema;
351
+ var getWalletTypeRequestMessageSchema = v6.object({
352
+ ...rpcRequestMessageSchema.entries,
353
+ ...v6.object({
354
+ method: v6.literal(getWalletTypeMethodName),
355
+ params: getWalletTypeParamsSchema,
356
+ id: v6.string()
357
+ }).entries
336
358
  });
337
- var walletPermissionSchema = v8.object({
338
- type: v8.literal("wallet"),
339
- resourceId: v8.string(),
340
- clientId: v8.string(),
341
- actions: walletActionsSchema
359
+ var getCurrentPermissionsMethodName = "wallet_getCurrentPermissions";
360
+ var getCurrentPermissionsParamsSchema = v6.nullish(v6.null());
361
+ var getCurrentPermissionsResultSchema = v6.array(permission);
362
+ var getCurrentPermissionsRequestMessageSchema = v6.object({
363
+ ...rpcRequestMessageSchema.entries,
364
+ ...v6.object({
365
+ method: v6.literal(getCurrentPermissionsMethodName),
366
+ params: getCurrentPermissionsParamsSchema,
367
+ id: v6.string()
368
+ }).entries
342
369
  });
343
- var PermissionRequestParams = v8.variant("type", [
344
- v8.object({
345
- ...v8.omit(accountPermissionSchema, ["clientId"]).entries
346
- }),
347
- v8.object({
348
- ...v8.omit(walletPermissionSchema, ["clientId"]).entries
349
- })
350
- ]);
351
- var permission = v8.variant("type", [accountPermissionSchema, walletPermissionSchema]);
352
-
353
- // src/request/types/walletMethods/connect.ts
354
- import * as v10 from "valibot";
355
-
356
- // src/request/types/walletMethods/getNetwork.ts
357
- import * as v9 from "valibot";
358
370
  var getNetworkMethodName = "wallet_getNetwork";
359
- var getNetworkParamsSchema = v9.nullish(v9.null());
360
- var getNetworkResultSchema = v9.object({
361
- bitcoin: v9.object({
362
- name: v9.enum(BitcoinNetworkType)
371
+ var getNetworkParamsSchema = v6.nullish(v6.null());
372
+ var getNetworkResultSchema = v6.object({
373
+ bitcoin: v6.object({
374
+ name: v6.enum(BitcoinNetworkType)
363
375
  }),
364
- stacks: v9.object({
365
- name: v9.enum(StacksNetworkType)
376
+ stacks: v6.object({
377
+ name: v6.enum(StacksNetworkType)
366
378
  }),
367
- spark: v9.object({
368
- name: v9.enum(SparkNetworkType)
379
+ spark: v6.object({
380
+ name: v6.enum(SparkNetworkType)
369
381
  })
370
382
  });
371
- var getNetworkRequestMessageSchema = v9.object({
383
+ var getNetworkRequestMessageSchema = v6.object({
372
384
  ...rpcRequestMessageSchema.entries,
373
- ...v9.object({
374
- method: v9.literal(getNetworkMethodName),
385
+ ...v6.object({
386
+ method: v6.literal(getNetworkMethodName),
375
387
  params: getNetworkParamsSchema,
376
- id: v9.string()
388
+ id: v6.string()
377
389
  }).entries
378
390
  });
379
-
380
- // src/request/types/walletMethods/connect.ts
381
- var connectMethodName = "wallet_connect";
382
- var connectParamsSchema = v10.nullish(
383
- v10.object({
384
- permissions: v10.optional(v10.array(PermissionRequestParams)),
385
- addresses: v10.optional(v10.array(v10.enum(AddressPurpose))),
386
- message: v10.optional(
387
- v10.pipe(v10.string(), v10.maxLength(80, "The message must not exceed 80 characters."))
388
- ),
389
- network: v10.optional(v10.enum(BitcoinNetworkType))
390
- })
391
- );
392
- var connectResultSchema = v10.object({
393
- id: v10.string(),
394
- addresses: v10.array(addressSchema),
395
- walletType: walletTypeSchema,
396
- network: getNetworkResultSchema
391
+ var changeNetworkMethodName = "wallet_changeNetwork";
392
+ var changeNetworkParamsSchema = v6.object({
393
+ name: v6.enum(BitcoinNetworkType)
397
394
  });
398
- var connectRequestMessageSchema = v10.object({
395
+ var changeNetworkResultSchema = v6.nullish(v6.null());
396
+ var changeNetworkRequestMessageSchema = v6.object({
399
397
  ...rpcRequestMessageSchema.entries,
400
- ...v10.object({
401
- method: v10.literal(connectMethodName),
402
- params: connectParamsSchema,
403
- id: v10.string()
398
+ ...v6.object({
399
+ method: v6.literal(changeNetworkMethodName),
400
+ params: changeNetworkParamsSchema,
401
+ id: v6.string()
404
402
  }).entries
405
403
  });
406
-
407
- // src/request/types/walletMethods/disconnect.ts
408
- import * as v11 from "valibot";
409
- var disconnectMethodName = "wallet_disconnect";
410
- var disconnectParamsSchema = v11.nullish(v11.null());
411
- var disconnectResultSchema = v11.nullish(v11.null());
412
- var disconnectRequestMessageSchema = v11.object({
404
+ var changeNetworkByIdMethodName = "wallet_changeNetworkById";
405
+ var changeNetworkByIdParamsSchema = v6.object({
406
+ id: v6.string()
407
+ });
408
+ var changeNetworkByIdResultSchema = v6.nullish(v6.null());
409
+ var changeNetworkByIdRequestMessageSchema = v6.object({
413
410
  ...rpcRequestMessageSchema.entries,
414
- ...v11.object({
415
- method: v11.literal(disconnectMethodName),
416
- params: disconnectParamsSchema,
417
- id: v11.string()
411
+ ...v6.object({
412
+ method: v6.literal(changeNetworkByIdMethodName),
413
+ params: changeNetworkByIdParamsSchema,
414
+ id: v6.string()
418
415
  }).entries
419
416
  });
420
-
421
- // src/request/types/walletMethods/getAccount.ts
422
- import * as v12 from "valibot";
423
417
  var getAccountMethodName = "wallet_getAccount";
424
- var getAccountParamsSchema = v12.nullish(v12.null());
425
- var getAccountResultSchema = v12.object({
426
- id: v12.string(),
427
- addresses: v12.array(addressSchema),
418
+ var getAccountParamsSchema = v6.nullish(v6.null());
419
+ var getAccountResultSchema = v6.object({
420
+ id: v6.string(),
421
+ addresses: v6.array(addressSchema),
428
422
  walletType: walletTypeSchema,
429
423
  network: getNetworkResultSchema
430
424
  });
431
- var getAccountRequestMessageSchema = v12.object({
425
+ var getAccountRequestMessageSchema = v6.object({
432
426
  ...rpcRequestMessageSchema.entries,
433
- ...v12.object({
434
- method: v12.literal(getAccountMethodName),
427
+ ...v6.object({
428
+ method: v6.literal(getAccountMethodName),
435
429
  params: getAccountParamsSchema,
436
- id: v12.string()
430
+ id: v6.string()
437
431
  }).entries
438
432
  });
439
-
440
- // src/request/types/walletMethods/getCurrentPermissions.ts
441
- import * as v13 from "valibot";
442
- var getCurrentPermissionsMethodName = "wallet_getCurrentPermissions";
443
- var getCurrentPermissionsParamsSchema = v13.nullish(v13.null());
444
- var getCurrentPermissionsResultSchema = v13.array(permission);
445
- var getCurrentPermissionsRequestMessageSchema = v13.object({
446
- ...rpcRequestMessageSchema.entries,
447
- ...v13.object({
448
- method: v13.literal(getCurrentPermissionsMethodName),
449
- params: getCurrentPermissionsParamsSchema,
450
- id: v13.string()
451
- }).entries
433
+ var connectMethodName = "wallet_connect";
434
+ var connectParamsSchema = v6.nullish(
435
+ v6.object({
436
+ permissions: v6.optional(v6.array(PermissionRequestParams)),
437
+ addresses: v6.optional(v6.array(v6.enum(AddressPurpose))),
438
+ message: v6.optional(
439
+ v6.pipe(v6.string(), v6.maxLength(80, "The message must not exceed 80 characters."))
440
+ ),
441
+ network: v6.optional(v6.enum(BitcoinNetworkType))
442
+ })
443
+ );
444
+ var connectResultSchema = v6.object({
445
+ id: v6.string(),
446
+ addresses: v6.array(addressSchema),
447
+ walletType: walletTypeSchema,
448
+ network: getNetworkResultSchema
452
449
  });
453
-
454
- // src/request/types/walletMethods/getWalletType.ts
455
- import * as v14 from "valibot";
456
- var getWalletTypeMethodName = "wallet_getWalletType";
457
- var getWalletTypeParamsSchema = v14.nullish(v14.null());
458
- var getWalletTypeResultSchema = walletTypeSchema;
459
- var getWalletTypeRequestMessageSchema = v14.object({
450
+ var connectRequestMessageSchema = v6.object({
460
451
  ...rpcRequestMessageSchema.entries,
461
- ...v14.object({
462
- method: v14.literal(getWalletTypeMethodName),
463
- params: getWalletTypeParamsSchema,
464
- id: v14.string()
452
+ ...v6.object({
453
+ method: v6.literal(connectMethodName),
454
+ params: connectParamsSchema,
455
+ id: v6.string()
465
456
  }).entries
466
457
  });
467
-
468
- // src/request/types/walletMethods/openBridge.ts
469
- import * as v15 from "valibot";
470
- var openBridgeMethodName = "wallet_openBridge";
471
- var openBridgeParamsSchema = v15.object({
472
- fromAsset: v15.string(),
473
- toAsset: v15.string()
474
- });
475
- var openBridgeResultSchema = v15.nullish(v15.null());
476
- var openBridgeRequestMessageSchema = v15.object({
458
+ var addNetworkMethodName = "wallet_addNetwork";
459
+ var addNetworkParamsSchema = v6.variant("chain", [
460
+ v6.object({
461
+ chain: v6.literal("bitcoin"),
462
+ type: v6.enum(BitcoinNetworkType),
463
+ name: v6.string(),
464
+ rpcUrl: v6.string(),
465
+ rpcFallbackUrl: v6.optional(v6.string()),
466
+ indexerUrl: v6.optional(v6.string()),
467
+ blockExplorerUrl: v6.optional(v6.string()),
468
+ switch: v6.optional(v6.boolean())
469
+ }),
470
+ v6.object({
471
+ chain: v6.literal("stacks"),
472
+ name: v6.string(),
473
+ type: v6.enum(StacksNetworkType),
474
+ rpcUrl: v6.string(),
475
+ blockExplorerUrl: v6.optional(v6.string()),
476
+ switch: v6.optional(v6.boolean())
477
+ }),
478
+ v6.object({
479
+ chain: v6.literal("starknet"),
480
+ name: v6.string(),
481
+ type: v6.enum(StarknetNetworkType),
482
+ rpcUrl: v6.string(),
483
+ blockExplorerUrl: v6.optional(v6.string()),
484
+ switch: v6.optional(v6.boolean())
485
+ })
486
+ ]);
487
+ var addNetworkRequestMessageSchema = v6.object({
477
488
  ...rpcRequestMessageSchema.entries,
478
- ...v15.object({
479
- method: v15.literal(openBridgeMethodName),
480
- params: openBridgeParamsSchema,
481
- id: v15.string()
489
+ ...v6.object({
490
+ method: v6.literal(addNetworkMethodName),
491
+ params: addNetworkParamsSchema,
492
+ id: v6.string()
482
493
  }).entries
483
494
  });
484
-
485
- // src/request/types/walletMethods/openBuy.ts
486
- import * as v16 from "valibot";
487
- var openBuyMethodName = "wallet_openBuy";
488
- var openBuyParamsSchema = v16.object({
489
- asset: v16.string()
490
- });
491
- var openBuyResultSchema = v16.nullish(v16.null());
492
- var openBuyRequestMessageSchema = v16.object({
493
- ...rpcRequestMessageSchema.entries,
494
- ...v16.object({
495
- method: v16.literal(openBuyMethodName),
496
- params: openBuyParamsSchema,
497
- id: v16.string()
498
- }).entries
495
+ var addNetworkResultSchema = v6.object({
496
+ id: v6.string()
499
497
  });
500
498
 
501
- // src/request/types/walletMethods/openReceive.ts
502
- import * as v17 from "valibot";
503
- var openReceiveMethodName = "wallet_openReceive";
504
- var openReceiveParamsSchema = v17.object({
505
- address: v17.string()
499
+ // src/request/types/btcMethods/getAddresses.ts
500
+ var getAddressesMethodName = "getAddresses";
501
+ var getAddressesParamsSchema = v7.object({
502
+ /**
503
+ * The purposes for which to generate addresses. See
504
+ * {@linkcode AddressPurpose} for available purposes.
505
+ */
506
+ purposes: v7.array(v7.enum(AddressPurpose)),
507
+ /**
508
+ * A message to be displayed to the user in the request prompt.
509
+ */
510
+ message: v7.optional(v7.string())
506
511
  });
507
- var openReceiveResultSchema = addressSchema;
508
- var openReceiveRequestMessageSchema = v17.object({
509
- ...rpcRequestMessageSchema.entries,
510
- ...v17.object({
511
- method: v17.literal(openReceiveMethodName),
512
- params: openReceiveParamsSchema,
513
- id: v17.string()
514
- }).entries
512
+ var getAddressesResultSchema = v7.object({
513
+ /**
514
+ * The addresses generated for the given purposes.
515
+ */
516
+ addresses: v7.array(addressSchema),
517
+ network: getNetworkResultSchema
515
518
  });
516
-
517
- // src/request/types/walletMethods/renouncePermissions.ts
518
- import * as v18 from "valibot";
519
- var renouncePermissionsMethodName = "wallet_renouncePermissions";
520
- var renouncePermissionsParamsSchema = v18.nullish(v18.null());
521
- var renouncePermissionsResultSchema = v18.nullish(v18.null());
522
- var renouncePermissionsRequestMessageSchema = v18.object({
519
+ var getAddressesRequestMessageSchema = v7.object({
523
520
  ...rpcRequestMessageSchema.entries,
524
- ...v18.object({
525
- method: v18.literal(renouncePermissionsMethodName),
526
- params: renouncePermissionsParamsSchema,
527
- id: v18.string()
521
+ ...v7.object({
522
+ method: v7.literal(getAddressesMethodName),
523
+ params: getAddressesParamsSchema,
524
+ id: v7.string()
528
525
  }).entries
529
526
  });
530
527
 
531
- // src/request/types/walletMethods/requestPermissions.ts
532
- import * as v19 from "valibot";
533
- var requestPermissionsMethodName = "wallet_requestPermissions";
534
- var requestPermissionsParamsSchema = v19.nullish(v19.array(PermissionRequestParams));
535
- var requestPermissionsResultSchema = v19.literal(true);
536
- var requestPermissionsRequestMessageSchema = v19.object({
528
+ // src/request/types/btcMethods/getBalance.ts
529
+ import * as v8 from "valibot";
530
+ var getBalanceMethodName = "getBalance";
531
+ var getBalanceParamsSchema = v8.nullish(v8.null());
532
+ var getBalanceResultSchema = v8.object({
533
+ /**
534
+ * The confirmed balance of the wallet in sats. Using a string due to chrome
535
+ * messages not supporting bigint
536
+ * (https://issues.chromium.org/issues/40116184).
537
+ */
538
+ confirmed: v8.string(),
539
+ /**
540
+ * The unconfirmed balance of the wallet in sats. Using a string due to chrome
541
+ * messages not supporting bigint
542
+ * (https://issues.chromium.org/issues/40116184).
543
+ */
544
+ unconfirmed: v8.string(),
545
+ /**
546
+ * The total balance (both confirmed and unconfrimed UTXOs) of the wallet in
547
+ * sats. Using a string due to chrome messages not supporting bigint
548
+ * (https://issues.chromium.org/issues/40116184).
549
+ */
550
+ total: v8.string()
551
+ });
552
+ var getBalanceRequestMessageSchema = v8.object({
537
553
  ...rpcRequestMessageSchema.entries,
538
- ...v19.object({
539
- method: v19.literal(requestPermissionsMethodName),
540
- params: requestPermissionsParamsSchema,
541
- id: v19.string()
554
+ ...v8.object({
555
+ method: v8.literal(getBalanceMethodName),
556
+ id: v8.string()
542
557
  }).entries
543
558
  });
544
559
 
545
- // src/request/types/btcMethods.ts
560
+ // src/request/types/btcMethods/getInfo.ts
561
+ import * as v9 from "valibot";
546
562
  var ProviderPlatform = /* @__PURE__ */ ((ProviderPlatform2) => {
547
563
  ProviderPlatform2["Web"] = "web";
548
564
  ProviderPlatform2["Mobile"] = "mobile";
549
565
  return ProviderPlatform2;
550
566
  })(ProviderPlatform || {});
551
567
  var getInfoMethodName = "getInfo";
552
- var getInfoParamsSchema = v20.nullish(v20.null());
553
- var getInfoResultSchema = v20.object({
568
+ var getInfoParamsSchema = v9.nullish(v9.null());
569
+ var getInfoResultSchema = v9.object({
554
570
  /**
555
571
  * Version of the wallet.
556
572
  */
557
- version: v20.string(),
573
+ version: v9.string(),
558
574
  /**
559
575
  * The platform the wallet is running on (web or mobile).
560
576
  */
561
- platform: v20.optional(v20.enum(ProviderPlatform)),
577
+ platform: v9.optional(v9.enum(ProviderPlatform)),
562
578
  /**
563
579
  * [WBIP](https://wbips.netlify.app/wbips/WBIP002) methods supported by the wallet.
564
580
  */
565
- methods: v20.optional(v20.array(v20.string())),
581
+ methods: v9.optional(v9.array(v9.string())),
566
582
  /**
567
583
  * List of WBIP standards supported by the wallet. Not currently used.
568
584
  */
569
- supports: v20.array(v20.string())
585
+ supports: v9.array(v9.string())
570
586
  });
571
- var getInfoRequestMessageSchema = v20.object({
587
+ var getInfoRequestMessageSchema = v9.object({
572
588
  ...rpcRequestMessageSchema.entries,
573
- ...v20.object({
574
- method: v20.literal(getInfoMethodName),
589
+ ...v9.object({
590
+ method: v9.literal(getInfoMethodName),
575
591
  params: getInfoParamsSchema,
576
- id: v20.string()
592
+ id: v9.string()
577
593
  }).entries
578
594
  });
579
- var getAddressesMethodName = "getAddresses";
580
- var getAddressesParamsSchema = v20.object({
581
- /**
582
- * The purposes for which to generate addresses. See
583
- * {@linkcode AddressPurpose} for available purposes.
584
- */
585
- purposes: v20.array(v20.enum(AddressPurpose)),
595
+
596
+ // src/request/types/btcMethods/sendTransfer.ts
597
+ import * as v10 from "valibot";
598
+ var sendTransferMethodName = "sendTransfer";
599
+ var sendTransferParamsSchema = v10.object({
586
600
  /**
587
- * A message to be displayed to the user in the request prompt.
601
+ * Array of recipients to send to.
602
+ * The amount to send to each recipient is in satoshis.
588
603
  */
589
- message: v20.optional(v20.string())
604
+ recipients: v10.array(
605
+ v10.object({
606
+ address: v10.string(),
607
+ amount: v10.number()
608
+ })
609
+ )
590
610
  });
591
- var getAddressesResultSchema = v20.object({
611
+ var sendTransferResultSchema = v10.object({
592
612
  /**
593
- * The addresses generated for the given purposes.
613
+ * The transaction id as a hex-encoded string.
594
614
  */
595
- addresses: v20.array(addressSchema),
596
- network: getNetworkResultSchema
615
+ txid: v10.string()
597
616
  });
598
- var getAddressesRequestMessageSchema = v20.object({
617
+ var sendTransferRequestMessageSchema = v10.object({
599
618
  ...rpcRequestMessageSchema.entries,
600
- ...v20.object({
601
- method: v20.literal(getAddressesMethodName),
602
- params: getAddressesParamsSchema,
603
- id: v20.string()
619
+ ...v10.object({
620
+ method: v10.literal(sendTransferMethodName),
621
+ params: sendTransferParamsSchema,
622
+ id: v10.string()
604
623
  }).entries
605
624
  });
625
+
626
+ // src/request/types/btcMethods/signMessage.ts
627
+ import * as v11 from "valibot";
606
628
  var signMessageMethodName = "signMessage";
607
- var MessageSigningProtocols = /* @__PURE__ */ ((MessageSigningProtocols2) => {
608
- MessageSigningProtocols2["ECDSA"] = "ECDSA";
609
- MessageSigningProtocols2["BIP322"] = "BIP322";
610
- return MessageSigningProtocols2;
611
- })(MessageSigningProtocols || {});
612
- var signMessageParamsSchema = v20.object({
629
+ var signMessageParamsSchema = v11.object({
613
630
  /**
614
631
  * The address used for signing.
615
632
  **/
616
- address: v20.string(),
633
+ address: v11.string(),
617
634
  /**
618
635
  * The message to sign.
619
636
  **/
620
- message: v20.string(),
637
+ message: v11.string(),
621
638
  /**
622
639
  * The protocol to use for signing the message.
623
640
  */
624
- protocol: v20.optional(v20.enum(MessageSigningProtocols))
641
+ protocol: v11.optional(v11.enum(MessageSigningProtocols))
625
642
  });
626
- var signMessageResultSchema = v20.object({
643
+ var signMessageResultSchema = v11.object({
627
644
  /**
628
645
  * The signature of the message.
629
646
  */
630
- signature: v20.string(),
647
+ signature: v11.string(),
631
648
  /**
632
649
  * hash of the message.
633
650
  */
634
- messageHash: v20.string(),
651
+ messageHash: v11.string(),
635
652
  /**
636
653
  * The address used for signing.
637
654
  */
638
- address: v20.string(),
655
+ address: v11.string(),
639
656
  /**
640
657
  * The protocol to use for signing the message.
641
658
  */
642
- protocol: v20.enum(MessageSigningProtocols)
659
+ protocol: v11.enum(MessageSigningProtocols)
643
660
  });
644
- var signMessageRequestMessageSchema = v20.object({
661
+ var signMessageRequestMessageSchema = v11.object({
645
662
  ...rpcRequestMessageSchema.entries,
646
- ...v20.object({
647
- method: v20.literal(signMessageMethodName),
663
+ ...v11.object({
664
+ method: v11.literal(signMessageMethodName),
648
665
  params: signMessageParamsSchema,
649
- id: v20.string()
666
+ id: v11.string()
650
667
  }).entries
651
668
  });
652
- var sendTransferMethodName = "sendTransfer";
653
- var sendTransferParamsSchema = v20.object({
654
- /**
655
- * Array of recipients to send to.
656
- * The amount to send to each recipient is in satoshis.
657
- */
658
- recipients: v20.array(
659
- v20.object({
660
- address: v20.string(),
661
- amount: v20.number()
662
- })
663
- )
664
- });
665
- var sendTransferResultSchema = v20.object({
666
- /**
667
- * The transaction id as a hex-encoded string.
668
- */
669
- txid: v20.string()
670
- });
671
- var sendTransferRequestMessageSchema = v20.object({
669
+
670
+ // src/request/types/btcMethods/signMultipleMessages.ts
671
+ import * as v12 from "valibot";
672
+ var signMultipleMessagesMethodName = "signMultipleMessages";
673
+ var signMultipleMessagesParamsSchema = v12.array(
674
+ v12.object({
675
+ /**
676
+ * The address used for signing.
677
+ **/
678
+ address: v12.string(),
679
+ /**
680
+ * The message to sign.
681
+ **/
682
+ message: v12.string(),
683
+ /**
684
+ * The protocol to use for signing the message.
685
+ */
686
+ protocol: v12.optional(v12.enum(MessageSigningProtocols))
687
+ })
688
+ );
689
+ var signMultipleMessagesResultSchema = v12.array(
690
+ v12.object({
691
+ /**
692
+ * The signature of the message.
693
+ */
694
+ signature: v12.string(),
695
+ /**
696
+ * The original message which was signed.
697
+ */
698
+ message: v12.string(),
699
+ /**
700
+ * Hash of the message.
701
+ */
702
+ messageHash: v12.string(),
703
+ /**
704
+ * The address used for signing.
705
+ */
706
+ address: v12.string(),
707
+ /**
708
+ * The protocol to use for signing the message.
709
+ */
710
+ protocol: v12.enum(MessageSigningProtocols)
711
+ })
712
+ );
713
+ var signMultipleMessagesRequestMessageSchema = v12.object({
672
714
  ...rpcRequestMessageSchema.entries,
673
- ...v20.object({
674
- method: v20.literal(sendTransferMethodName),
675
- params: sendTransferParamsSchema,
676
- id: v20.string()
715
+ ...v12.object({
716
+ method: v12.literal(signMultipleMessagesMethodName),
717
+ params: signMultipleMessagesParamsSchema,
718
+ id: v12.string()
677
719
  }).entries
678
720
  });
721
+
722
+ // src/request/types/btcMethods/signPSBT.ts
723
+ import * as v13 from "valibot";
679
724
  var signPsbtMethodName = "signPsbt";
680
- var signPsbtParamsSchema = v20.object({
725
+ var signPsbtParamsSchema = v13.object({
681
726
  /**
682
727
  * The base64 encoded PSBT to sign.
683
728
  */
684
- psbt: v20.string(),
729
+ psbt: v13.string(),
685
730
  /**
686
731
  * The inputs to sign.
687
732
  * The key is the address and the value is an array of indexes of the inputs to sign.
688
733
  */
689
- signInputs: v20.optional(v20.record(v20.string(), v20.array(v20.number()))),
734
+ signInputs: v13.optional(v13.record(v13.string(), v13.array(v13.number()))),
690
735
  /**
691
736
  * Whether to broadcast the transaction after signing.
692
737
  **/
693
- broadcast: v20.optional(v20.boolean())
738
+ broadcast: v13.optional(v13.boolean())
694
739
  });
695
- var signPsbtResultSchema = v20.object({
740
+ var signPsbtResultSchema = v13.object({
696
741
  /**
697
742
  * The base64 encoded PSBT after signing.
698
743
  */
699
- psbt: v20.string(),
744
+ psbt: v13.string(),
700
745
  /**
701
746
  * The transaction id as a hex-encoded string.
702
747
  * This is only returned if the transaction was broadcast.
703
748
  **/
704
- txid: v20.optional(v20.string())
749
+ txid: v13.optional(v13.string())
705
750
  });
706
- var signPsbtRequestMessageSchema = v20.object({
751
+ var signPsbtRequestMessageSchema = v13.object({
707
752
  ...rpcRequestMessageSchema.entries,
708
- ...v20.object({
709
- method: v20.literal(signPsbtMethodName),
753
+ ...v13.object({
754
+ method: v13.literal(signPsbtMethodName),
710
755
  params: signPsbtParamsSchema,
711
- id: v20.string()
712
- }).entries
713
- });
714
- var getAccountsMethodName = "getAccounts";
715
- var getAccountsParamsSchema = v20.object({
716
- /**
717
- * The purposes for which to generate addresses. See
718
- * {@linkcode AddressPurpose} for available purposes.
719
- */
720
- purposes: v20.array(v20.enum(AddressPurpose)),
721
- /**
722
- * A message to be displayed to the user in the request prompt.
723
- */
724
- message: v20.optional(v20.string())
725
- });
726
- var getAccountsResultSchema = v20.array(
727
- v20.object({
728
- ...addressSchema.entries,
729
- ...v20.object({
730
- walletType: walletTypeSchema
731
- }).entries
732
- })
733
- );
734
- var getAccountsRequestMessageSchema = v20.object({
735
- ...rpcRequestMessageSchema.entries,
736
- ...v20.object({
737
- method: v20.literal(getAccountsMethodName),
738
- params: getAccountsParamsSchema,
739
- id: v20.string()
740
- }).entries
741
- });
742
- var getBalanceMethodName = "getBalance";
743
- var getBalanceParamsSchema = v20.nullish(v20.null());
744
- var getBalanceResultSchema = v20.object({
745
- /**
746
- * The confirmed balance of the wallet in sats. Using a string due to chrome
747
- * messages not supporting bigint
748
- * (https://issues.chromium.org/issues/40116184).
749
- */
750
- confirmed: v20.string(),
751
- /**
752
- * The unconfirmed balance of the wallet in sats. Using a string due to chrome
753
- * messages not supporting bigint
754
- * (https://issues.chromium.org/issues/40116184).
755
- */
756
- unconfirmed: v20.string(),
757
- /**
758
- * The total balance (both confirmed and unconfrimed UTXOs) of the wallet in
759
- * sats. Using a string due to chrome messages not supporting bigint
760
- * (https://issues.chromium.org/issues/40116184).
761
- */
762
- total: v20.string()
763
- });
764
- var getBalanceRequestMessageSchema = v20.object({
765
- ...rpcRequestMessageSchema.entries,
766
- ...v20.object({
767
- method: v20.literal(getBalanceMethodName),
768
- id: v20.string()
756
+ id: v13.string()
769
757
  }).entries
770
758
  });
771
759
 
772
760
  // src/request/types/ordinalsMethods.ts
773
- import * as v21 from "valibot";
761
+ import * as v14 from "valibot";
774
762
  var getInscriptionsMethodName = "ord_getInscriptions";
775
- var getInscriptionsParamsSchema = v21.object({
776
- offset: v21.number(),
777
- limit: v21.number()
778
- });
779
- var getInscriptionsResultSchema = v21.object({
780
- total: v21.number(),
781
- limit: v21.number(),
782
- offset: v21.number(),
783
- inscriptions: v21.array(
784
- v21.object({
785
- inscriptionId: v21.string(),
786
- inscriptionNumber: v21.string(),
787
- address: v21.string(),
788
- collectionName: v21.optional(v21.string()),
789
- postage: v21.string(),
790
- contentLength: v21.string(),
791
- contentType: v21.string(),
792
- timestamp: v21.number(),
793
- offset: v21.number(),
794
- genesisTransaction: v21.string(),
795
- output: v21.string()
763
+ var getInscriptionsParamsSchema = v14.object({
764
+ offset: v14.number(),
765
+ limit: v14.number()
766
+ });
767
+ var getInscriptionsResultSchema = v14.object({
768
+ total: v14.number(),
769
+ limit: v14.number(),
770
+ offset: v14.number(),
771
+ inscriptions: v14.array(
772
+ v14.object({
773
+ inscriptionId: v14.string(),
774
+ inscriptionNumber: v14.string(),
775
+ address: v14.string(),
776
+ collectionName: v14.optional(v14.string()),
777
+ postage: v14.string(),
778
+ contentLength: v14.string(),
779
+ contentType: v14.string(),
780
+ timestamp: v14.number(),
781
+ offset: v14.number(),
782
+ genesisTransaction: v14.string(),
783
+ output: v14.string()
796
784
  })
797
785
  )
798
786
  });
799
- var getInscriptionsRequestMessageSchema = v21.object({
787
+ var getInscriptionsRequestMessageSchema = v14.object({
800
788
  ...rpcRequestMessageSchema.entries,
801
- ...v21.object({
802
- method: v21.literal(getInscriptionsMethodName),
789
+ ...v14.object({
790
+ method: v14.literal(getInscriptionsMethodName),
803
791
  params: getInscriptionsParamsSchema,
804
- id: v21.string()
792
+ id: v14.string()
805
793
  }).entries
806
794
  });
807
795
  var sendInscriptionsMethodName = "ord_sendInscriptions";
808
- var sendInscriptionsParamsSchema = v21.object({
809
- transfers: v21.array(
810
- v21.object({
811
- address: v21.string(),
812
- inscriptionId: v21.string()
796
+ var sendInscriptionsParamsSchema = v14.object({
797
+ transfers: v14.array(
798
+ v14.object({
799
+ address: v14.string(),
800
+ inscriptionId: v14.string()
813
801
  })
814
802
  )
815
803
  });
816
- var sendInscriptionsResultSchema = v21.object({
817
- txid: v21.string()
804
+ var sendInscriptionsResultSchema = v14.object({
805
+ txid: v14.string()
818
806
  });
819
- var sendInscriptionsRequestMessageSchema = v21.object({
807
+ var sendInscriptionsRequestMessageSchema = v14.object({
820
808
  ...rpcRequestMessageSchema.entries,
821
- ...v21.object({
822
- method: v21.literal(sendInscriptionsMethodName),
809
+ ...v14.object({
810
+ method: v14.literal(sendInscriptionsMethodName),
823
811
  params: sendInscriptionsParamsSchema,
824
- id: v21.string()
812
+ id: v14.string()
825
813
  }).entries
826
814
  });
827
815
 
828
816
  // src/request/types/runesMethods/etch.ts
829
- import * as v22 from "valibot";
817
+ import * as v15 from "valibot";
830
818
  var runesEtchMethodName = "runes_etch";
831
- var etchTermsSchema = v22.object({
832
- amount: v22.string(),
833
- cap: v22.string(),
834
- heightStart: v22.optional(v22.string()),
835
- heightEnd: v22.optional(v22.string()),
836
- offsetStart: v22.optional(v22.string()),
837
- offsetEnd: v22.optional(v22.string())
838
- });
839
- var inscriptionDetailsSchema = v22.object({
840
- contentType: v22.string(),
841
- contentBase64: v22.string()
842
- });
843
- var runesEtchParamsSchema = v22.object({
844
- runeName: v22.string(),
845
- divisibility: v22.optional(v22.number()),
846
- symbol: v22.optional(v22.string()),
847
- premine: v22.optional(v22.string()),
848
- isMintable: v22.boolean(),
849
- delegateInscriptionId: v22.optional(v22.string()),
850
- destinationAddress: v22.string(),
851
- refundAddress: v22.string(),
852
- feeRate: v22.number(),
853
- appServiceFee: v22.optional(v22.number()),
854
- appServiceFeeAddress: v22.optional(v22.string()),
855
- terms: v22.optional(etchTermsSchema),
856
- inscriptionDetails: v22.optional(inscriptionDetailsSchema),
857
- network: v22.optional(v22.enum(BitcoinNetworkType))
858
- });
859
- var runesEtchResultSchema = v22.object({
860
- orderId: v22.string(),
861
- fundTransactionId: v22.string(),
862
- fundingAddress: v22.string()
863
- });
864
- var runesEtchRequestMessageSchema = v22.object({
819
+ var etchTermsSchema = v15.object({
820
+ amount: v15.string(),
821
+ cap: v15.string(),
822
+ heightStart: v15.optional(v15.string()),
823
+ heightEnd: v15.optional(v15.string()),
824
+ offsetStart: v15.optional(v15.string()),
825
+ offsetEnd: v15.optional(v15.string())
826
+ });
827
+ var inscriptionDetailsSchema = v15.object({
828
+ contentType: v15.string(),
829
+ contentBase64: v15.string()
830
+ });
831
+ var runesEtchParamsSchema = v15.object({
832
+ runeName: v15.string(),
833
+ divisibility: v15.optional(v15.number()),
834
+ symbol: v15.optional(v15.string()),
835
+ premine: v15.optional(v15.string()),
836
+ isMintable: v15.boolean(),
837
+ delegateInscriptionId: v15.optional(v15.string()),
838
+ destinationAddress: v15.string(),
839
+ refundAddress: v15.string(),
840
+ feeRate: v15.number(),
841
+ appServiceFee: v15.optional(v15.number()),
842
+ appServiceFeeAddress: v15.optional(v15.string()),
843
+ terms: v15.optional(etchTermsSchema),
844
+ inscriptionDetails: v15.optional(inscriptionDetailsSchema),
845
+ network: v15.optional(v15.enum(BitcoinNetworkType))
846
+ });
847
+ var runesEtchResultSchema = v15.object({
848
+ orderId: v15.string(),
849
+ fundTransactionId: v15.string(),
850
+ fundingAddress: v15.string()
851
+ });
852
+ var runesEtchRequestMessageSchema = v15.object({
865
853
  ...rpcRequestMessageSchema.entries,
866
- ...v22.object({
867
- method: v22.literal(runesEtchMethodName),
854
+ ...v15.object({
855
+ method: v15.literal(runesEtchMethodName),
868
856
  params: runesEtchParamsSchema,
869
- id: v22.string()
857
+ id: v15.string()
870
858
  }).entries
871
859
  });
872
860
 
873
861
  // src/request/types/runesMethods/getBalance.ts
874
- import * as v23 from "valibot";
862
+ import * as v16 from "valibot";
875
863
  var runesGetBalanceMethodName = "runes_getBalance";
876
- var runesGetBalanceParamsSchema = v23.nullish(v23.null());
877
- var runesGetBalanceResultSchema = v23.object({
878
- balances: v23.array(
879
- v23.object({
880
- runeName: v23.string(),
881
- amount: v23.string(),
882
- divisibility: v23.number(),
883
- symbol: v23.string(),
884
- inscriptionId: v23.nullish(v23.string()),
885
- spendableBalance: v23.string()
864
+ var runesGetBalanceParamsSchema = v16.nullish(v16.null());
865
+ var runesGetBalanceResultSchema = v16.object({
866
+ balances: v16.array(
867
+ v16.object({
868
+ runeName: v16.string(),
869
+ amount: v16.string(),
870
+ divisibility: v16.number(),
871
+ symbol: v16.string(),
872
+ inscriptionId: v16.nullish(v16.string()),
873
+ spendableBalance: v16.string()
886
874
  })
887
875
  )
888
876
  });
889
- var runesGetBalanceRequestMessageSchema = v23.object({
877
+ var runesGetBalanceRequestMessageSchema = v16.object({
890
878
  ...rpcRequestMessageSchema.entries,
891
- ...v23.object({
892
- method: v23.literal(runesGetBalanceMethodName),
879
+ ...v16.object({
880
+ method: v16.literal(runesGetBalanceMethodName),
893
881
  params: runesGetBalanceParamsSchema,
894
- id: v23.string()
882
+ id: v16.string()
895
883
  }).entries
896
884
  });
897
885
 
898
886
  // src/request/types/runesMethods/mint.ts
899
- import * as v24 from "valibot";
887
+ import * as v17 from "valibot";
900
888
  var runesMintMethodName = "runes_mint";
901
- var runesMintParamsSchema = v24.object({
902
- appServiceFee: v24.optional(v24.number()),
903
- appServiceFeeAddress: v24.optional(v24.string()),
904
- destinationAddress: v24.string(),
905
- feeRate: v24.number(),
906
- refundAddress: v24.string(),
907
- repeats: v24.number(),
908
- runeName: v24.string(),
909
- network: v24.optional(v24.enum(BitcoinNetworkType))
910
- });
911
- var runesMintResultSchema = v24.object({
912
- orderId: v24.string(),
913
- fundTransactionId: v24.string(),
914
- fundingAddress: v24.string()
915
- });
916
- var runesMintRequestMessageSchema = v24.object({
889
+ var runesMintParamsSchema = v17.object({
890
+ appServiceFee: v17.optional(v17.number()),
891
+ appServiceFeeAddress: v17.optional(v17.string()),
892
+ destinationAddress: v17.string(),
893
+ feeRate: v17.number(),
894
+ refundAddress: v17.string(),
895
+ repeats: v17.number(),
896
+ runeName: v17.string(),
897
+ network: v17.optional(v17.enum(BitcoinNetworkType))
898
+ });
899
+ var runesMintResultSchema = v17.object({
900
+ orderId: v17.string(),
901
+ fundTransactionId: v17.string(),
902
+ fundingAddress: v17.string()
903
+ });
904
+ var runesMintRequestMessageSchema = v17.object({
917
905
  ...rpcRequestMessageSchema.entries,
918
- ...v24.object({
919
- method: v24.literal(runesMintMethodName),
906
+ ...v17.object({
907
+ method: v17.literal(runesMintMethodName),
920
908
  params: runesMintParamsSchema,
921
- id: v24.string()
909
+ id: v17.string()
922
910
  }).entries
923
911
  });
924
912
 
925
913
  // src/request/types/runesMethods/transfer.ts
926
- import * as v25 from "valibot";
914
+ import * as v18 from "valibot";
927
915
  var runesTransferMethodName = "runes_transfer";
928
- var runesTransferParamsSchema = v25.object({
929
- recipients: v25.array(
930
- v25.object({
931
- runeName: v25.string(),
932
- amount: v25.string(),
933
- address: v25.string()
916
+ var runesTransferParamsSchema = v18.object({
917
+ recipients: v18.array(
918
+ v18.object({
919
+ runeName: v18.string(),
920
+ amount: v18.string(),
921
+ address: v18.string()
934
922
  })
935
923
  )
936
924
  });
937
- var runesTransferResultSchema = v25.object({
938
- txid: v25.string()
925
+ var runesTransferResultSchema = v18.object({
926
+ txid: v18.string()
939
927
  });
940
- var runesTransferRequestMessageSchema = v25.object({
928
+ var runesTransferRequestMessageSchema = v18.object({
941
929
  ...rpcRequestMessageSchema.entries,
942
- ...v25.object({
943
- method: v25.literal(runesTransferMethodName),
930
+ ...v18.object({
931
+ method: v18.literal(runesTransferMethodName),
944
932
  params: runesTransferParamsSchema,
945
- id: v25.string()
933
+ id: v18.string()
946
934
  }).entries
947
935
  });
948
936
 
949
937
  // src/request/types/sparkMethods/flashnetMethods/clawbackFunds.ts
950
- import * as v26 from "valibot";
938
+ import * as v19 from "valibot";
951
939
  var sparkFlashnetClawbackFundsMethodName = "spark_flashnet_clawbackFunds";
952
- var sparkFlashnetClawbackFundsParamsSchema = v26.object({
953
- sparkTransferId: v26.string(),
954
- lpIdentityPublicKey: v26.string()
955
- });
956
- var sparkFlashnetClawbackFundsResultSchema = v26.object({
957
- requestId: v26.string(),
958
- accepted: v26.boolean(),
959
- internalRequestId: v26.optional(v26.string()),
960
- sparkStatusTrackingId: v26.optional(v26.string()),
961
- error: v26.optional(v26.string())
962
- });
963
- var sparkFlashnetClawbackFundsRequestMessageSchema = v26.object({
940
+ var sparkFlashnetClawbackFundsParamsSchema = v19.object({
941
+ sparkTransferId: v19.string(),
942
+ lpIdentityPublicKey: v19.string()
943
+ });
944
+ var sparkFlashnetClawbackFundsResultSchema = v19.object({
945
+ requestId: v19.string(),
946
+ accepted: v19.boolean(),
947
+ internalRequestId: v19.optional(v19.string()),
948
+ sparkStatusTrackingId: v19.optional(v19.string()),
949
+ error: v19.optional(v19.string())
950
+ });
951
+ var sparkFlashnetClawbackFundsRequestMessageSchema = v19.object({
964
952
  ...rpcRequestMessageSchema.entries,
965
- ...v26.object({
966
- method: v26.literal(sparkFlashnetClawbackFundsMethodName),
953
+ ...v19.object({
954
+ method: v19.literal(sparkFlashnetClawbackFundsMethodName),
967
955
  params: sparkFlashnetClawbackFundsParamsSchema,
968
- id: v26.string()
956
+ id: v19.string()
969
957
  }).entries
970
958
  });
971
959
 
972
960
  // src/request/types/sparkMethods/flashnetMethods/executeRouteSwap.ts
973
- import * as v27 from "valibot";
961
+ import * as v20 from "valibot";
974
962
  var sparkFlashnetExecuteRouteSwapMethodName = "spark_flashnet_executeRouteSwap";
975
- var sparkFlashnetExecuteRouteSwapParamsSchema = v27.object({
976
- hops: v27.array(
977
- v27.object({
978
- poolId: v27.string(),
979
- assetInAddress: v27.string(),
980
- assetOutAddress: v27.string(),
981
- hopIntegratorFeeRateBps: v27.optional(v27.number())
963
+ var sparkFlashnetExecuteRouteSwapParamsSchema = v20.object({
964
+ hops: v20.array(
965
+ v20.object({
966
+ poolId: v20.string(),
967
+ assetInAddress: v20.string(),
968
+ assetOutAddress: v20.string(),
969
+ hopIntegratorFeeRateBps: v20.optional(v20.number())
982
970
  })
983
971
  ),
984
- initialAssetAddress: v27.string(),
985
- inputAmount: v27.string(),
986
- maxRouteSlippageBps: v27.string(),
987
- minAmountOut: v27.optional(v27.string()),
988
- integratorFeeRateBps: v27.optional(v27.number()),
989
- integratorPublicKey: v27.optional(v27.string())
990
- });
991
- var sparkFlashnetExecuteRouteSwapResultSchema = v27.object({
992
- requestId: v27.string(),
993
- accepted: v27.boolean(),
994
- outputAmount: v27.string(),
995
- executionPrice: v27.string(),
996
- finalOutboundTransferId: v27.string(),
997
- error: v27.optional(v27.string())
998
- });
999
- var sparkFlashnetExecuteRouteSwapRequestMessageSchema = v27.object({
972
+ initialAssetAddress: v20.string(),
973
+ inputAmount: v20.string(),
974
+ maxRouteSlippageBps: v20.string(),
975
+ minAmountOut: v20.optional(v20.string()),
976
+ integratorFeeRateBps: v20.optional(v20.number()),
977
+ integratorPublicKey: v20.optional(v20.string())
978
+ });
979
+ var sparkFlashnetExecuteRouteSwapResultSchema = v20.object({
980
+ requestId: v20.string(),
981
+ accepted: v20.boolean(),
982
+ outputAmount: v20.string(),
983
+ executionPrice: v20.string(),
984
+ finalOutboundTransferId: v20.string(),
985
+ error: v20.optional(v20.string())
986
+ });
987
+ var sparkFlashnetExecuteRouteSwapRequestMessageSchema = v20.object({
1000
988
  ...rpcRequestMessageSchema.entries,
1001
- ...v27.object({
1002
- method: v27.literal(sparkFlashnetExecuteRouteSwapMethodName),
989
+ ...v20.object({
990
+ method: v20.literal(sparkFlashnetExecuteRouteSwapMethodName),
1003
991
  params: sparkFlashnetExecuteRouteSwapParamsSchema,
1004
- id: v27.string()
992
+ id: v20.string()
1005
993
  }).entries
1006
994
  });
1007
995
 
1008
996
  // src/request/types/sparkMethods/flashnetMethods/executeSwap.ts
1009
- import * as v28 from "valibot";
997
+ import * as v21 from "valibot";
1010
998
  var sparkFlashnetExecuteSwapMethodName = "spark_flashnet_executeSwap";
1011
- var sparkFlashnetExecuteSwapParamsSchema = v28.object({
1012
- poolId: v28.string(),
1013
- assetInAddress: v28.string(),
1014
- assetOutAddress: v28.string(),
1015
- amountIn: v28.string(),
1016
- maxSlippageBps: v28.number(),
1017
- minAmountOut: v28.optional(v28.string()),
1018
- integratorFeeRateBps: v28.optional(v28.number()),
1019
- integratorPublicKey: v28.optional(v28.string())
1020
- });
1021
- var sparkFlashnetExecuteSwapResultSchema = v28.object({
1022
- requestId: v28.string(),
1023
- accepted: v28.boolean(),
1024
- amountOut: v28.optional(v28.string()),
1025
- feeAmount: v28.optional(v28.string()),
1026
- executionPrice: v28.optional(v28.string()),
1027
- assetOutAddress: v28.optional(v28.string()),
1028
- assetInAddress: v28.optional(v28.string()),
1029
- outboundTransferId: v28.optional(v28.string()),
1030
- error: v28.optional(v28.string())
1031
- });
1032
- var sparkFlashnetExecuteSwapRequestMessageSchema = v28.object({
999
+ var sparkFlashnetExecuteSwapParamsSchema = v21.object({
1000
+ poolId: v21.string(),
1001
+ assetInAddress: v21.string(),
1002
+ assetOutAddress: v21.string(),
1003
+ amountIn: v21.string(),
1004
+ maxSlippageBps: v21.number(),
1005
+ minAmountOut: v21.optional(v21.string()),
1006
+ integratorFeeRateBps: v21.optional(v21.number()),
1007
+ integratorPublicKey: v21.optional(v21.string())
1008
+ });
1009
+ var sparkFlashnetExecuteSwapResultSchema = v21.object({
1010
+ requestId: v21.string(),
1011
+ accepted: v21.boolean(),
1012
+ amountOut: v21.optional(v21.string()),
1013
+ feeAmount: v21.optional(v21.string()),
1014
+ executionPrice: v21.optional(v21.string()),
1015
+ assetOutAddress: v21.optional(v21.string()),
1016
+ assetInAddress: v21.optional(v21.string()),
1017
+ outboundTransferId: v21.optional(v21.string()),
1018
+ error: v21.optional(v21.string())
1019
+ });
1020
+ var sparkFlashnetExecuteSwapRequestMessageSchema = v21.object({
1033
1021
  ...rpcRequestMessageSchema.entries,
1034
- ...v28.object({
1035
- method: v28.literal(sparkFlashnetExecuteSwapMethodName),
1022
+ ...v21.object({
1023
+ method: v21.literal(sparkFlashnetExecuteSwapMethodName),
1036
1024
  params: sparkFlashnetExecuteSwapParamsSchema,
1037
- id: v28.string()
1025
+ id: v21.string()
1038
1026
  }).entries
1039
1027
  });
1040
1028
 
1041
1029
  // src/request/types/sparkMethods/flashnetMethods/getClawbackEligibleTransfers.ts
1042
- import * as v29 from "valibot";
1030
+ import * as v22 from "valibot";
1043
1031
  var sparkGetClawbackEligibleTransfersMethodName = "spark_flashnet_getClawbackEligibleTransfers";
1044
- var sparkGetClawbackEligibleTransfersParamsSchema = v29.nullish(v29.null());
1045
- var sparkGetClawbackEligibleTransfersResultSchema = v29.object({
1046
- eligibleTransfers: v29.array(
1047
- v29.object({
1048
- txId: v29.string(),
1049
- createdAt: v29.string(),
1050
- lpIdentityPublicKey: v29.string()
1032
+ var sparkGetClawbackEligibleTransfersParamsSchema = v22.nullish(v22.null());
1033
+ var sparkGetClawbackEligibleTransfersResultSchema = v22.object({
1034
+ eligibleTransfers: v22.array(
1035
+ v22.object({
1036
+ txId: v22.string(),
1037
+ createdAt: v22.string(),
1038
+ lpIdentityPublicKey: v22.string()
1051
1039
  })
1052
1040
  )
1053
1041
  });
1054
- var sparkGetClawbackEligibleTransfersRequestMessageSchema = v29.object({
1042
+ var sparkGetClawbackEligibleTransfersRequestMessageSchema = v22.object({
1055
1043
  ...rpcRequestMessageSchema.entries,
1056
- ...v29.object({
1057
- method: v29.literal(sparkGetClawbackEligibleTransfersMethodName),
1044
+ ...v22.object({
1045
+ method: v22.literal(sparkGetClawbackEligibleTransfersMethodName),
1058
1046
  params: sparkGetClawbackEligibleTransfersParamsSchema,
1059
- id: v29.string()
1047
+ id: v22.string()
1060
1048
  }).entries
1061
1049
  });
1062
1050
 
1063
1051
  // src/request/types/sparkMethods/flashnetMethods/getJwt.ts
1064
- import * as v30 from "valibot";
1052
+ import * as v23 from "valibot";
1065
1053
  var sparkFlashnetGetJwtMethodName = "spark_flashnet_getJwt";
1066
- var sparkFlashnetGetJwtParamsSchema = v30.null();
1067
- var sparkFlashnetGetJwtResultSchema = v30.object({
1054
+ var sparkFlashnetGetJwtParamsSchema = v23.null();
1055
+ var sparkFlashnetGetJwtResultSchema = v23.object({
1068
1056
  /**
1069
1057
  * The JWT token for authenticated requests to the Flashnet API.
1070
1058
  */
1071
- jwt: v30.string()
1059
+ jwt: v23.string()
1072
1060
  });
1073
- var sparkFlashnetGetJwtRequestMessageSchema = v30.object({
1061
+ var sparkFlashnetGetJwtRequestMessageSchema = v23.object({
1074
1062
  ...rpcRequestMessageSchema.entries,
1075
- ...v30.object({
1076
- method: v30.literal(sparkFlashnetGetJwtMethodName),
1063
+ ...v23.object({
1064
+ method: v23.literal(sparkFlashnetGetJwtMethodName),
1077
1065
  params: sparkFlashnetGetJwtParamsSchema,
1078
- id: v30.string()
1066
+ id: v23.string()
1079
1067
  }).entries
1080
1068
  });
1081
1069
 
1082
1070
  // src/request/types/sparkMethods/flashnetMethods/intents/addLiquidity.ts
1083
- import * as v31 from "valibot";
1084
- var sparkFlashnetAddLiquidityIntentSchema = v31.object({
1085
- type: v31.literal("addLiquidity"),
1086
- data: v31.object({
1087
- userPublicKey: v31.string(),
1088
- poolId: v31.string(),
1089
- assetAAmount: v31.string(),
1090
- assetBAmount: v31.string(),
1091
- assetAMinAmountIn: v31.string(),
1092
- assetBMinAmountIn: v31.string(),
1093
- assetATransferId: v31.string(),
1094
- assetBTransferId: v31.string(),
1095
- nonce: v31.string()
1071
+ import * as v24 from "valibot";
1072
+ var sparkFlashnetAddLiquidityIntentSchema = v24.object({
1073
+ type: v24.literal("addLiquidity"),
1074
+ data: v24.object({
1075
+ userPublicKey: v24.string(),
1076
+ poolId: v24.string(),
1077
+ assetAAmount: v24.string(),
1078
+ assetBAmount: v24.string(),
1079
+ assetAMinAmountIn: v24.string(),
1080
+ assetBMinAmountIn: v24.string(),
1081
+ assetATransferId: v24.string(),
1082
+ assetBTransferId: v24.string(),
1083
+ nonce: v24.string()
1096
1084
  })
1097
1085
  });
1098
1086
 
1099
1087
  // src/request/types/sparkMethods/flashnetMethods/intents/clawback.ts
1100
- import * as v32 from "valibot";
1101
- var sparkFlashnetClawbackIntentSchema = v32.object({
1102
- type: v32.literal("clawback"),
1103
- data: v32.object({
1104
- senderPublicKey: v32.string(),
1105
- sparkTransferId: v32.string(),
1106
- lpIdentityPublicKey: v32.string(),
1107
- nonce: v32.string()
1088
+ import * as v25 from "valibot";
1089
+ var sparkFlashnetClawbackIntentSchema = v25.object({
1090
+ type: v25.literal("clawback"),
1091
+ data: v25.object({
1092
+ senderPublicKey: v25.string(),
1093
+ sparkTransferId: v25.string(),
1094
+ lpIdentityPublicKey: v25.string(),
1095
+ nonce: v25.string()
1108
1096
  })
1109
1097
  });
1110
1098
 
1111
1099
  // src/request/types/sparkMethods/flashnetMethods/intents/confirmInitialDeposit.ts
1112
- import * as v33 from "valibot";
1113
- var sparkFlashnetConfirmInitialDepositIntentSchema = v33.object({
1114
- type: v33.literal("confirmInitialDeposit"),
1115
- data: v33.object({
1116
- poolId: v33.string(),
1117
- assetASparkTransferId: v33.string(),
1118
- poolOwnerPublicKey: v33.string(),
1119
- nonce: v33.string()
1100
+ import * as v26 from "valibot";
1101
+ var sparkFlashnetConfirmInitialDepositIntentSchema = v26.object({
1102
+ type: v26.literal("confirmInitialDeposit"),
1103
+ data: v26.object({
1104
+ poolId: v26.string(),
1105
+ assetASparkTransferId: v26.string(),
1106
+ poolOwnerPublicKey: v26.string(),
1107
+ nonce: v26.string()
1120
1108
  })
1121
1109
  });
1122
1110
 
1123
1111
  // src/request/types/sparkMethods/flashnetMethods/intents/createConstantProductPool.ts
1124
- import * as v34 from "valibot";
1125
- var sparkFlashnetCreateConstantProductPoolIntentSchema = v34.object({
1126
- type: v34.literal("createConstantProductPool"),
1127
- data: v34.object({
1128
- poolOwnerPublicKey: v34.string(),
1129
- assetAAddress: v34.string(),
1130
- assetBAddress: v34.string(),
1131
- lpFeeRateBps: v34.union([v34.number(), v34.string()]),
1132
- totalHostFeeRateBps: v34.union([v34.number(), v34.string()]),
1133
- nonce: v34.string()
1112
+ import * as v27 from "valibot";
1113
+ var sparkFlashnetCreateConstantProductPoolIntentSchema = v27.object({
1114
+ type: v27.literal("createConstantProductPool"),
1115
+ data: v27.object({
1116
+ poolOwnerPublicKey: v27.string(),
1117
+ assetAAddress: v27.string(),
1118
+ assetBAddress: v27.string(),
1119
+ lpFeeRateBps: v27.union([v27.number(), v27.string()]),
1120
+ totalHostFeeRateBps: v27.union([v27.number(), v27.string()]),
1121
+ nonce: v27.string()
1134
1122
  })
1135
1123
  });
1136
1124
 
1137
1125
  // src/request/types/sparkMethods/flashnetMethods/intents/createSingleSidedPool.ts
1138
- import * as v35 from "valibot";
1139
- var sparkFlashnetCreateSingleSidedPoolIntentSchema = v35.object({
1140
- type: v35.literal("createSingleSidedPool"),
1141
- data: v35.object({
1142
- assetAAddress: v35.string(),
1143
- assetBAddress: v35.string(),
1144
- assetAInitialReserve: v35.string(),
1145
- virtualReserveA: v35.union([v35.number(), v35.string()]),
1146
- virtualReserveB: v35.union([v35.number(), v35.string()]),
1147
- threshold: v35.union([v35.number(), v35.string()]),
1148
- lpFeeRateBps: v35.union([v35.number(), v35.string()]),
1149
- totalHostFeeRateBps: v35.union([v35.number(), v35.string()]),
1150
- poolOwnerPublicKey: v35.string(),
1151
- nonce: v35.string()
1126
+ import * as v28 from "valibot";
1127
+ var sparkFlashnetCreateSingleSidedPoolIntentSchema = v28.object({
1128
+ type: v28.literal("createSingleSidedPool"),
1129
+ data: v28.object({
1130
+ assetAAddress: v28.string(),
1131
+ assetBAddress: v28.string(),
1132
+ assetAInitialReserve: v28.string(),
1133
+ virtualReserveA: v28.union([v28.number(), v28.string()]),
1134
+ virtualReserveB: v28.union([v28.number(), v28.string()]),
1135
+ threshold: v28.union([v28.number(), v28.string()]),
1136
+ lpFeeRateBps: v28.union([v28.number(), v28.string()]),
1137
+ totalHostFeeRateBps: v28.union([v28.number(), v28.string()]),
1138
+ poolOwnerPublicKey: v28.string(),
1139
+ nonce: v28.string()
1152
1140
  })
1153
1141
  });
1154
1142
 
1155
1143
  // src/request/types/sparkMethods/flashnetMethods/intents/removeLiquidity.ts
1156
- import * as v36 from "valibot";
1157
- var sparkFlashnetRemoveLiquidityIntentSchema = v36.object({
1158
- type: v36.literal("removeLiquidity"),
1159
- data: v36.object({
1160
- userPublicKey: v36.string(),
1161
- poolId: v36.string(),
1162
- lpTokensToRemove: v36.string(),
1163
- nonce: v36.string()
1144
+ import * as v29 from "valibot";
1145
+ var sparkFlashnetRemoveLiquidityIntentSchema = v29.object({
1146
+ type: v29.literal("removeLiquidity"),
1147
+ data: v29.object({
1148
+ userPublicKey: v29.string(),
1149
+ poolId: v29.string(),
1150
+ lpTokensToRemove: v29.string(),
1151
+ nonce: v29.string()
1164
1152
  })
1165
1153
  });
1166
1154
 
1167
1155
  // src/request/types/sparkMethods/flashnetMethods/intents/routeSwap.ts
1168
- import * as v37 from "valibot";
1169
- var sparkFlashnetRouteSwapIntentSchema = v37.object({
1170
- type: v37.literal("executeRouteSwap"),
1171
- data: v37.object({
1172
- userPublicKey: v37.string(),
1173
- initialSparkTransferId: v37.string(),
1174
- hops: v37.array(
1175
- v37.object({
1176
- poolId: v37.string(),
1177
- inputAssetAddress: v37.string(),
1178
- outputAssetAddress: v37.string(),
1179
- hopIntegratorFeeRateBps: v37.optional(v37.union([v37.number(), v37.string()]))
1156
+ import * as v30 from "valibot";
1157
+ var sparkFlashnetRouteSwapIntentSchema = v30.object({
1158
+ type: v30.literal("executeRouteSwap"),
1159
+ data: v30.object({
1160
+ userPublicKey: v30.string(),
1161
+ initialSparkTransferId: v30.string(),
1162
+ hops: v30.array(
1163
+ v30.object({
1164
+ poolId: v30.string(),
1165
+ inputAssetAddress: v30.string(),
1166
+ outputAssetAddress: v30.string(),
1167
+ hopIntegratorFeeRateBps: v30.optional(v30.union([v30.number(), v30.string()]))
1180
1168
  })
1181
1169
  ),
1182
- inputAmount: v37.string(),
1183
- maxRouteSlippageBps: v37.union([v37.number(), v37.string()]),
1184
- minAmountOut: v37.string(),
1185
- defaultIntegratorFeeRateBps: v37.optional(v37.union([v37.number(), v37.string()])),
1186
- nonce: v37.string()
1170
+ inputAmount: v30.string(),
1171
+ maxRouteSlippageBps: v30.union([v30.number(), v30.string()]),
1172
+ minAmountOut: v30.string(),
1173
+ defaultIntegratorFeeRateBps: v30.optional(v30.union([v30.number(), v30.string()])),
1174
+ nonce: v30.string()
1187
1175
  })
1188
1176
  });
1189
1177
 
1190
1178
  // src/request/types/sparkMethods/flashnetMethods/intents/swap.ts
1191
- import * as v38 from "valibot";
1192
- var sparkFlashnetSwapIntentSchema = v38.object({
1193
- type: v38.literal("executeSwap"),
1194
- data: v38.object({
1195
- userPublicKey: v38.string(),
1196
- poolId: v38.string(),
1197
- transferId: v38.string(),
1198
- assetInAddress: v38.string(),
1199
- assetOutAddress: v38.string(),
1200
- amountIn: v38.string(),
1201
- maxSlippageBps: v38.union([v38.number(), v38.string()]),
1202
- minAmountOut: v38.string(),
1203
- totalIntegratorFeeRateBps: v38.optional(v38.union([v38.number(), v38.string()])),
1204
- nonce: v38.string()
1179
+ import * as v31 from "valibot";
1180
+ var sparkFlashnetSwapIntentSchema = v31.object({
1181
+ type: v31.literal("executeSwap"),
1182
+ data: v31.object({
1183
+ userPublicKey: v31.string(),
1184
+ poolId: v31.string(),
1185
+ transferId: v31.string(),
1186
+ assetInAddress: v31.string(),
1187
+ assetOutAddress: v31.string(),
1188
+ amountIn: v31.string(),
1189
+ maxSlippageBps: v31.union([v31.number(), v31.string()]),
1190
+ minAmountOut: v31.string(),
1191
+ totalIntegratorFeeRateBps: v31.optional(v31.union([v31.number(), v31.string()])),
1192
+ nonce: v31.string()
1205
1193
  })
1206
1194
  });
1207
1195
 
1208
1196
  // src/request/types/sparkMethods/flashnetMethods/signIntent.ts
1209
- import * as v39 from "valibot";
1197
+ import * as v32 from "valibot";
1210
1198
  var sparkFlashnetSignIntentMethodName = "spark_flashnet_signIntent";
1211
- var sparkFlashnetSignIntentParamsSchema = v39.union([
1199
+ var sparkFlashnetSignIntentParamsSchema = v32.union([
1212
1200
  sparkFlashnetSwapIntentSchema,
1213
1201
  sparkFlashnetRouteSwapIntentSchema,
1214
1202
  sparkFlashnetAddLiquidityIntentSchema,
@@ -1218,109 +1206,109 @@ var sparkFlashnetSignIntentParamsSchema = v39.union([
1218
1206
  sparkFlashnetCreateSingleSidedPoolIntentSchema,
1219
1207
  sparkFlashnetRemoveLiquidityIntentSchema
1220
1208
  ]);
1221
- var sparkFlashnetSignIntentResultSchema = v39.object({
1209
+ var sparkFlashnetSignIntentResultSchema = v32.object({
1222
1210
  /**
1223
1211
  * The signed intent as a hex string.
1224
1212
  */
1225
- signature: v39.string()
1213
+ signature: v32.string()
1226
1214
  });
1227
- var sparkFlashnetSignIntentRequestMessageSchema = v39.object({
1215
+ var sparkFlashnetSignIntentRequestMessageSchema = v32.object({
1228
1216
  ...rpcRequestMessageSchema.entries,
1229
- ...v39.object({
1230
- method: v39.literal(sparkFlashnetSignIntentMethodName),
1217
+ ...v32.object({
1218
+ method: v32.literal(sparkFlashnetSignIntentMethodName),
1231
1219
  params: sparkFlashnetSignIntentParamsSchema,
1232
- id: v39.string()
1220
+ id: v32.string()
1233
1221
  }).entries
1234
1222
  });
1235
1223
 
1236
1224
  // src/request/types/sparkMethods/flashnetMethods/signStructuredMessage.ts
1237
- import * as v40 from "valibot";
1225
+ import * as v33 from "valibot";
1238
1226
  var sparkFlashnetSignStructuredMessageMethodName = "spark_flashnet_signStructuredMessage";
1239
- var sparkFlashnetSignStructuredMessageParamsSchema = v40.object({
1240
- message: v40.string()
1227
+ var sparkFlashnetSignStructuredMessageParamsSchema = v33.object({
1228
+ message: v33.string()
1241
1229
  });
1242
- var sparkFlashnetSignStructuredMessageResultSchema = v40.object({
1243
- message: v40.string(),
1244
- signature: v40.string()
1230
+ var sparkFlashnetSignStructuredMessageResultSchema = v33.object({
1231
+ message: v33.string(),
1232
+ signature: v33.string()
1245
1233
  });
1246
- var sparkFlashnetSignStructuredMessageRequestMessageSchema = v40.object({
1234
+ var sparkFlashnetSignStructuredMessageRequestMessageSchema = v33.object({
1247
1235
  ...rpcRequestMessageSchema.entries,
1248
- ...v40.object({
1249
- method: v40.literal(sparkFlashnetSignStructuredMessageMethodName),
1236
+ ...v33.object({
1237
+ method: v33.literal(sparkFlashnetSignStructuredMessageMethodName),
1250
1238
  params: sparkFlashnetSignStructuredMessageParamsSchema,
1251
- id: v40.string()
1239
+ id: v33.string()
1252
1240
  }).entries
1253
1241
  });
1254
1242
 
1255
1243
  // src/request/types/sparkMethods/getAddresses.ts
1256
- import * as v41 from "valibot";
1244
+ import * as v34 from "valibot";
1257
1245
  var sparkGetAddressesMethodName = "spark_getAddresses";
1258
- var sparkGetAddressesParamsSchema = v41.nullish(
1259
- v41.object({
1246
+ var sparkGetAddressesParamsSchema = v34.nullish(
1247
+ v34.object({
1260
1248
  /**
1261
1249
  * A message to be displayed to the user in the request prompt.
1262
1250
  */
1263
- message: v41.optional(v41.string())
1251
+ message: v34.optional(v34.string())
1264
1252
  })
1265
1253
  );
1266
- var sparkGetAddressesResultSchema = v41.object({
1254
+ var sparkGetAddressesResultSchema = v34.object({
1267
1255
  /**
1268
1256
  * The addresses generated for the given purposes.
1269
1257
  */
1270
- addresses: v41.array(addressSchema),
1258
+ addresses: v34.array(addressSchema),
1271
1259
  network: getNetworkResultSchema
1272
1260
  });
1273
- var sparkGetAddressesRequestMessageSchema = v41.object({
1261
+ var sparkGetAddressesRequestMessageSchema = v34.object({
1274
1262
  ...rpcRequestMessageSchema.entries,
1275
- ...v41.object({
1276
- method: v41.literal(sparkGetAddressesMethodName),
1263
+ ...v34.object({
1264
+ method: v34.literal(sparkGetAddressesMethodName),
1277
1265
  params: sparkGetAddressesParamsSchema,
1278
- id: v41.string()
1266
+ id: v34.string()
1279
1267
  }).entries
1280
1268
  });
1281
1269
 
1282
1270
  // src/request/types/sparkMethods/getBalance.ts
1283
- import * as v42 from "valibot";
1271
+ import * as v35 from "valibot";
1284
1272
  var sparkGetBalanceMethodName = "spark_getBalance";
1285
- var sparkGetBalanceParamsSchema = v42.nullish(v42.null());
1286
- var sparkGetBalanceResultSchema = v42.object({
1273
+ var sparkGetBalanceParamsSchema = v35.nullish(v35.null());
1274
+ var sparkGetBalanceResultSchema = v35.object({
1287
1275
  /**
1288
1276
  * The Spark Bitcoin address balance in sats in string form.
1289
1277
  */
1290
- balance: v42.string(),
1291
- tokenBalances: v42.array(
1292
- v42.object({
1278
+ balance: v35.string(),
1279
+ tokenBalances: v35.array(
1280
+ v35.object({
1293
1281
  /* The address balance of the token in string form as it can overflow a js number */
1294
- balance: v42.string(),
1295
- tokenMetadata: v42.object({
1296
- tokenIdentifier: v42.string(),
1297
- tokenName: v42.string(),
1298
- tokenTicker: v42.string(),
1299
- decimals: v42.number(),
1300
- maxSupply: v42.string()
1282
+ balance: v35.string(),
1283
+ tokenMetadata: v35.object({
1284
+ tokenIdentifier: v35.string(),
1285
+ tokenName: v35.string(),
1286
+ tokenTicker: v35.string(),
1287
+ decimals: v35.number(),
1288
+ maxSupply: v35.string()
1301
1289
  })
1302
1290
  })
1303
1291
  )
1304
1292
  });
1305
- var sparkGetBalanceRequestMessageSchema = v42.object({
1293
+ var sparkGetBalanceRequestMessageSchema = v35.object({
1306
1294
  ...rpcRequestMessageSchema.entries,
1307
- ...v42.object({
1308
- method: v42.literal(sparkGetBalanceMethodName),
1295
+ ...v35.object({
1296
+ method: v35.literal(sparkGetBalanceMethodName),
1309
1297
  params: sparkGetBalanceParamsSchema,
1310
- id: v42.string()
1298
+ id: v35.string()
1311
1299
  }).entries
1312
1300
  });
1313
1301
 
1314
1302
  // src/request/types/sparkMethods/signMessage.ts
1315
- import * as v43 from "valibot";
1303
+ import * as v36 from "valibot";
1316
1304
  var sparkSignMessageMethodName = "spark_signMessage";
1317
- var sparkSignMessageParamsSchema = v43.object({
1305
+ var sparkSignMessageParamsSchema = v36.object({
1318
1306
  /**
1319
1307
  * The message to sign. The message should only consist of valid UTF-8 characters.
1320
1308
  */
1321
- message: v43.string()
1309
+ message: v36.string()
1322
1310
  });
1323
- var sparkSignMessageResultSchema = v43.object({
1311
+ var sparkSignMessageResultSchema = v36.object({
1324
1312
  /**
1325
1313
  * The signature, encoded in base64, of the message hash.
1326
1314
  *
@@ -1328,98 +1316,98 @@ var sparkSignMessageResultSchema = v43.object({
1328
1316
  * and the resulting byte array is hashed with SHA256 before signing
1329
1317
  * with the private key.
1330
1318
  */
1331
- signature: v43.string()
1319
+ signature: v36.string()
1332
1320
  });
1333
- var sparkSignMessageRequestMessageSchema = v43.object({
1321
+ var sparkSignMessageRequestMessageSchema = v36.object({
1334
1322
  ...rpcRequestMessageSchema.entries,
1335
- ...v43.object({
1336
- method: v43.literal(sparkSignMessageMethodName),
1323
+ ...v36.object({
1324
+ method: v36.literal(sparkSignMessageMethodName),
1337
1325
  params: sparkSignMessageParamsSchema,
1338
- id: v43.string()
1326
+ id: v36.string()
1339
1327
  }).entries
1340
1328
  });
1341
1329
 
1342
1330
  // src/request/types/sparkMethods/transfer.ts
1343
- import * as v44 from "valibot";
1331
+ import * as v37 from "valibot";
1344
1332
  var sparkTransferMethodName = "spark_transfer";
1345
- var sparkTransferParamsSchema = v44.object({
1333
+ var sparkTransferParamsSchema = v37.object({
1346
1334
  /**
1347
1335
  * Amount of SATS to transfer as a string or number.
1348
1336
  */
1349
- amountSats: v44.union([v44.number(), v44.string()]),
1337
+ amountSats: v37.union([v37.number(), v37.string()]),
1350
1338
  /**
1351
1339
  * The recipient's spark address.
1352
1340
  */
1353
- receiverSparkAddress: v44.string()
1341
+ receiverSparkAddress: v37.string()
1354
1342
  });
1355
- var sparkTransferResultSchema = v44.object({
1343
+ var sparkTransferResultSchema = v37.object({
1356
1344
  /**
1357
1345
  * The ID of the transaction.
1358
1346
  */
1359
- id: v44.string()
1347
+ id: v37.string()
1360
1348
  });
1361
- var sparkTransferRequestMessageSchema = v44.object({
1349
+ var sparkTransferRequestMessageSchema = v37.object({
1362
1350
  ...rpcRequestMessageSchema.entries,
1363
- ...v44.object({
1364
- method: v44.literal(sparkTransferMethodName),
1351
+ ...v37.object({
1352
+ method: v37.literal(sparkTransferMethodName),
1365
1353
  params: sparkTransferParamsSchema,
1366
- id: v44.string()
1354
+ id: v37.string()
1367
1355
  }).entries
1368
1356
  });
1369
1357
 
1370
1358
  // src/request/types/sparkMethods/transferToken.ts
1371
- import * as v45 from "valibot";
1359
+ import * as v38 from "valibot";
1372
1360
  var sparkTransferTokenMethodName = "spark_transferToken";
1373
- var sparkTransferTokenParamsSchema = v45.object({
1361
+ var sparkTransferTokenParamsSchema = v38.object({
1374
1362
  /**
1375
1363
  * Amount of units of the token to transfer as a string or number.
1376
1364
  */
1377
- tokenAmount: v45.union([v45.number(), v45.string()]),
1365
+ tokenAmount: v38.union([v38.number(), v38.string()]),
1378
1366
  /**
1379
1367
  * The Bech32m token identifier.
1380
1368
  */
1381
- tokenIdentifier: v45.string(),
1369
+ tokenIdentifier: v38.string(),
1382
1370
  /**
1383
1371
  * The recipient's spark address.
1384
1372
  */
1385
- receiverSparkAddress: v45.string()
1373
+ receiverSparkAddress: v38.string()
1386
1374
  });
1387
- var sparkTransferTokenResultSchema = v45.object({
1375
+ var sparkTransferTokenResultSchema = v38.object({
1388
1376
  /**
1389
1377
  * The ID of the transaction.
1390
1378
  */
1391
- id: v45.string()
1379
+ id: v38.string()
1392
1380
  });
1393
- var sparkTransferTokenRequestMessageSchema = v45.object({
1381
+ var sparkTransferTokenRequestMessageSchema = v38.object({
1394
1382
  ...rpcRequestMessageSchema.entries,
1395
- ...v45.object({
1396
- method: v45.literal(sparkTransferTokenMethodName),
1383
+ ...v38.object({
1384
+ method: v38.literal(sparkTransferTokenMethodName),
1397
1385
  params: sparkTransferTokenParamsSchema,
1398
- id: v45.string()
1386
+ id: v38.string()
1399
1387
  }).entries
1400
1388
  });
1401
1389
 
1402
1390
  // src/request/types/stxMethods/callContract.ts
1403
- import * as v46 from "valibot";
1391
+ import * as v39 from "valibot";
1404
1392
  var stxCallContractMethodName = "stx_callContract";
1405
- var stxCallContractParamsSchema = v46.object({
1393
+ var stxCallContractParamsSchema = v39.object({
1406
1394
  /**
1407
1395
  * The contract principal.
1408
1396
  *
1409
1397
  * E.g. `"SPKE...GD5C.my-contract"`
1410
1398
  */
1411
- contract: v46.string(),
1399
+ contract: v39.string(),
1412
1400
  /**
1413
1401
  * The name of the function to call.
1414
1402
  *
1415
1403
  * Note: spec changes ongoing,
1416
1404
  * https://github.com/stacksgov/sips/pull/166#pullrequestreview-1914236999
1417
1405
  */
1418
- functionName: v46.string(),
1406
+ functionName: v39.string(),
1419
1407
  /**
1420
1408
  * @deprecated in favor of `functionArgs` for @stacks/connect compatibility
1421
1409
  */
1422
- arguments: v46.optional(v46.array(v46.string())),
1410
+ arguments: v39.optional(v39.array(v39.string())),
1423
1411
  /**
1424
1412
  * The function's arguments. The arguments are expected to be hex-encoded
1425
1413
  * strings of Clarity values.
@@ -1434,274 +1422,274 @@ var stxCallContractParamsSchema = v46.object({
1434
1422
  * const hexArgs = functionArgs.map(cvToHex);
1435
1423
  * ```
1436
1424
  */
1437
- functionArgs: v46.optional(v46.array(v46.string())),
1425
+ functionArgs: v39.optional(v39.array(v39.string())),
1438
1426
  /**
1439
1427
  * The post conditions to apply to the contract call.
1440
1428
  */
1441
- postConditions: v46.optional(v46.array(v46.string())),
1429
+ postConditions: v39.optional(v39.array(v39.string())),
1442
1430
  /**
1443
1431
  * The mode to apply to the post conditions.
1444
1432
  */
1445
- postConditionMode: v46.optional(v46.union([v46.literal("allow"), v46.literal("deny")]))
1433
+ postConditionMode: v39.optional(v39.union([v39.literal("allow"), v39.literal("deny")]))
1446
1434
  });
1447
- var stxCallContractResultSchema = v46.object({
1435
+ var stxCallContractResultSchema = v39.object({
1448
1436
  /**
1449
1437
  * The ID of the transaction.
1450
1438
  */
1451
- txid: v46.string(),
1439
+ txid: v39.string(),
1452
1440
  /**
1453
1441
  * A Stacks transaction as a hex-encoded string.
1454
1442
  */
1455
- transaction: v46.string()
1443
+ transaction: v39.string()
1456
1444
  });
1457
- var stxCallContractRequestMessageSchema = v46.object({
1445
+ var stxCallContractRequestMessageSchema = v39.object({
1458
1446
  ...rpcRequestMessageSchema.entries,
1459
- ...v46.object({
1460
- method: v46.literal(stxCallContractMethodName),
1447
+ ...v39.object({
1448
+ method: v39.literal(stxCallContractMethodName),
1461
1449
  params: stxCallContractParamsSchema,
1462
- id: v46.string()
1450
+ id: v39.string()
1463
1451
  }).entries
1464
1452
  });
1465
1453
 
1466
1454
  // src/request/types/stxMethods/deployContract.ts
1467
- import * as v47 from "valibot";
1455
+ import * as v40 from "valibot";
1468
1456
  var stxDeployContractMethodName = "stx_deployContract";
1469
- var stxDeployContractParamsSchema = v47.object({
1457
+ var stxDeployContractParamsSchema = v40.object({
1470
1458
  /**
1471
1459
  * Name of the contract.
1472
1460
  */
1473
- name: v47.string(),
1461
+ name: v40.string(),
1474
1462
  /**
1475
1463
  * The source code of the Clarity contract.
1476
1464
  */
1477
- clarityCode: v47.string(),
1465
+ clarityCode: v40.string(),
1478
1466
  /**
1479
1467
  * The version of the Clarity contract.
1480
1468
  */
1481
- clarityVersion: v47.optional(v47.number()),
1469
+ clarityVersion: v40.optional(v40.number()),
1482
1470
  /**
1483
1471
  * The post conditions to apply to the contract call.
1484
1472
  */
1485
- postConditions: v47.optional(v47.array(v47.string())),
1473
+ postConditions: v40.optional(v40.array(v40.string())),
1486
1474
  /**
1487
1475
  * The mode to apply to the post conditions.
1488
1476
  */
1489
- postConditionMode: v47.optional(v47.union([v47.literal("allow"), v47.literal("deny")]))
1477
+ postConditionMode: v40.optional(v40.union([v40.literal("allow"), v40.literal("deny")]))
1490
1478
  });
1491
- var stxDeployContractResultSchema = v47.object({
1479
+ var stxDeployContractResultSchema = v40.object({
1492
1480
  /**
1493
1481
  * The ID of the transaction.
1494
1482
  */
1495
- txid: v47.string(),
1483
+ txid: v40.string(),
1496
1484
  /**
1497
1485
  * A Stacks transaction as a hex-encoded string.
1498
1486
  */
1499
- transaction: v47.string()
1487
+ transaction: v40.string()
1500
1488
  });
1501
- var stxDeployContractRequestMessageSchema = v47.object({
1489
+ var stxDeployContractRequestMessageSchema = v40.object({
1502
1490
  ...rpcRequestMessageSchema.entries,
1503
- ...v47.object({
1504
- method: v47.literal(stxDeployContractMethodName),
1491
+ ...v40.object({
1492
+ method: v40.literal(stxDeployContractMethodName),
1505
1493
  params: stxDeployContractParamsSchema,
1506
- id: v47.string()
1494
+ id: v40.string()
1507
1495
  }).entries
1508
1496
  });
1509
1497
 
1510
1498
  // src/request/types/stxMethods/getAccounts.ts
1511
- import * as v48 from "valibot";
1499
+ import * as v41 from "valibot";
1512
1500
  var stxGetAccountsMethodName = "stx_getAccounts";
1513
- var stxGetAccountsParamsSchema = v48.nullish(v48.null());
1514
- var stxGetAccountsResultSchema = v48.object({
1501
+ var stxGetAccountsParamsSchema = v41.nullish(v41.null());
1502
+ var stxGetAccountsResultSchema = v41.object({
1515
1503
  /**
1516
1504
  * The addresses generated for the given purposes.
1517
1505
  */
1518
- addresses: v48.array(
1519
- v48.object({
1520
- address: v48.string(),
1521
- publicKey: v48.string(),
1522
- gaiaHubUrl: v48.string(),
1523
- gaiaAppKey: v48.string()
1506
+ addresses: v41.array(
1507
+ v41.object({
1508
+ address: v41.string(),
1509
+ publicKey: v41.string(),
1510
+ gaiaHubUrl: v41.string(),
1511
+ gaiaAppKey: v41.string()
1524
1512
  })
1525
1513
  ),
1526
1514
  network: getNetworkResultSchema
1527
1515
  });
1528
- var stxGetAccountsRequestMessageSchema = v48.object({
1516
+ var stxGetAccountsRequestMessageSchema = v41.object({
1529
1517
  ...rpcRequestMessageSchema.entries,
1530
- ...v48.object({
1531
- method: v48.literal(stxGetAccountsMethodName),
1518
+ ...v41.object({
1519
+ method: v41.literal(stxGetAccountsMethodName),
1532
1520
  params: stxGetAccountsParamsSchema,
1533
- id: v48.string()
1521
+ id: v41.string()
1534
1522
  }).entries
1535
1523
  });
1536
1524
 
1537
1525
  // src/request/types/stxMethods/getAddresses.ts
1538
- import * as v49 from "valibot";
1526
+ import * as v42 from "valibot";
1539
1527
  var stxGetAddressesMethodName = "stx_getAddresses";
1540
- var stxGetAddressesParamsSchema = v49.nullish(
1541
- v49.object({
1528
+ var stxGetAddressesParamsSchema = v42.nullish(
1529
+ v42.object({
1542
1530
  /**
1543
1531
  * A message to be displayed to the user in the request prompt.
1544
1532
  */
1545
- message: v49.optional(v49.string())
1533
+ message: v42.optional(v42.string())
1546
1534
  })
1547
1535
  );
1548
- var stxGetAddressesResultSchema = v49.object({
1536
+ var stxGetAddressesResultSchema = v42.object({
1549
1537
  /**
1550
1538
  * The addresses generated for the given purposes.
1551
1539
  */
1552
- addresses: v49.array(addressSchema),
1540
+ addresses: v42.array(addressSchema),
1553
1541
  network: getNetworkResultSchema
1554
1542
  });
1555
- var stxGetAddressesRequestMessageSchema = v49.object({
1543
+ var stxGetAddressesRequestMessageSchema = v42.object({
1556
1544
  ...rpcRequestMessageSchema.entries,
1557
- ...v49.object({
1558
- method: v49.literal(stxGetAddressesMethodName),
1545
+ ...v42.object({
1546
+ method: v42.literal(stxGetAddressesMethodName),
1559
1547
  params: stxGetAddressesParamsSchema,
1560
- id: v49.string()
1548
+ id: v42.string()
1561
1549
  }).entries
1562
1550
  });
1563
1551
 
1564
1552
  // src/request/types/stxMethods/signMessage.ts
1565
- import * as v50 from "valibot";
1553
+ import * as v43 from "valibot";
1566
1554
  var stxSignMessageMethodName = "stx_signMessage";
1567
- var stxSignMessageParamsSchema = v50.object({
1555
+ var stxSignMessageParamsSchema = v43.object({
1568
1556
  /**
1569
1557
  * The message to sign.
1570
1558
  */
1571
- message: v50.string()
1559
+ message: v43.string()
1572
1560
  });
1573
- var stxSignMessageResultSchema = v50.object({
1561
+ var stxSignMessageResultSchema = v43.object({
1574
1562
  /**
1575
1563
  * The signature of the message.
1576
1564
  */
1577
- signature: v50.string(),
1565
+ signature: v43.string(),
1578
1566
  /**
1579
1567
  * The public key used to sign the message.
1580
1568
  */
1581
- publicKey: v50.string()
1569
+ publicKey: v43.string()
1582
1570
  });
1583
- var stxSignMessageRequestMessageSchema = v50.object({
1571
+ var stxSignMessageRequestMessageSchema = v43.object({
1584
1572
  ...rpcRequestMessageSchema.entries,
1585
- ...v50.object({
1586
- method: v50.literal(stxSignMessageMethodName),
1573
+ ...v43.object({
1574
+ method: v43.literal(stxSignMessageMethodName),
1587
1575
  params: stxSignMessageParamsSchema,
1588
- id: v50.string()
1576
+ id: v43.string()
1589
1577
  }).entries
1590
1578
  });
1591
1579
 
1592
1580
  // src/request/types/stxMethods/signStructuredMessage.ts
1593
- import * as v51 from "valibot";
1581
+ import * as v44 from "valibot";
1594
1582
  var stxSignStructuredMessageMethodName = "stx_signStructuredMessage";
1595
- var stxSignStructuredMessageParamsSchema = v51.object({
1583
+ var stxSignStructuredMessageParamsSchema = v44.object({
1596
1584
  /**
1597
1585
  * The domain to be signed.
1598
1586
  */
1599
- domain: v51.string(),
1587
+ domain: v44.string(),
1600
1588
  /**
1601
1589
  * Message payload to be signed.
1602
1590
  */
1603
- message: v51.string(),
1591
+ message: v44.string(),
1604
1592
  /**
1605
1593
  * The public key to sign the message with.
1606
1594
  */
1607
- publicKey: v51.optional(v51.string())
1595
+ publicKey: v44.optional(v44.string())
1608
1596
  });
1609
- var stxSignStructuredMessageResultSchema = v51.object({
1597
+ var stxSignStructuredMessageResultSchema = v44.object({
1610
1598
  /**
1611
1599
  * Signature of the message.
1612
1600
  */
1613
- signature: v51.string(),
1601
+ signature: v44.string(),
1614
1602
  /**
1615
1603
  * Public key as hex-encoded string.
1616
1604
  */
1617
- publicKey: v51.string()
1605
+ publicKey: v44.string()
1618
1606
  });
1619
- var stxSignStructuredMessageRequestMessageSchema = v51.object({
1607
+ var stxSignStructuredMessageRequestMessageSchema = v44.object({
1620
1608
  ...rpcRequestMessageSchema.entries,
1621
- ...v51.object({
1622
- method: v51.literal(stxSignStructuredMessageMethodName),
1609
+ ...v44.object({
1610
+ method: v44.literal(stxSignStructuredMessageMethodName),
1623
1611
  params: stxSignStructuredMessageParamsSchema,
1624
- id: v51.string()
1612
+ id: v44.string()
1625
1613
  }).entries
1626
1614
  });
1627
1615
 
1628
1616
  // src/request/types/stxMethods/signTransaction.ts
1629
- import * as v52 from "valibot";
1617
+ import * as v45 from "valibot";
1630
1618
  var stxSignTransactionMethodName = "stx_signTransaction";
1631
- var stxSignTransactionParamsSchema = v52.object({
1619
+ var stxSignTransactionParamsSchema = v45.object({
1632
1620
  /**
1633
1621
  * The transaction to sign as a hex-encoded string.
1634
1622
  */
1635
- transaction: v52.string(),
1623
+ transaction: v45.string(),
1636
1624
  /**
1637
1625
  * The public key to sign the transaction with. The wallet may use any key
1638
1626
  * when not provided.
1639
1627
  */
1640
- pubkey: v52.optional(v52.string()),
1628
+ pubkey: v45.optional(v45.string()),
1641
1629
  /**
1642
1630
  * Whether to broadcast the transaction after signing. Defaults to `true`.
1643
1631
  */
1644
- broadcast: v52.optional(v52.boolean())
1632
+ broadcast: v45.optional(v45.boolean())
1645
1633
  });
1646
- var stxSignTransactionResultSchema = v52.object({
1634
+ var stxSignTransactionResultSchema = v45.object({
1647
1635
  /**
1648
1636
  * The signed transaction as a hex-encoded string.
1649
1637
  */
1650
- transaction: v52.string()
1638
+ transaction: v45.string()
1651
1639
  });
1652
- var stxSignTransactionRequestMessageSchema = v52.object({
1640
+ var stxSignTransactionRequestMessageSchema = v45.object({
1653
1641
  ...rpcRequestMessageSchema.entries,
1654
- ...v52.object({
1655
- method: v52.literal(stxSignTransactionMethodName),
1642
+ ...v45.object({
1643
+ method: v45.literal(stxSignTransactionMethodName),
1656
1644
  params: stxSignTransactionParamsSchema,
1657
- id: v52.string()
1645
+ id: v45.string()
1658
1646
  }).entries
1659
1647
  });
1660
1648
 
1661
1649
  // src/request/types/stxMethods/signTransactions.ts
1662
- import * as v53 from "valibot";
1650
+ import * as v46 from "valibot";
1663
1651
  var stxSignTransactionsMethodName = "stx_signTransactions";
1664
- var stxSignTransactionsParamsSchema = v53.object({
1652
+ var stxSignTransactionsParamsSchema = v46.object({
1665
1653
  /**
1666
1654
  * The transactions to sign as hex-encoded strings.
1667
1655
  */
1668
- transactions: v53.pipe(
1669
- v53.array(
1670
- v53.pipe(
1671
- v53.string(),
1672
- v53.check((hex) => {
1656
+ transactions: v46.pipe(
1657
+ v46.array(
1658
+ v46.pipe(
1659
+ v46.string(),
1660
+ v46.check((hex) => {
1673
1661
  return true;
1674
1662
  }, "Invalid hex-encoded Stacks transaction.")
1675
1663
  )
1676
1664
  ),
1677
- v53.minLength(1)
1665
+ v46.minLength(1)
1678
1666
  ),
1679
1667
  /**
1680
1668
  * Whether the signed transactions should be broadcast after signing. Defaults
1681
1669
  * to `true`.
1682
1670
  */
1683
- broadcast: v53.optional(v53.boolean())
1671
+ broadcast: v46.optional(v46.boolean())
1684
1672
  });
1685
- var stxSignTransactionsResultSchema = v53.object({
1673
+ var stxSignTransactionsResultSchema = v46.object({
1686
1674
  /**
1687
1675
  * The signed transactions as hex-encoded strings, in the same order as in the
1688
1676
  * sign request.
1689
1677
  */
1690
- transactions: v53.array(v53.string())
1678
+ transactions: v46.array(v46.string())
1691
1679
  });
1692
- var stxSignTransactionsRequestMessageSchema = v53.object({
1680
+ var stxSignTransactionsRequestMessageSchema = v46.object({
1693
1681
  ...rpcRequestMessageSchema.entries,
1694
- ...v53.object({
1695
- method: v53.literal(stxSignTransactionsMethodName),
1682
+ ...v46.object({
1683
+ method: v46.literal(stxSignTransactionsMethodName),
1696
1684
  params: stxSignTransactionsParamsSchema,
1697
- id: v53.string()
1685
+ id: v46.string()
1698
1686
  }).entries
1699
1687
  });
1700
1688
 
1701
1689
  // src/request/types/stxMethods/transferStx.ts
1702
- import * as v54 from "valibot";
1690
+ import * as v47 from "valibot";
1703
1691
  var stxTransferStxMethodName = "stx_transferStx";
1704
- var stxTransferStxParamsSchema = v54.object({
1692
+ var stxTransferStxParamsSchema = v47.object({
1705
1693
  /**
1706
1694
  * Amount of STX tokens to transfer in microstacks as a string. Anything
1707
1695
  * parseable by `BigInt` is acceptable.
@@ -1714,23 +1702,23 @@ var stxTransferStxParamsSchema = v54.object({
1714
1702
  * const amount3 = '1234';
1715
1703
  * ```
1716
1704
  */
1717
- amount: v54.union([v54.number(), v54.string()]),
1705
+ amount: v47.union([v47.number(), v47.string()]),
1718
1706
  /**
1719
1707
  * The recipient's principal.
1720
1708
  */
1721
- recipient: v54.string(),
1709
+ recipient: v47.string(),
1722
1710
  /**
1723
1711
  * A string representing the memo.
1724
1712
  */
1725
- memo: v54.optional(v54.string()),
1713
+ memo: v47.optional(v47.string()),
1726
1714
  /**
1727
1715
  * Version of parameter format.
1728
1716
  */
1729
- version: v54.optional(v54.string()),
1717
+ version: v47.optional(v47.string()),
1730
1718
  /**
1731
1719
  * The mode of the post conditions.
1732
1720
  */
1733
- postConditionMode: v54.optional(v54.number()),
1721
+ postConditionMode: v47.optional(v47.number()),
1734
1722
  /**
1735
1723
  * A hex-encoded string representing the post conditions.
1736
1724
  *
@@ -1743,29 +1731,29 @@ var stxTransferStxParamsSchema = v54.object({
1743
1731
  * const hexPostCondition = serializePostCondition(postCondition).toString('hex');
1744
1732
  * ```
1745
1733
  */
1746
- postConditions: v54.optional(v54.array(v54.string())),
1734
+ postConditions: v47.optional(v47.array(v47.string())),
1747
1735
  /**
1748
1736
  * The public key to sign the transaction with. The wallet may use any key
1749
1737
  * when not provided.
1750
1738
  */
1751
- pubkey: v54.optional(v54.string())
1739
+ pubkey: v47.optional(v47.string())
1752
1740
  });
1753
- var stxTransferStxResultSchema = v54.object({
1741
+ var stxTransferStxResultSchema = v47.object({
1754
1742
  /**
1755
1743
  * The ID of the transaction.
1756
1744
  */
1757
- txid: v54.string(),
1745
+ txid: v47.string(),
1758
1746
  /**
1759
1747
  * A Stacks transaction as a hex-encoded string.
1760
1748
  */
1761
- transaction: v54.string()
1749
+ transaction: v47.string()
1762
1750
  });
1763
- var stxTransferStxRequestMessageSchema = v54.object({
1751
+ var stxTransferStxRequestMessageSchema = v47.object({
1764
1752
  ...rpcRequestMessageSchema.entries,
1765
- ...v54.object({
1766
- method: v54.literal(stxTransferStxMethodName),
1753
+ ...v47.object({
1754
+ method: v47.literal(stxTransferStxMethodName),
1767
1755
  params: stxTransferStxParamsSchema,
1768
- id: v54.string()
1756
+ id: v47.string()
1769
1757
  }).entries
1770
1758
  });
1771
1759
 
@@ -1773,13 +1761,13 @@ var stxTransferStxRequestMessageSchema = v54.object({
1773
1761
  var cache = {};
1774
1762
  var requestInternal = async (provider, method, params) => {
1775
1763
  const response = await provider.request(method, params);
1776
- if (v55.is(rpcErrorResponseMessageSchema, response)) {
1764
+ if (v48.is(rpcErrorResponseMessageSchema, response)) {
1777
1765
  return {
1778
1766
  status: "error",
1779
1767
  error: response.error
1780
1768
  };
1781
1769
  }
1782
- if (v55.is(rpcSuccessResponseMessageSchema, response)) {
1770
+ if (v48.is(rpcSuccessResponseMessageSchema, response)) {
1783
1771
  return {
1784
1772
  status: "success",
1785
1773
  result: response.result
@@ -2915,18 +2903,6 @@ export {
2915
2903
  isProviderInstalled,
2916
2904
  networkChangeEventName,
2917
2905
  networkChangeSchema,
2918
- openBridgeMethodName,
2919
- openBridgeParamsSchema,
2920
- openBridgeRequestMessageSchema,
2921
- openBridgeResultSchema,
2922
- openBuyMethodName,
2923
- openBuyParamsSchema,
2924
- openBuyRequestMessageSchema,
2925
- openBuyResultSchema,
2926
- openReceiveMethodName,
2927
- openReceiveParamsSchema,
2928
- openReceiveRequestMessageSchema,
2929
- openReceiveResultSchema,
2930
2906
  permission,
2931
2907
  removeDefaultProvider,
2932
2908
  renouncePermissionsMethodName,
@@ -2973,6 +2949,10 @@ export {
2973
2949
  signMessageParamsSchema,
2974
2950
  signMessageRequestMessageSchema,
2975
2951
  signMessageResultSchema,
2952
+ signMultipleMessagesMethodName,
2953
+ signMultipleMessagesParamsSchema,
2954
+ signMultipleMessagesRequestMessageSchema,
2955
+ signMultipleMessagesResultSchema,
2976
2956
  signMultipleTransactions,
2977
2957
  signPsbtMethodName,
2978
2958
  signPsbtParamsSchema,