@arkade-os/sdk 0.4.33 → 0.4.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (78) hide show
  1. package/README.md +1 -1
  2. package/dist/adapters/expo.cjs +5 -5
  3. package/dist/adapters/expo.d.cts +2 -2
  4. package/dist/adapters/expo.d.ts +2 -2
  5. package/dist/adapters/expo.js +3 -3
  6. package/dist/adapters/indexedDB.cjs +5 -5
  7. package/dist/adapters/indexedDB.js +4 -4
  8. package/dist/{ark-DEsDMYGv.d.cts → ark-Dsv5Jq4E.d.cts} +65 -7
  9. package/dist/{ark-DEsDMYGv.d.ts → ark-Dsv5Jq4E.d.ts} +65 -7
  10. package/dist/{asyncStorageTaskQueue-CMrTYlKG.d.ts → asyncStorageTaskQueue-BH-zuth5.d.ts} +1 -1
  11. package/dist/{asyncStorageTaskQueue-D8T1VXEx.d.cts → asyncStorageTaskQueue-D92ch8yI.d.cts} +1 -1
  12. package/dist/{chunk-L6ZETTX3.js → chunk-5WDBHWX3.js} +4 -4
  13. package/dist/{chunk-L6ZETTX3.js.map → chunk-5WDBHWX3.js.map} +1 -1
  14. package/dist/{chunk-5CCRRL5S.cjs → chunk-CCLNFHJ5.cjs} +11 -11
  15. package/dist/{chunk-5CCRRL5S.cjs.map → chunk-CCLNFHJ5.cjs.map} +1 -1
  16. package/dist/{chunk-WMIPYZSB.cjs → chunk-CMPJR3HS.cjs} +42 -9
  17. package/dist/chunk-CMPJR3HS.cjs.map +1 -0
  18. package/dist/{chunk-AOJUURHM.js → chunk-CUSABEUQ.js} +141 -37
  19. package/dist/chunk-CUSABEUQ.js.map +1 -0
  20. package/dist/{chunk-SPDNHPM4.cjs → chunk-FSAXPBGP.cjs} +8 -8
  21. package/dist/{chunk-SPDNHPM4.cjs.map → chunk-FSAXPBGP.cjs.map} +1 -1
  22. package/dist/{chunk-E22HEKLN.js → chunk-FXFBPXV3.js} +3 -3
  23. package/dist/{chunk-E22HEKLN.js.map → chunk-FXFBPXV3.js.map} +1 -1
  24. package/dist/{chunk-GYSK5R57.cjs → chunk-GUTKJMSF.cjs} +164 -59
  25. package/dist/chunk-GUTKJMSF.cjs.map +1 -0
  26. package/dist/{chunk-DSS2GQUG.js → chunk-HFXEUW55.js} +575 -155
  27. package/dist/chunk-HFXEUW55.js.map +1 -0
  28. package/dist/{chunk-TU3LVAPX.js → chunk-OUVTG72A.js} +43 -11
  29. package/dist/chunk-OUVTG72A.js.map +1 -0
  30. package/dist/{chunk-BU3BU6XK.js → chunk-VVGD3JIP.js} +3 -3
  31. package/dist/{chunk-BU3BU6XK.js.map → chunk-VVGD3JIP.js.map} +1 -1
  32. package/dist/{chunk-7K3ROJF6.cjs → chunk-XCHBQVMK.cjs} +718 -298
  33. package/dist/chunk-XCHBQVMK.cjs.map +1 -0
  34. package/dist/{chunk-HAVA4XB7.cjs → chunk-ZS3OZHC7.cjs} +7 -7
  35. package/dist/{chunk-HAVA4XB7.cjs.map → chunk-ZS3OZHC7.cjs.map} +1 -1
  36. package/dist/contracts/handlers/index.cjs +7 -7
  37. package/dist/contracts/handlers/index.d.cts +3 -3
  38. package/dist/contracts/handlers/index.d.ts +3 -3
  39. package/dist/contracts/handlers/index.js +2 -2
  40. package/dist/{delegate-BJeBNP5a.d.cts → delegate-BaS5SCIW.d.cts} +1 -1
  41. package/dist/{delegate-EXN2mfkb.d.ts → delegate-Baz_hb83.d.ts} +1 -1
  42. package/dist/{index-BG2ooYKO.d.ts → index-FwXZveaX.d.ts} +22 -16
  43. package/dist/{index-DHjEeHEp.d.cts → index-lNZ6qaO3.d.cts} +22 -16
  44. package/dist/index.cjs +134 -130
  45. package/dist/index.d.cts +63 -14
  46. package/dist/index.d.ts +63 -14
  47. package/dist/index.js +4 -4
  48. package/dist/repositories/realm/index.cjs +13 -13
  49. package/dist/repositories/realm/index.d.cts +1 -1
  50. package/dist/repositories/realm/index.d.ts +1 -1
  51. package/dist/repositories/realm/index.js +4 -4
  52. package/dist/repositories/sqlite/index.cjs +13 -13
  53. package/dist/repositories/sqlite/index.d.cts +1 -1
  54. package/dist/repositories/sqlite/index.d.ts +1 -1
  55. package/dist/repositories/sqlite/index.js +4 -4
  56. package/dist/{taskRunner-B7lBU45X.d.ts → taskRunner-B1NUWyWR.d.ts} +1 -1
  57. package/dist/{taskRunner-pIGyarFG.d.cts → taskRunner-vFRA3F9b.d.cts} +1 -1
  58. package/dist/wallet/expo/background.cjs +14 -14
  59. package/dist/wallet/expo/background.d.cts +3 -3
  60. package/dist/wallet/expo/background.d.ts +3 -3
  61. package/dist/wallet/expo/background.js +6 -6
  62. package/dist/wallet/expo/index.cjs +13 -13
  63. package/dist/wallet/expo/index.d.cts +5 -5
  64. package/dist/wallet/expo/index.d.ts +5 -5
  65. package/dist/wallet/expo/index.js +5 -5
  66. package/dist/{wallet-C4L_X0i6.d.ts → wallet-By9HIo0Q.d.cts} +160 -5
  67. package/dist/{wallet-D4Dll5Gu.d.cts → wallet-D6uoBLmS.d.ts} +160 -5
  68. package/dist/worker/expo/index.cjs +9 -9
  69. package/dist/worker/expo/index.d.cts +4 -4
  70. package/dist/worker/expo/index.d.ts +4 -4
  71. package/dist/worker/expo/index.js +5 -5
  72. package/package.json +4 -4
  73. package/dist/chunk-7K3ROJF6.cjs.map +0 -1
  74. package/dist/chunk-AOJUURHM.js.map +0 -1
  75. package/dist/chunk-DSS2GQUG.js.map +0 -1
  76. package/dist/chunk-GYSK5R57.cjs.map +0 -1
  77. package/dist/chunk-TU3LVAPX.js.map +0 -1
  78. package/dist/chunk-WMIPYZSB.cjs.map +0 -1
