@sats-connect/core 0.16.0-2dd02aa → 0.16.0-55e197a

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