@@ -1,6 +1,6 @@
1
- import { W as WalletRepository, C as ContractRepository } from '../../ark-DEsDMYGv.js';
2
- import { A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-CMrTYlKG.js';
3
- import { T as TaskProcessor } from '../../taskRunner-B7lBU45X.js';
1
+ import { W as WalletRepository, C as ContractRepository } from '../../ark-Dsv5Jq4E.js';
2
+ import { A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-BH-zuth5.js';
3
+ import { T as TaskProcessor } from '../../taskRunner-B1NUWyWR.js';
4
4
  import '@scure/btc-signer/transaction.js';
5
5
  import '@scure/btc-signer/utils.js';
6
6
  import '@scure/btc-signer/psbt.js';
@@ -1,9 +1,9 @@
1
- import { contractPollProcessor, createTaskDependencies, runTasks, CONTRACT_POLL_TASK_TYPE } from '../../chunk-BU3BU6XK.js';
2
- import { ExpoIndexerProvider, ExpoArkProvider } from '../../chunk-L6ZETTX3.js';
3
- import { getRandomId } from '../../chunk-DSS2GQUG.js';
4
- import '../../chunk-E22HEKLN.js';
5
- import '../../chunk-AOJUURHM.js';
6
- import '../../chunk-TU3LVAPX.js';
1
+ import { contractPollProcessor, createTaskDependencies, runTasks, CONTRACT_POLL_TASK_TYPE } from '../../chunk-VVGD3JIP.js';
2
+ import { ExpoIndexerProvider, ExpoArkProvider } from '../../chunk-5WDBHWX3.js';
3
+ import { getRandomId } from '../../chunk-HFXEUW55.js';
4
+ import '../../chunk-FXFBPXV3.js';
5
+ import '../../chunk-CUSABEUQ.js';
6
+ import '../../chunk-OUVTG72A.js';
7
7
  import '../../chunk-NSBPE2FW.js';
8
8
  import * as TaskManager from 'expo-task-manager';
9
9
  import * as BackgroundTask from 'expo-background-task';
@@ -1,10 +1,10 @@
1
1
  'use strict';
2
2
 
3
- var chunkHAVA4XB7_cjs = require('../../chunk-HAVA4XB7.cjs');
4
- var chunk7K3ROJF6_cjs = require('../../chunk-7K3ROJF6.cjs');
5
- var chunkSPDNHPM4_cjs = require('../../chunk-SPDNHPM4.cjs');
6
- require('../../chunk-GYSK5R57.cjs');
7
- require('../../chunk-WMIPYZSB.cjs');
3
+ var chunkZS3OZHC7_cjs = require('../../chunk-ZS3OZHC7.cjs');
4
+ var chunkXCHBQVMK_cjs = require('../../chunk-XCHBQVMK.cjs');
5
+ var chunkFSAXPBGP_cjs = require('../../chunk-FSAXPBGP.cjs');
6
+ require('../../chunk-GUTKJMSF.cjs');
7
+ require('../../chunk-CMPJR3HS.cjs');
8
8
  require('../../chunk-5BLDMQED.cjs');
9
9
  var base = require('@scure/base');
10
10
 
@@ -52,18 +52,18 @@ var ExpoWallet = class _ExpoWallet {
52
52
  */
53
53
  static async setup(config) {
54
54
  warnOnRemovedBackgroundFields(config.background);
55
- const wallet = await chunk7K3ROJF6_cjs.Wallet.create(config);
56
- const processors = config.background.processors ?? [chunkHAVA4XB7_cjs.contractPollProcessor];
55
+ const wallet = await chunkXCHBQVMK_cjs.Wallet.create(config);
56
+ const processors = config.background.processors ?? [chunkZS3OZHC7_cjs.contractPollProcessor];
57
57
  const deps = {
58
58
  walletRepository: wallet.walletRepository,
59
59
  contractRepository: wallet.contractRepository,
60
60
  indexerProvider: wallet.indexerProvider,
61
61
  arkProvider: wallet.arkProvider,
62
- extendVtxo: (vtxo, contract) => chunk7K3ROJF6_cjs.extendVirtualCoinForContract(vtxo, contract)
62
+ extendVtxo: (vtxo, contract) => chunkXCHBQVMK_cjs.extendVirtualCoinForContract(vtxo, contract)
63
63
  };
64
64
  const { taskQueue } = config.background;
65
65
  if ("persistConfig" in taskQueue) {
66
- const arkServerUrl = config.arkServerUrl || (wallet.arkProvider instanceof chunkSPDNHPM4_cjs.RestArkProvider ? wallet.arkProvider.serverUrl : void 0);
66
+ const arkServerUrl = config.arkServerUrl || (wallet.arkProvider instanceof chunkFSAXPBGP_cjs.RestArkProvider ? wallet.arkProvider.serverUrl : void 0);
67
67
  if (arkServerUrl) {
68
68
  const timelock = wallet.offchainTapscript.options.csvTimelock;
69
69
  const bgConfig = {
@@ -93,7 +93,7 @@ var ExpoWallet = class _ExpoWallet {
93
93
  }, intervalMs);
94
94
  }
95
95
  async runForegroundPoll() {
96
- await chunkHAVA4XB7_cjs.runTasks(this.taskQueue, this.processors, this.deps);
96
+ await chunkZS3OZHC7_cjs.runTasks(this.taskQueue, this.processors, this.deps);
97
97
  const results = await this.taskQueue.getResults();
98
98
  if (results.length > 0) {
99
99
  await this.taskQueue.acknowledgeResults(results.map((r) => r.id));
@@ -101,11 +101,11 @@ var ExpoWallet = class _ExpoWallet {
101
101
  await this.seedContractPollTask();
102
102
  }
103
103
  async seedContractPollTask() {
104
- const existing = await this.taskQueue.getTasks(chunkHAVA4XB7_cjs.CONTRACT_POLL_TASK_TYPE);
104
+ const existing = await this.taskQueue.getTasks(chunkZS3OZHC7_cjs.CONTRACT_POLL_TASK_TYPE);
105
105
  if (existing.length > 0) return;
106
106
  const task = {
107
- id: chunk7K3ROJF6_cjs.getRandomId(),
108
- type: chunkHAVA4XB7_cjs.CONTRACT_POLL_TASK_TYPE,
107
+ id: chunkXCHBQVMK_cjs.getRandomId(),
108
+ type: chunkZS3OZHC7_cjs.CONTRACT_POLL_TASK_TYPE,
109
109
  data: {},
110
110
  createdAt: Date.now()
111
111
  };
@@ -1,11 +1,11 @@
1
- import { W as Wallet } from '../../wallet-D4Dll5Gu.cjs';
2
- import { I as IWallet, a as Identity, b as WalletConfig, c as WalletBalance, G as GetVtxosFilter, E as ExtendedVirtualCoin, d as ExtendedCoin, A as ArkTransaction, e as IContractManager, f as IDelegateManager, S as SendBitcoinParams, g as SettleParams, h as SettlementEvent, R as Recipient, i as IAssetManager } from '../../ark-DEsDMYGv.cjs';
3
- import { a as TaskQueue, T as TaskProcessor } from '../../taskRunner-pIGyarFG.cjs';
1
+ import { W as Wallet } from '../../wallet-By9HIo0Q.cjs';
2
+ import { I as IWallet, a as Identity, b as WalletConfig, c as WalletBalance, G as GetVtxosFilter, E as ExtendedVirtualCoin, d as ExtendedCoin, A as ArkTransaction, e as IContractManager, f as IDelegateManager, S as SendBitcoinParams, g as SettleParams, h as SettlementEvent, R as Recipient, i as IAssetManager } from '../../ark-Dsv5Jq4E.cjs';
3
+ import { a as TaskQueue, T as TaskProcessor } from '../../taskRunner-vFRA3F9b.cjs';
4
+ import '@scure/btc-signer';
4
5
  import '@scure/btc-signer/utils.js';
5
6
  import '@scure/btc-signer/psbt.js';
6
- import '../../delegate-BJeBNP5a.cjs';
7
+ import '../../delegate-BaS5SCIW.cjs';
7
8
  import '@scure/btc-signer/transaction.js';
8
- import '@scure/btc-signer';
9
9
 
10
10
  /**
11
11
  * Background processing configuration for @see ExpoWallet.
@@ -1,11 +1,11 @@
1
- import { W as Wallet } from '../../wallet-C4L_X0i6.js';
2
- import { I as IWallet, a as Identity, b as WalletConfig, c as WalletBalance, G as GetVtxosFilter, E as ExtendedVirtualCoin, d as ExtendedCoin, A as ArkTransaction, e as IContractManager, f as IDelegateManager, S as SendBitcoinParams, g as SettleParams, h as SettlementEvent, R as Recipient, i as IAssetManager } from '../../ark-DEsDMYGv.js';
3
- import { a as TaskQueue, T as TaskProcessor } from '../../taskRunner-B7lBU45X.js';
1
+ import { W as Wallet } from '../../wallet-D6uoBLmS.js';
2
+ import { I as IWallet, a as Identity, b as WalletConfig, c as WalletBalance, G as GetVtxosFilter, E as ExtendedVirtualCoin, d as ExtendedCoin, A as ArkTransaction, e as IContractManager, f as IDelegateManager, S as SendBitcoinParams, g as SettleParams, h as SettlementEvent, R as Recipient, i as IAssetManager } from '../../ark-Dsv5Jq4E.js';
3
+ import { a as TaskQueue, T as TaskProcessor } from '../../taskRunner-B1NUWyWR.js';
4
+ import '@scure/btc-signer';
4
5
  import '@scure/btc-signer/utils.js';
5
6
  import '@scure/btc-signer/psbt.js';
6
- import '../../delegate-EXN2mfkb.js';
7
+ import '../../delegate-Baz_hb83.js';
7
8
  import '@scure/btc-signer/transaction.js';
8
- import '@scure/btc-signer';
9
9
 
10
10
  /**
11
11
  * Background processing configuration for @see ExpoWallet.
@@ -1,8 +1,8 @@
1
- import { contractPollProcessor, runTasks, CONTRACT_POLL_TASK_TYPE } from '../../chunk-BU3BU6XK.js';
2
- import { Wallet, getRandomId, extendVirtualCoinForContract } from '../../chunk-DSS2GQUG.js';
3
- import { RestArkProvider } from '../../chunk-E22HEKLN.js';
4
- import '../../chunk-AOJUURHM.js';
5
- import '../../chunk-TU3LVAPX.js';
1
+ import { contractPollProcessor, runTasks, CONTRACT_POLL_TASK_TYPE } from '../../chunk-VVGD3JIP.js';
2
+ import { Wallet, getRandomId, extendVirtualCoinForContract } from '../../chunk-HFXEUW55.js';
3
+ import { RestArkProvider } from '../../chunk-FXFBPXV3.js';
4
+ import '../../chunk-CUSABEUQ.js';
5
+ import '../../chunk-OUVTG72A.js';
6
6
  import '../../chunk-NSBPE2FW.js';
7
7
  import { hex } from '@scure/base';
8
8
 
@@ -1,7 +1,8 @@
1
+ import { Transaction } from '@scure/btc-signer';
1
2
  import { Bytes } from '@scure/btc-signer/utils.js';
2
- import { B as BatchStartedEvent, v as TreeSigningStartedEvent, w as TxTree, x as TreeNoncesEvent, y as BatchFinalizationEvent, z as BatchFinalizedEvent, D as BatchFailedEvent, F as TreeTxEvent, H as TreeSignatureEvent, h as SettlementEvent, b as WalletConfig, W as WalletRepository, C as ContractRepository, J as DescriptorProvider, e as IContractManager, K as IReadonlyWallet, L as ReadonlyIdentity, N as Network, O as OnchainProvider, n as IndexerProvider, M as DelegateProvider, P as ReadonlyWalletConfig, o as RelativeTimelock, Q as IReadonlyAssetManager, m as ArkProvider, U as NetworkName, X as ArkInfo, Y as ArkAddress, c as WalletBalance, G as GetVtxosFilter, E as ExtendedVirtualCoin, A as ArkTransaction, d as ExtendedCoin, Z as Coin, _ as ContractManager, I as IWallet, $ as CSVMultisigTapscript, a as Identity, a0 as SettlementConfig, i as IAssetManager, a1 as VtxoManager, f as IDelegateManager, S as SendBitcoinParams, g as SettleParams, R as Recipient, a2 as SignerSession, a3 as SignedIntent, a4 as Intent } from './ark-DEsDMYGv.js';
3
+ import { B as BatchStartedEvent, s as TreeSigningStartedEvent, t as TxTree, u as TreeNoncesEvent, v as BatchFinalizationEvent, w as BatchFinalizedEvent, x as BatchFailedEvent, y as TreeTxEvent, z as TreeSignatureEvent, h as SettlementEvent, b as WalletConfig, W as WalletRepository, C as ContractRepository, D as DescriptorProvider, e as IContractManager, F as IReadonlyWallet, H as ReadonlyIdentity, N as Network, O as OnchainProvider, n as IndexerProvider, J as DelegateProvider, K as ReadonlyWalletConfig, o as RelativeTimelock, L as IReadonlyAssetManager, m as ArkProvider, M as NetworkName, P as ArkInfo, Q as ArkAddress, c as WalletBalance, G as GetVtxosFilter, E as ExtendedVirtualCoin, A as ArkTransaction, d as ExtendedCoin, U as Coin, X as ContractManager, I as IWallet, Y as CSVMultisigTapscript, a as Identity, Z as SettlementConfig, i as IAssetManager, _ as VtxoManager, f as IDelegateManager, S as SendBitcoinParams, g as SettleParams, R as Recipient, $ as SignerSession, a0 as SignedIntent, a1 as Intent } from './ark-Dsv5Jq4E.cjs';
3
4
  import { TransactionOutput } from '@scure/btc-signer/psbt.js';
4
- import { D as DefaultVtxo, a as DelegateVtxo } from './delegate-EXN2mfkb.js';
5
+ import { D as DefaultVtxo, a as DelegateVtxo } from './delegate-BaS5SCIW.cjs';
5
6
 
6
7
  /**
7
8
  * Batch namespace provides utilities for joining and processing batch session.
@@ -129,6 +130,17 @@ interface ReceiveRotatorBootOpts {
129
130
  * accidentally picking up a delegate contract or vice versa.
130
131
  */
131
132
  expectedContractType?: "default" | "delegate";
133
+ /**
134
+ * The wallet's baseline (index-0) receive pubkey — the x-only key the
135
+ * initial offchain tapscript is built from. Used by {@link
136
+ * WalletReceiveRotator.defaultBoot} as the no-tagged-row fallback:
137
+ * because boarding shares the single HD index stream, the raw watermark
138
+ * may have been advanced by a boarding-only allocation, so the boot must
139
+ * NOT derive the receive pubkey from it. A wallet with no tagged receive
140
+ * row has never rotated L2, so its correct current receive *is* the
141
+ * baseline index-0 key (plan §6-II.5).
142
+ */
143
+ baselineReceivePubKey?: Uint8Array;
132
144
  /**
133
145
  * Logger to receive rotation-failure + backoff diagnostics. Defaults
134
146
  * to `console` when omitted. Any object implementing
@@ -379,7 +391,6 @@ declare class ReadonlyWallet implements IReadonlyWallet {
379
391
  readonly onchainProvider: OnchainProvider;
380
392
  readonly indexerProvider: IndexerProvider;
381
393
  readonly arkServerPublicKey: Bytes;
382
- readonly boardingTapscript: DefaultVtxo.Script;
383
394
  readonly dustAmount: bigint;
384
395
  readonly walletRepository: WalletRepository;
385
396
  readonly contractRepository: ContractRepository;
@@ -399,6 +410,17 @@ declare class ReadonlyWallet implements IReadonlyWallet {
399
410
  * {@link WalletReceiveRotator.rotate} is the sole intended caller of.
400
411
  */
401
412
  protected _offchainTapscript: DefaultVtxo.Script | DelegateVtxo.Script;
413
+ /**
414
+ * Backing field for the current boarding tapscript (the QR / onboarding
415
+ * target). Read via the public `boardingTapscript` getter; written only
416
+ * by {@link Wallet.setBoardingTapscriptForRotation}, the sanctioned
417
+ * boarding-rotation write path (analogue of `_offchainTapscript`). It is
418
+ * a *current value*, not a fixed setup constant, because per-derivation
419
+ * boarding rotation (plan §6-II) swaps it when a fresh boarding address
420
+ * is explicitly allocated. Static / `auto` wallets never rotate it, so
421
+ * it stays the index-0 baseline for their lifetime.
422
+ */
423
+ protected _boardingTapscript: DefaultVtxo.Script;
402
424
  protected constructor(identity: ReadonlyIdentity, network: Network, onchainProvider: OnchainProvider, indexerProvider: IndexerProvider, arkServerPublicKey: Bytes, offchainTapscript: DefaultVtxo.Script | DelegateVtxo.Script, boardingTapscript: DefaultVtxo.Script, dustAmount: bigint, walletRepository: WalletRepository, contractRepository: ContractRepository, delegateProvider?: DelegateProvider | undefined, watcherConfig?: ReadonlyWalletConfig["watcherConfig"], walletContractTimelocks?: RelativeTimelock[]);
403
425
  /**
404
426
  * Currently-active receive tapscript. Read-only from the outside;
@@ -406,6 +428,37 @@ declare class ReadonlyWallet implements IReadonlyWallet {
406
428
  * by {@link WalletReceiveRotator.rotate}.
407
429
  */
408
430
  get offchainTapscript(): DefaultVtxo.Script | DelegateVtxo.Script;
431
+ /**
432
+ * The wallet's current boarding tapscript (the on-chain onboarding
433
+ * target). Read-only from the outside; mutated only via
434
+ * {@link Wallet.setBoardingTapscriptForRotation} when a fresh boarding
435
+ * address is explicitly allocated. Single-valued for static / `auto`
436
+ * wallets.
437
+ */
438
+ get boardingTapscript(): DefaultVtxo.Script;
439
+ /**
440
+ * Listeners fired after the boarding tapscript rotates to a fresh index
441
+ * (see {@link Wallet.setBoardingTapscriptForRotation}). A live
442
+ * {@link notifyIncomingFunds} onchain watcher registers one so it can
443
+ * re-subscribe to include the newly allocated boarding address within the
444
+ * same session — without it, a deposit to the fresh address wouldn't fire
445
+ * a notification until the watcher's next re-init. Always empty for
446
+ * readonly / static / `auto` wallets, which never rotate boarding.
447
+ */
448
+ private readonly _boardingRotationListeners;
449
+ /**
450
+ * Register a listener invoked synchronously after each boarding rotation.
451
+ * Returns an unsubscribe function. Protected: only internal subscribers
452
+ * (the incoming-funds watcher) participate.
453
+ */
454
+ protected onBoardingRotation(listener: () => void): () => void;
455
+ /**
456
+ * Notify boarding-rotation listeners. Called by the boarding-rotation
457
+ * write path ({@link Wallet.setBoardingTapscriptForRotation}) once the new
458
+ * tapscript is in place. A throwing listener is isolated so it can neither
459
+ * break the rotation nor starve sibling listeners.
460
+ */
461
+ protected notifyBoardingRotation(): void;
409
462
  /**
410
463
  * Protected helper to set up shared wallet configuration.
411
464
  * Extracts common logic used by both ReadonlyWallet.create() and Wallet.create().
@@ -465,19 +518,54 @@ declare class ReadonlyWallet implements IReadonlyWallet {
465
518
  */
466
519
  clearSyncCursor(): Promise<void>;
467
520
  /**
468
- * Build a transaction history view for the wallet's boarding address.
521
+ * The on-chain (P2TR) addresses of every boarding tapscript this wallet
522
+ * uses — the current address plus any historical rotated boarding
523
+ * addresses. The aggregating boarding readers (history, notifications) fan
524
+ * out over this set so deposits at previous boarding addresses are still
525
+ * surfaced (plan §6-IV); {@link getBoardingAddress} stays single-valued.
526
+ */
527
+ getBoardingAddresses(): Promise<string[]>;
528
+ /**
529
+ * Build a transaction history view across the wallet's boarding addresses
530
+ * (current + historical rotated; plan §6-IV.1).
469
531
  */
470
532
  getBoardingTxs(): Promise<{
471
533
  boardingTxs: ArkTransaction[];
472
534
  commitmentsToIgnore: Set<string>;
473
535
  }>;
474
536
  /**
475
- * Fetch and cache onchain inputs (UTXOs) received at the boarding address.
537
+ * The set of boarding tapscripts whose on-chain UTXOs belong to this
538
+ * wallet — the current display tapscript plus every historical boarding
539
+ * address it has used. Under per-derivation rotation (plan §6-II) a wallet
540
+ * can hold unspent boarding UTXOs at several addresses at once, so fund
541
+ * discovery / spending must enumerate them all, not just the current one
542
+ * (plan §6-III.1). Deduplicated by scriptPubKey.
543
+ *
544
+ * Always includes the index-0 baseline (identity x-only key), which covers
545
+ * the degenerate equal-delay case where the index-0 boarding row is
546
+ * coalesced onto a `default` row and so isn't a `boarding`-typed contract.
547
+ */
548
+ protected getBoardingTapscripts(): Promise<DefaultVtxo.Script[]>;
549
+ /**
550
+ * Fetch and cache onchain inputs (UTXOs) received at the wallet's boarding
551
+ * addresses — the current address plus any historical rotated boarding
552
+ * addresses that still hold unspent UTXOs (plan §6-III.1). Each UTXO is
553
+ * annotated with the tapscript of the address it actually sits on, so the
554
+ * spending path forfeits / exits it with the correct per-index leaves.
476
555
  */
477
556
  getBoardingUtxos(): Promise<ExtendedCoin[]>;
478
557
  /**
479
558
  * Subscribe to onchain and offchain notifications for newly received funds.
480
559
  *
560
+ * The onchain watcher tracks the full boarding-address set (current +
561
+ * historical rotated). When boarding rotates *after* subscribing — e.g.
562
+ * rotate-on-board allocates a fresh address via
563
+ * {@link getNewBoardingAddress} — the watcher automatically re-subscribes
564
+ * to widen its set, so a deposit to the new address fires a notification
565
+ * within the same session (no watcher re-init required). The re-subscribe
566
+ * is driven by {@link onBoardingRotation}; static / `auto` / readonly
567
+ * wallets never rotate boarding, so it never fires for them.
568
+ *
481
569
  * @param eventCallback - Callback invoked when matching funds are detected
482
570
  * @returns A function that stops the subscriptions
483
571
  */
@@ -598,6 +686,39 @@ declare class Wallet extends ReadonlyWallet implements IWallet {
598
686
  * `offchainTapscript` as read-only.
599
687
  */
600
688
  setOffchainTapscriptForRotation(tapscript: DefaultVtxo.Script | DelegateVtxo.Script): void;
689
+ /**
690
+ * @internal Sole write path for `boardingTapscript` after construction.
691
+ * Called by {@link Wallet.getNewBoardingAddress} once the rotated
692
+ * boarding contract has been persisted. External code must treat
693
+ * `boardingTapscript` as read-only.
694
+ */
695
+ setBoardingTapscriptForRotation(tapscript: DefaultVtxo.Script): void;
696
+ /**
697
+ * Allocate and return a *fresh* on-chain boarding address, rotating the
698
+ * wallet's current boarding tapscript to a new HD index.
699
+ *
700
+ * This is the explicit boarding allocator — the analogue of dotnet's
701
+ * `GetNextContract(NextContractPurpose.Boarding)`. Unlike
702
+ * {@link getBoardingAddress} (a stable read of the current display
703
+ * address that never burns an index), each call here:
704
+ *
705
+ * - allocates the next index from the shared HD stream (so boarding and
706
+ * L2 receive interleave on one monotonic index);
707
+ * - builds the boarding tapscript at that index with the boarding-exit
708
+ * CSV;
709
+ * - persists an `active` `boarding` contract tagged
710
+ * {@link WALLET_RECEIVE_SOURCE} (with its `signingDescriptor`) so the
711
+ * ContractWatcher monitors it, boot can restore it as the current
712
+ * boarding address, and descriptor-aware signing can recover the
713
+ * per-index key;
714
+ * - swaps the wallet's current `boardingTapscript`.
715
+ *
716
+ * Gated by `walletMode`: a static / `auto` wallet has no descriptor
717
+ * provider and keeps a single index-0 boarding address for its lifetime,
718
+ * so this returns the existing {@link getBoardingAddress} unchanged
719
+ * (no rotation, no index burned).
720
+ */
721
+ getNewBoardingAddress(): Promise<string>;
601
722
  /**
602
723
  * Async mutex that serializes all operations submitting VTXOs to the Arkade
603
724
  * server (`settle`, `send`, `sendBitcoin`). This prevents VtxoManager's
@@ -706,6 +827,30 @@ declare class Wallet extends ReadonlyWallet implements IWallet {
706
827
  */
707
828
  settle(params?: SettleParams, eventCallback?: (event: SettlementEvent) => void): Promise<string>;
708
829
  private _settleImpl;
830
+ /**
831
+ * Rotate the boarding address after a board (rotate-on-board trigger).
832
+ *
833
+ * Mirrors {@link WalletReceiveRotator}'s L2 rotation, but driven by a
834
+ * board instead of a `vtxo_received` event: when a settle consumes at
835
+ * least one boarding (on-chain) UTXO, the current boarding address has
836
+ * served its purpose, so we allocate a fresh one via
837
+ * {@link getNewBoardingAddress}. A settle that consumed only VTXOs (a
838
+ * renewal / offboard) is not a board and leaves the boarding address
839
+ * untouched.
840
+ *
841
+ * Boarding inputs are the non-VTXO coins (no `virtualStatus`), the same
842
+ * discriminator {@link handleSettlementFinalizationEvent} uses; the
843
+ * `typeof` guard skips arknote string inputs before the `in` test.
844
+ *
845
+ * No-ops for static / `auto` wallets (no descriptor provider — boarding
846
+ * stays on its fixed index-0 address). Best-effort and non-fatal: the
847
+ * settle has already committed and its txid must be returned, so a
848
+ * rotation failure is logged and swallowed rather than thrown. Funds at
849
+ * the retired boarding address remain discoverable — the old `boarding`
850
+ * contract stays active and {@link getBoardingUtxos} fans out over the
851
+ * full historical boarding set.
852
+ */
853
+ private maybeRotateBoardingAfterBoard;
709
854
  private handleSettlementFinalizationEvent;
710
855
  /**
711
856
  * Create a batch event handler for settlement flows.
@@ -723,6 +868,16 @@ declare class Wallet extends ReadonlyWallet implements IWallet {
723
868
  * historical silent-skip behaviour for cosigner/connector inputs.
724
869
  */
725
870
  private inputSigningJobsFromWitnessUtxos;
871
+ /**
872
+ * @internal Sign an on-chain boarding exit / sweep transaction, routing
873
+ * each input to the correct key by its `witnessUtxo.script`: the identity
874
+ * for index-0 / static boarding, the per-index descriptor for a rotated
875
+ * boarding UTXO (plan §6-III.3). Used by
876
+ * {@link VtxoManager.sweepExpiredBoardingUtxos}; without it, the
877
+ * unilateral exit of a rotated boarding UTXO would be signed with the
878
+ * wrong (index-0) key and rejected.
879
+ */
880
+ signOnchainBoardingTx(tx: Transaction): Promise<Transaction>;
726
881
  safeRegisterIntent(intent: SignedIntent<Intent.RegisterMessage>, inputs: ExtendedCoin[]): Promise<string>;
727
882
  makeRegisterIntentSignature(coins: ExtendedCoin[], outputs: TransactionOutput[], onchainOutputsIndexes: number[], cosignerPubKeys: string[], validAt?: number): Promise<SignedIntent<Intent.RegisterMessage>>;
728
883
  makeDeleteIntentSignature(coins: ExtendedCoin[]): Promise<SignedIntent<Intent.DeleteMessage>>;
@@ -1,7 +1,8 @@
1
+ import { Transaction } from '@scure/btc-signer';
1
2
  import { Bytes } from '@scure/btc-signer/utils.js';
2
- import { B as BatchStartedEvent, v as TreeSigningStartedEvent, w as TxTree, x as TreeNoncesEvent, y as BatchFinalizationEvent, z as BatchFinalizedEvent, D as BatchFailedEvent, F as TreeTxEvent, H as TreeSignatureEvent, h as SettlementEvent, b as WalletConfig, W as WalletRepository, C as ContractRepository, J as DescriptorProvider, e as IContractManager, K as IReadonlyWallet, L as ReadonlyIdentity, N as Network, O as OnchainProvider, n as IndexerProvider, M as DelegateProvider, P as ReadonlyWalletConfig, o as RelativeTimelock, Q as IReadonlyAssetManager, m as ArkProvider, U as NetworkName, X as ArkInfo, Y as ArkAddress, c as WalletBalance, G as GetVtxosFilter, E as ExtendedVirtualCoin, A as ArkTransaction, d as ExtendedCoin, Z as Coin, _ as ContractManager, I as IWallet, $ as CSVMultisigTapscript, a as Identity, a0 as SettlementConfig, i as IAssetManager, a1 as VtxoManager, f as IDelegateManager, S as SendBitcoinParams, g as SettleParams, R as Recipient, a2 as SignerSession, a3 as SignedIntent, a4 as Intent } from './ark-DEsDMYGv.cjs';
3
+ import { B as BatchStartedEvent, s as TreeSigningStartedEvent, t as TxTree, u as TreeNoncesEvent, v as BatchFinalizationEvent, w as BatchFinalizedEvent, x as BatchFailedEvent, y as TreeTxEvent, z as TreeSignatureEvent, h as SettlementEvent, b as WalletConfig, W as WalletRepository, C as ContractRepository, D as DescriptorProvider, e as IContractManager, F as IReadonlyWallet, H as ReadonlyIdentity, N as Network, O as OnchainProvider, n as IndexerProvider, J as DelegateProvider, K as ReadonlyWalletConfig, o as RelativeTimelock, L as IReadonlyAssetManager, m as ArkProvider, M as NetworkName, P as ArkInfo, Q as ArkAddress, c as WalletBalance, G as GetVtxosFilter, E as ExtendedVirtualCoin, A as ArkTransaction, d as ExtendedCoin, U as Coin, X as ContractManager, I as IWallet, Y as CSVMultisigTapscript, a as Identity, Z as SettlementConfig, i as IAssetManager, _ as VtxoManager, f as IDelegateManager, S as SendBitcoinParams, g as SettleParams, R as Recipient, $ as SignerSession, a0 as SignedIntent, a1 as Intent } from './ark-Dsv5Jq4E.js';
3
4
  import { TransactionOutput } from '@scure/btc-signer/psbt.js';
4
- import { D as DefaultVtxo, a as DelegateVtxo } from './delegate-BJeBNP5a.cjs';
5
+ import { D as DefaultVtxo, a as DelegateVtxo } from './delegate-Baz_hb83.js';
5
6
 
6
7
  /**
7
8
  * Batch namespace provides utilities for joining and processing batch session.
@@ -129,6 +130,17 @@ interface ReceiveRotatorBootOpts {
129
130
  * accidentally picking up a delegate contract or vice versa.
130
131
  */
131
132
  expectedContractType?: "default" | "delegate";
133
+ /**
134
+ * The wallet's baseline (index-0) receive pubkey — the x-only key the
135
+ * initial offchain tapscript is built from. Used by {@link
136
+ * WalletReceiveRotator.defaultBoot} as the no-tagged-row fallback:
137
+ * because boarding shares the single HD index stream, the raw watermark
138
+ * may have been advanced by a boarding-only allocation, so the boot must
139
+ * NOT derive the receive pubkey from it. A wallet with no tagged receive
140
+ * row has never rotated L2, so its correct current receive *is* the
141
+ * baseline index-0 key (plan §6-II.5).
142
+ */
143
+ baselineReceivePubKey?: Uint8Array;
132
144
  /**
133
145
  * Logger to receive rotation-failure + backoff diagnostics. Defaults
134
146
  * to `console` when omitted. Any object implementing
@@ -379,7 +391,6 @@ declare class ReadonlyWallet implements IReadonlyWallet {
379
391
  readonly onchainProvider: OnchainProvider;
380
392
  readonly indexerProvider: IndexerProvider;
381
393
  readonly arkServerPublicKey: Bytes;
382
- readonly boardingTapscript: DefaultVtxo.Script;
383
394
  readonly dustAmount: bigint;
384
395
  readonly walletRepository: WalletRepository;
385
396
  readonly contractRepository: ContractRepository;
@@ -399,6 +410,17 @@ declare class ReadonlyWallet implements IReadonlyWallet {
399
410
  * {@link WalletReceiveRotator.rotate} is the sole intended caller of.
400
411
  */
401
412
  protected _offchainTapscript: DefaultVtxo.Script | DelegateVtxo.Script;
413
+ /**
414
+ * Backing field for the current boarding tapscript (the QR / onboarding
415
+ * target). Read via the public `boardingTapscript` getter; written only
416
+ * by {@link Wallet.setBoardingTapscriptForRotation}, the sanctioned
417
+ * boarding-rotation write path (analogue of `_offchainTapscript`). It is
418
+ * a *current value*, not a fixed setup constant, because per-derivation
419
+ * boarding rotation (plan §6-II) swaps it when a fresh boarding address
420
+ * is explicitly allocated. Static / `auto` wallets never rotate it, so
421
+ * it stays the index-0 baseline for their lifetime.
422
+ */
423
+ protected _boardingTapscript: DefaultVtxo.Script;
402
424
  protected constructor(identity: ReadonlyIdentity, network: Network, onchainProvider: OnchainProvider, indexerProvider: IndexerProvider, arkServerPublicKey: Bytes, offchainTapscript: DefaultVtxo.Script | DelegateVtxo.Script, boardingTapscript: DefaultVtxo.Script, dustAmount: bigint, walletRepository: WalletRepository, contractRepository: ContractRepository, delegateProvider?: DelegateProvider | undefined, watcherConfig?: ReadonlyWalletConfig["watcherConfig"], walletContractTimelocks?: RelativeTimelock[]);
403
425
  /**
404
426
  * Currently-active receive tapscript. Read-only from the outside;
@@ -406,6 +428,37 @@ declare class ReadonlyWallet implements IReadonlyWallet {
406
428
  * by {@link WalletReceiveRotator.rotate}.
407
429
  */
408
430
  get offchainTapscript(): DefaultVtxo.Script | DelegateVtxo.Script;
431
+ /**
432
+ * The wallet's current boarding tapscript (the on-chain onboarding
433
+ * target). Read-only from the outside; mutated only via
434
+ * {@link Wallet.setBoardingTapscriptForRotation} when a fresh boarding
435
+ * address is explicitly allocated. Single-valued for static / `auto`
436
+ * wallets.
437
+ */
438
+ get boardingTapscript(): DefaultVtxo.Script;
439
+ /**
440
+ * Listeners fired after the boarding tapscript rotates to a fresh index
441
+ * (see {@link Wallet.setBoardingTapscriptForRotation}). A live
442
+ * {@link notifyIncomingFunds} onchain watcher registers one so it can
443
+ * re-subscribe to include the newly allocated boarding address within the
444
+ * same session — without it, a deposit to the fresh address wouldn't fire
445
+ * a notification until the watcher's next re-init. Always empty for
446
+ * readonly / static / `auto` wallets, which never rotate boarding.
447
+ */
448
+ private readonly _boardingRotationListeners;
449
+ /**
450
+ * Register a listener invoked synchronously after each boarding rotation.
451
+ * Returns an unsubscribe function. Protected: only internal subscribers
452
+ * (the incoming-funds watcher) participate.
453
+ */
454
+ protected onBoardingRotation(listener: () => void): () => void;
455
+ /**
456
+ * Notify boarding-rotation listeners. Called by the boarding-rotation
457
+ * write path ({@link Wallet.setBoardingTapscriptForRotation}) once the new
458
+ * tapscript is in place. A throwing listener is isolated so it can neither
459
+ * break the rotation nor starve sibling listeners.
460
+ */
461
+ protected notifyBoardingRotation(): void;
409
462
  /**
410
463
  * Protected helper to set up shared wallet configuration.
411
464
  * Extracts common logic used by both ReadonlyWallet.create() and Wallet.create().
@@ -465,19 +518,54 @@ declare class ReadonlyWallet implements IReadonlyWallet {
465
518
  */
466
519
  clearSyncCursor(): Promise<void>;
467
520
  /**
468
- * Build a transaction history view for the wallet's boarding address.
521
+ * The on-chain (P2TR) addresses of every boarding tapscript this wallet
522
+ * uses — the current address plus any historical rotated boarding
523
+ * addresses. The aggregating boarding readers (history, notifications) fan
524
+ * out over this set so deposits at previous boarding addresses are still
525
+ * surfaced (plan §6-IV); {@link getBoardingAddress} stays single-valued.
526
+ */
527
+ getBoardingAddresses(): Promise<string[]>;
528
+ /**
529
+ * Build a transaction history view across the wallet's boarding addresses
530
+ * (current + historical rotated; plan §6-IV.1).
469
531
  */
470
532
  getBoardingTxs(): Promise<{
471
533
  boardingTxs: ArkTransaction[];
472
534
  commitmentsToIgnore: Set<string>;
473
535
  }>;
474
536
  /**
475
- * Fetch and cache onchain inputs (UTXOs) received at the boarding address.
537
+ * The set of boarding tapscripts whose on-chain UTXOs belong to this
538
+ * wallet — the current display tapscript plus every historical boarding
539
+ * address it has used. Under per-derivation rotation (plan §6-II) a wallet
540
+ * can hold unspent boarding UTXOs at several addresses at once, so fund
541
+ * discovery / spending must enumerate them all, not just the current one
542
+ * (plan §6-III.1). Deduplicated by scriptPubKey.
543
+ *
544
+ * Always includes the index-0 baseline (identity x-only key), which covers
545
+ * the degenerate equal-delay case where the index-0 boarding row is
546
+ * coalesced onto a `default` row and so isn't a `boarding`-typed contract.
547
+ */
548
+ protected getBoardingTapscripts(): Promise<DefaultVtxo.Script[]>;
549
+ /**
550
+ * Fetch and cache onchain inputs (UTXOs) received at the wallet's boarding
551
+ * addresses — the current address plus any historical rotated boarding
552
+ * addresses that still hold unspent UTXOs (plan §6-III.1). Each UTXO is
553
+ * annotated with the tapscript of the address it actually sits on, so the
554
+ * spending path forfeits / exits it with the correct per-index leaves.
476
555
  */
477
556
  getBoardingUtxos(): Promise<ExtendedCoin[]>;
478
557
  /**
479
558
  * Subscribe to onchain and offchain notifications for newly received funds.
480
559
  *
560
+ * The onchain watcher tracks the full boarding-address set (current +
561
+ * historical rotated). When boarding rotates *after* subscribing — e.g.
562
+ * rotate-on-board allocates a fresh address via
563
+ * {@link getNewBoardingAddress} — the watcher automatically re-subscribes
564
+ * to widen its set, so a deposit to the new address fires a notification
565
+ * within the same session (no watcher re-init required). The re-subscribe
566
+ * is driven by {@link onBoardingRotation}; static / `auto` / readonly
567
+ * wallets never rotate boarding, so it never fires for them.
568
+ *
481
569
  * @param eventCallback - Callback invoked when matching funds are detected
482
570
  * @returns A function that stops the subscriptions
483
571
  */
@@ -598,6 +686,39 @@ declare class Wallet extends ReadonlyWallet implements IWallet {
598
686
  * `offchainTapscript` as read-only.
599
687
  */
600
688
  setOffchainTapscriptForRotation(tapscript: DefaultVtxo.Script | DelegateVtxo.Script): void;
689
+ /**
690
+ * @internal Sole write path for `boardingTapscript` after construction.
691
+ * Called by {@link Wallet.getNewBoardingAddress} once the rotated
692
+ * boarding contract has been persisted. External code must treat
693
+ * `boardingTapscript` as read-only.
694
+ */
695
+ setBoardingTapscriptForRotation(tapscript: DefaultVtxo.Script): void;
696
+ /**
697
+ * Allocate and return a *fresh* on-chain boarding address, rotating the
698
+ * wallet's current boarding tapscript to a new HD index.
699
+ *
700
+ * This is the explicit boarding allocator — the analogue of dotnet's
701
+ * `GetNextContract(NextContractPurpose.Boarding)`. Unlike
702
+ * {@link getBoardingAddress} (a stable read of the current display
703
+ * address that never burns an index), each call here:
704
+ *
705
+ * - allocates the next index from the shared HD stream (so boarding and
706
+ * L2 receive interleave on one monotonic index);
707
+ * - builds the boarding tapscript at that index with the boarding-exit
708
+ * CSV;
709
+ * - persists an `active` `boarding` contract tagged
710
+ * {@link WALLET_RECEIVE_SOURCE} (with its `signingDescriptor`) so the
711
+ * ContractWatcher monitors it, boot can restore it as the current
712
+ * boarding address, and descriptor-aware signing can recover the
713
+ * per-index key;
714
+ * - swaps the wallet's current `boardingTapscript`.
715
+ *
716
+ * Gated by `walletMode`: a static / `auto` wallet has no descriptor
717
+ * provider and keeps a single index-0 boarding address for its lifetime,
718
+ * so this returns the existing {@link getBoardingAddress} unchanged
719
+ * (no rotation, no index burned).
720
+ */
721
+ getNewBoardingAddress(): Promise<string>;
601
722
  /**
602
723
  * Async mutex that serializes all operations submitting VTXOs to the Arkade
603
724
  * server (`settle`, `send`, `sendBitcoin`). This prevents VtxoManager's
@@ -706,6 +827,30 @@ declare class Wallet extends ReadonlyWallet implements IWallet {
706
827
  */
707
828
  settle(params?: SettleParams, eventCallback?: (event: SettlementEvent) => void): Promise<string>;
708
829
  private _settleImpl;
830
+ /**
831
+ * Rotate the boarding address after a board (rotate-on-board trigger).
832
+ *
833
+ * Mirrors {@link WalletReceiveRotator}'s L2 rotation, but driven by a
834
+ * board instead of a `vtxo_received` event: when a settle consumes at
835
+ * least one boarding (on-chain) UTXO, the current boarding address has
836
+ * served its purpose, so we allocate a fresh one via
837
+ * {@link getNewBoardingAddress}. A settle that consumed only VTXOs (a
838
+ * renewal / offboard) is not a board and leaves the boarding address
839
+ * untouched.
840
+ *
841
+ * Boarding inputs are the non-VTXO coins (no `virtualStatus`), the same
842
+ * discriminator {@link handleSettlementFinalizationEvent} uses; the
843
+ * `typeof` guard skips arknote string inputs before the `in` test.
844
+ *
845
+ * No-ops for static / `auto` wallets (no descriptor provider — boarding
846
+ * stays on its fixed index-0 address). Best-effort and non-fatal: the
847
+ * settle has already committed and its txid must be returned, so a
848
+ * rotation failure is logged and swallowed rather than thrown. Funds at
849
+ * the retired boarding address remain discoverable — the old `boarding`
850
+ * contract stays active and {@link getBoardingUtxos} fans out over the
851
+ * full historical boarding set.
852
+ */
853
+ private maybeRotateBoardingAfterBoard;
709
854
  private handleSettlementFinalizationEvent;
710
855
  /**
711
856
  * Create a batch event handler for settlement flows.
@@ -723,6 +868,16 @@ declare class Wallet extends ReadonlyWallet implements IWallet {
723
868
  * historical silent-skip behaviour for cosigner/connector inputs.
724
869
  */
725
870
  private inputSigningJobsFromWitnessUtxos;
871
+ /**
872
+ * @internal Sign an on-chain boarding exit / sweep transaction, routing
873
+ * each input to the correct key by its `witnessUtxo.script`: the identity
874
+ * for index-0 / static boarding, the per-index descriptor for a rotated
875
+ * boarding UTXO (plan §6-III.3). Used by
876
+ * {@link VtxoManager.sweepExpiredBoardingUtxos}; without it, the
877
+ * unilateral exit of a rotated boarding UTXO would be signed with the
878
+ * wrong (index-0) key and rejected.
879
+ */
880
+ signOnchainBoardingTx(tx: Transaction): Promise<Transaction>;
726
881
  safeRegisterIntent(intent: SignedIntent<Intent.RegisterMessage>, inputs: ExtendedCoin[]): Promise<string>;
727
882
  makeRegisterIntentSignature(coins: ExtendedCoin[], outputs: TransactionOutput[], onchainOutputsIndexes: number[], cosignerPubKeys: string[], validAt?: number): Promise<SignedIntent<Intent.RegisterMessage>>;
728
883
  makeDeleteIntentSignature(coins: ExtendedCoin[]): Promise<SignedIntent<Intent.DeleteMessage>>;