@bsv/wallet-toolbox 1.7.18 → 2.0.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (606) hide show
  1. package/out/src/sdk/validationHelpers.d.ts +303 -0
  2. package/out/src/sdk/validationHelpers.d.ts.map +1 -0
  3. package/out/src/sdk/validationHelpers.js +632 -0
  4. package/out/src/sdk/validationHelpers.js.map +1 -0
  5. package/package.json +9 -2
  6. package/.env.template +0 -22
  7. package/.github/ISSUE_TEMPLATE/bug_report.md +0 -40
  8. package/.github/ISSUE_TEMPLATE/discussion.md +0 -24
  9. package/.github/pull_request_template.md +0 -22
  10. package/.github/workflows/push.yaml +0 -145
  11. package/.prettierrc +0 -10
  12. package/CONTRIBUTING.md +0 -89
  13. package/jest.config.ts +0 -25
  14. package/out/test/Wallet/StorageClient/storageClient.man.test.d.ts +0 -2
  15. package/out/test/Wallet/StorageClient/storageClient.man.test.d.ts.map +0 -1
  16. package/out/test/Wallet/StorageClient/storageClient.man.test.js +0 -64
  17. package/out/test/Wallet/StorageClient/storageClient.man.test.js.map +0 -1
  18. package/out/test/Wallet/action/internalizeAction.a.test.d.ts +0 -2
  19. package/out/test/Wallet/action/internalizeAction.a.test.d.ts.map +0 -1
  20. package/out/test/Wallet/action/internalizeAction.a.test.js +0 -243
  21. package/out/test/Wallet/action/internalizeAction.a.test.js.map +0 -1
  22. package/out/test/Wallet/certificate/acquireCertificate.test.d.ts +0 -2
  23. package/out/test/Wallet/certificate/acquireCertificate.test.d.ts.map +0 -1
  24. package/out/test/Wallet/certificate/acquireCertificate.test.js +0 -210
  25. package/out/test/Wallet/certificate/acquireCertificate.test.js.map +0 -1
  26. package/out/test/Wallet/certificate/listCertificates.test.d.ts +0 -2
  27. package/out/test/Wallet/certificate/listCertificates.test.d.ts.map +0 -1
  28. package/out/test/Wallet/certificate/listCertificates.test.js +0 -305
  29. package/out/test/Wallet/certificate/listCertificates.test.js.map +0 -1
  30. package/out/test/Wallet/get/getHeaderForHeight.test.d.ts +0 -2
  31. package/out/test/Wallet/get/getHeaderForHeight.test.d.ts.map +0 -1
  32. package/out/test/Wallet/get/getHeaderForHeight.test.js +0 -74
  33. package/out/test/Wallet/get/getHeaderForHeight.test.js.map +0 -1
  34. package/out/test/Wallet/get/getHeight.test.d.ts +0 -2
  35. package/out/test/Wallet/get/getHeight.test.d.ts.map +0 -1
  36. package/out/test/Wallet/get/getHeight.test.js +0 -48
  37. package/out/test/Wallet/get/getHeight.test.js.map +0 -1
  38. package/out/test/Wallet/get/getKnownTxids.test.d.ts +0 -2
  39. package/out/test/Wallet/get/getKnownTxids.test.d.ts.map +0 -1
  40. package/out/test/Wallet/get/getKnownTxids.test.js +0 -73
  41. package/out/test/Wallet/get/getKnownTxids.test.js.map +0 -1
  42. package/out/test/Wallet/get/getNetwork.test.d.ts +0 -2
  43. package/out/test/Wallet/get/getNetwork.test.d.ts.map +0 -1
  44. package/out/test/Wallet/get/getNetwork.test.js +0 -26
  45. package/out/test/Wallet/get/getNetwork.test.js.map +0 -1
  46. package/out/test/Wallet/get/getVersion.test.d.ts +0 -2
  47. package/out/test/Wallet/get/getVersion.test.d.ts.map +0 -1
  48. package/out/test/Wallet/get/getVersion.test.js +0 -25
  49. package/out/test/Wallet/get/getVersion.test.js.map +0 -1
  50. package/out/test/Wallet/live/walletLive.man.test.d.ts +0 -26
  51. package/out/test/Wallet/live/walletLive.man.test.d.ts.map +0 -1
  52. package/out/test/Wallet/live/walletLive.man.test.js +0 -417
  53. package/out/test/Wallet/live/walletLive.man.test.js.map +0 -1
  54. package/out/test/Wallet/local/localWallet.man.test.d.ts +0 -2
  55. package/out/test/Wallet/local/localWallet.man.test.d.ts.map +0 -1
  56. package/out/test/Wallet/local/localWallet.man.test.js +0 -83
  57. package/out/test/Wallet/local/localWallet.man.test.js.map +0 -1
  58. package/out/test/Wallet/local/localWallet2.man.test.d.ts +0 -2
  59. package/out/test/Wallet/local/localWallet2.man.test.d.ts.map +0 -1
  60. package/out/test/Wallet/local/localWallet2.man.test.js +0 -284
  61. package/out/test/Wallet/local/localWallet2.man.test.js.map +0 -1
  62. package/out/test/Wallet/signAction/mountaintop.man.test.d.ts +0 -2
  63. package/out/test/Wallet/signAction/mountaintop.man.test.d.ts.map +0 -1
  64. package/out/test/Wallet/signAction/mountaintop.man.test.js +0 -109
  65. package/out/test/Wallet/signAction/mountaintop.man.test.js.map +0 -1
  66. package/out/test/Wallet/specOps/specOps.man.test.d.ts +0 -2
  67. package/out/test/Wallet/specOps/specOps.man.test.d.ts.map +0 -1
  68. package/out/test/Wallet/specOps/specOps.man.test.js +0 -163
  69. package/out/test/Wallet/specOps/specOps.man.test.js.map +0 -1
  70. package/out/test/Wallet/support/janitor.man.test.d.ts +0 -2
  71. package/out/test/Wallet/support/janitor.man.test.d.ts.map +0 -1
  72. package/out/test/Wallet/support/janitor.man.test.js +0 -38
  73. package/out/test/Wallet/support/janitor.man.test.js.map +0 -1
  74. package/out/test/Wallet/support/operations.man.test.d.ts +0 -2
  75. package/out/test/Wallet/support/operations.man.test.d.ts.map +0 -1
  76. package/out/test/Wallet/support/operations.man.test.js +0 -370
  77. package/out/test/Wallet/support/operations.man.test.js.map +0 -1
  78. package/out/test/Wallet/support/reqErrorReview.2025.05.06.man.test.d.ts +0 -2
  79. package/out/test/Wallet/support/reqErrorReview.2025.05.06.man.test.d.ts.map +0 -1
  80. package/out/test/Wallet/support/reqErrorReview.2025.05.06.man.test.js +0 -385
  81. package/out/test/Wallet/support/reqErrorReview.2025.05.06.man.test.js.map +0 -1
  82. package/out/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.d.ts +0 -2
  83. package/out/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.d.ts.map +0 -1
  84. package/out/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.js +0 -206
  85. package/out/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.js.map +0 -1
  86. package/out/test/Wallet/sync/setActive.test.d.ts +0 -2
  87. package/out/test/Wallet/sync/setActive.test.d.ts.map +0 -1
  88. package/out/test/Wallet/sync/setActive.test.js +0 -161
  89. package/out/test/Wallet/sync/setActive.test.js.map +0 -1
  90. package/out/test/WalletClient/LocalKVStore.man.test.d.ts +0 -2
  91. package/out/test/WalletClient/LocalKVStore.man.test.d.ts.map +0 -1
  92. package/out/test/WalletClient/LocalKVStore.man.test.js +0 -99
  93. package/out/test/WalletClient/LocalKVStore.man.test.js.map +0 -1
  94. package/out/test/WalletClient/WERR.man.test.d.ts +0 -2
  95. package/out/test/WalletClient/WERR.man.test.d.ts.map +0 -1
  96. package/out/test/WalletClient/WERR.man.test.js +0 -34
  97. package/out/test/WalletClient/WERR.man.test.js.map +0 -1
  98. package/out/test/bsv-ts-sdk/LocalKVStore.test.d.ts +0 -2
  99. package/out/test/bsv-ts-sdk/LocalKVStore.test.d.ts.map +0 -1
  100. package/out/test/bsv-ts-sdk/LocalKVStore.test.js +0 -98
  101. package/out/test/bsv-ts-sdk/LocalKVStore.test.js.map +0 -1
  102. package/out/test/checkDB.d.ts +0 -4
  103. package/out/test/checkDB.d.ts.map +0 -1
  104. package/out/test/checkDB.js +0 -55
  105. package/out/test/checkDB.js.map +0 -1
  106. package/out/test/examples/backup.man.test.d.ts +0 -14
  107. package/out/test/examples/backup.man.test.d.ts.map +0 -1
  108. package/out/test/examples/backup.man.test.js +0 -59
  109. package/out/test/examples/backup.man.test.js.map +0 -1
  110. package/out/test/examples/pushdrop.test.d.ts +0 -56
  111. package/out/test/examples/pushdrop.test.d.ts.map +0 -1
  112. package/out/test/examples/pushdrop.test.js +0 -232
  113. package/out/test/examples/pushdrop.test.js.map +0 -1
  114. package/out/test/monitor/Monitor.test.d.ts +0 -2
  115. package/out/test/monitor/Monitor.test.d.ts.map +0 -1
  116. package/out/test/monitor/Monitor.test.js +0 -560
  117. package/out/test/monitor/Monitor.test.js.map +0 -1
  118. package/out/test/services/Services.test.d.ts +0 -2
  119. package/out/test/services/Services.test.d.ts.map +0 -1
  120. package/out/test/services/Services.test.js +0 -246
  121. package/out/test/services/Services.test.js.map +0 -1
  122. package/out/test/storage/KnexMigrations.test.d.ts +0 -2
  123. package/out/test/storage/KnexMigrations.test.d.ts.map +0 -1
  124. package/out/test/storage/KnexMigrations.test.js +0 -81
  125. package/out/test/storage/KnexMigrations.test.js.map +0 -1
  126. package/out/test/storage/StorageMySQLDojoReader.man.test.d.ts +0 -2
  127. package/out/test/storage/StorageMySQLDojoReader.man.test.d.ts.map +0 -1
  128. package/out/test/storage/StorageMySQLDojoReader.man.test.js +0 -86
  129. package/out/test/storage/StorageMySQLDojoReader.man.test.js.map +0 -1
  130. package/out/test/storage/count.test.d.ts +0 -2
  131. package/out/test/storage/count.test.d.ts.map +0 -1
  132. package/out/test/storage/count.test.js +0 -142
  133. package/out/test/storage/count.test.js.map +0 -1
  134. package/out/test/storage/find.test.d.ts +0 -2
  135. package/out/test/storage/find.test.d.ts.map +0 -1
  136. package/out/test/storage/find.test.js +0 -144
  137. package/out/test/storage/find.test.js.map +0 -1
  138. package/out/test/storage/findLegacy.test.d.ts +0 -2
  139. package/out/test/storage/findLegacy.test.d.ts.map +0 -1
  140. package/out/test/storage/findLegacy.test.js +0 -52
  141. package/out/test/storage/findLegacy.test.js.map +0 -1
  142. package/out/test/storage/idb/allocateChange.test.d.ts +0 -2
  143. package/out/test/storage/idb/allocateChange.test.d.ts.map +0 -1
  144. package/out/test/storage/idb/allocateChange.test.js +0 -110
  145. package/out/test/storage/idb/allocateChange.test.js.map +0 -1
  146. package/out/test/storage/idb/count.test.d.ts +0 -2
  147. package/out/test/storage/idb/count.test.d.ts.map +0 -1
  148. package/out/test/storage/idb/count.test.js +0 -129
  149. package/out/test/storage/idb/count.test.js.map +0 -1
  150. package/out/test/storage/idb/find.test.d.ts +0 -2
  151. package/out/test/storage/idb/find.test.d.ts.map +0 -1
  152. package/out/test/storage/idb/find.test.js +0 -131
  153. package/out/test/storage/idb/find.test.js.map +0 -1
  154. package/out/test/storage/idb/idbSpeed.test.d.ts +0 -2
  155. package/out/test/storage/idb/idbSpeed.test.d.ts.map +0 -1
  156. package/out/test/storage/idb/idbSpeed.test.js +0 -30
  157. package/out/test/storage/idb/idbSpeed.test.js.map +0 -1
  158. package/out/test/storage/idb/insert.test.d.ts +0 -2
  159. package/out/test/storage/idb/insert.test.d.ts.map +0 -1
  160. package/out/test/storage/idb/insert.test.js +0 -242
  161. package/out/test/storage/idb/insert.test.js.map +0 -1
  162. package/out/test/storage/idb/transactionAbort.test.d.ts +0 -2
  163. package/out/test/storage/idb/transactionAbort.test.d.ts.map +0 -1
  164. package/out/test/storage/idb/transactionAbort.test.js +0 -97
  165. package/out/test/storage/idb/transactionAbort.test.js.map +0 -1
  166. package/out/test/storage/idb/update.test.d.ts +0 -2
  167. package/out/test/storage/idb/update.test.d.ts.map +0 -1
  168. package/out/test/storage/idb/update.test.js +0 -902
  169. package/out/test/storage/idb/update.test.js.map +0 -1
  170. package/out/test/storage/insert.test.d.ts +0 -2
  171. package/out/test/storage/insert.test.d.ts.map +0 -1
  172. package/out/test/storage/insert.test.js +0 -256
  173. package/out/test/storage/insert.test.js.map +0 -1
  174. package/out/test/storage/update.test.d.ts +0 -2
  175. package/out/test/storage/update.test.d.ts.map +0 -1
  176. package/out/test/storage/update.test.js +0 -919
  177. package/out/test/storage/update.test.js.map +0 -1
  178. package/out/test/storage/update2.test.d.ts +0 -2
  179. package/out/test/storage/update2.test.d.ts.map +0 -1
  180. package/out/test/storage/update2.test.js +0 -767
  181. package/out/test/storage/update2.test.js.map +0 -1
  182. package/out/test/utils/TestUtilsWalletStorage.d.ts +0 -523
  183. package/out/test/utils/TestUtilsWalletStorage.d.ts.map +0 -1
  184. package/out/test/utils/TestUtilsWalletStorage.js +0 -1958
  185. package/out/test/utils/TestUtilsWalletStorage.js.map +0 -1
  186. package/out/test/utils/localWalletMethods.d.ts +0 -33
  187. package/out/test/utils/localWalletMethods.d.ts.map +0 -1
  188. package/out/test/utils/localWalletMethods.js +0 -304
  189. package/out/test/utils/localWalletMethods.js.map +0 -1
  190. package/out/test/wallet/action/abortAction.test.d.ts +0 -2
  191. package/out/test/wallet/action/abortAction.test.d.ts.map +0 -1
  192. package/out/test/wallet/action/abortAction.test.js +0 -44
  193. package/out/test/wallet/action/abortAction.test.js.map +0 -1
  194. package/out/test/wallet/action/createAction.test.d.ts +0 -2
  195. package/out/test/wallet/action/createAction.test.d.ts.map +0 -1
  196. package/out/test/wallet/action/createAction.test.js +0 -272
  197. package/out/test/wallet/action/createAction.test.js.map +0 -1
  198. package/out/test/wallet/action/createAction2.test.d.ts +0 -37
  199. package/out/test/wallet/action/createAction2.test.d.ts.map +0 -1
  200. package/out/test/wallet/action/createAction2.test.js +0 -1143
  201. package/out/test/wallet/action/createAction2.test.js.map +0 -1
  202. package/out/test/wallet/action/createActionToGenerateBeefs.man.test.d.ts +0 -2
  203. package/out/test/wallet/action/createActionToGenerateBeefs.man.test.d.ts.map +0 -1
  204. package/out/test/wallet/action/createActionToGenerateBeefs.man.test.js +0 -273
  205. package/out/test/wallet/action/createActionToGenerateBeefs.man.test.js.map +0 -1
  206. package/out/test/wallet/action/internalizeAction.test.d.ts +0 -2
  207. package/out/test/wallet/action/internalizeAction.test.d.ts.map +0 -1
  208. package/out/test/wallet/action/internalizeAction.test.js +0 -608
  209. package/out/test/wallet/action/internalizeAction.test.js.map +0 -1
  210. package/out/test/wallet/action/relinquishOutput.test.d.ts +0 -2
  211. package/out/test/wallet/action/relinquishOutput.test.d.ts.map +0 -1
  212. package/out/test/wallet/action/relinquishOutput.test.js +0 -31
  213. package/out/test/wallet/action/relinquishOutput.test.js.map +0 -1
  214. package/out/test/wallet/construct/Wallet.constructor.test.d.ts +0 -2
  215. package/out/test/wallet/construct/Wallet.constructor.test.d.ts.map +0 -1
  216. package/out/test/wallet/construct/Wallet.constructor.test.js +0 -49
  217. package/out/test/wallet/construct/Wallet.constructor.test.js.map +0 -1
  218. package/out/test/wallet/list/listActions.test.d.ts +0 -2
  219. package/out/test/wallet/list/listActions.test.d.ts.map +0 -1
  220. package/out/test/wallet/list/listActions.test.js +0 -271
  221. package/out/test/wallet/list/listActions.test.js.map +0 -1
  222. package/out/test/wallet/list/listActions2.test.d.ts +0 -2
  223. package/out/test/wallet/list/listActions2.test.d.ts.map +0 -1
  224. package/out/test/wallet/list/listActions2.test.js +0 -1141
  225. package/out/test/wallet/list/listActions2.test.js.map +0 -1
  226. package/out/test/wallet/list/listCertificates.test.d.ts +0 -2
  227. package/out/test/wallet/list/listCertificates.test.d.ts.map +0 -1
  228. package/out/test/wallet/list/listCertificates.test.js +0 -111
  229. package/out/test/wallet/list/listCertificates.test.js.map +0 -1
  230. package/out/test/wallet/list/listOutputs.test.d.ts +0 -2
  231. package/out/test/wallet/list/listOutputs.test.d.ts.map +0 -1
  232. package/out/test/wallet/list/listOutputs.test.js +0 -424
  233. package/out/test/wallet/list/listOutputs.test.js.map +0 -1
  234. package/out/test/wallet/sync/Wallet.sync.test.d.ts +0 -2
  235. package/out/test/wallet/sync/Wallet.sync.test.d.ts.map +0 -1
  236. package/out/test/wallet/sync/Wallet.sync.test.js +0 -155
  237. package/out/test/wallet/sync/Wallet.sync.test.js.map +0 -1
  238. package/out/tsconfig.all.tsbuildinfo +0 -1
  239. package/src/CWIStyleWalletManager.ts +0 -1999
  240. package/src/Setup.ts +0 -579
  241. package/src/SetupClient.ts +0 -322
  242. package/src/SetupWallet.ts +0 -108
  243. package/src/SimpleWalletManager.ts +0 -526
  244. package/src/Wallet.ts +0 -1169
  245. package/src/WalletAuthenticationManager.ts +0 -153
  246. package/src/WalletLogger.ts +0 -213
  247. package/src/WalletPermissionsManager.ts +0 -3660
  248. package/src/WalletSettingsManager.ts +0 -114
  249. package/src/__tests/CWIStyleWalletManager.test.d.ts.map +0 -1
  250. package/src/__tests/CWIStyleWalletManager.test.js.map +0 -1
  251. package/src/__tests/CWIStyleWalletManager.test.ts +0 -675
  252. package/src/__tests/WalletPermissionsManager.callbacks.test.ts +0 -323
  253. package/src/__tests/WalletPermissionsManager.checks.test.ts +0 -844
  254. package/src/__tests/WalletPermissionsManager.encryption.test.ts +0 -412
  255. package/src/__tests/WalletPermissionsManager.fixtures.ts +0 -307
  256. package/src/__tests/WalletPermissionsManager.flows.test.ts +0 -462
  257. package/src/__tests/WalletPermissionsManager.initialization.test.ts +0 -300
  258. package/src/__tests/WalletPermissionsManager.pmodules.test.ts +0 -798
  259. package/src/__tests/WalletPermissionsManager.proxying.test.ts +0 -724
  260. package/src/__tests/WalletPermissionsManager.tokens.test.ts +0 -503
  261. package/src/index.all.ts +0 -27
  262. package/src/index.client.ts +0 -25
  263. package/src/index.mobile.ts +0 -21
  264. package/src/index.ts +0 -1
  265. package/src/monitor/Monitor.ts +0 -412
  266. package/src/monitor/MonitorDaemon.ts +0 -188
  267. package/src/monitor/README.md +0 -3
  268. package/src/monitor/__test/MonitorDaemon.man.test.ts +0 -45
  269. package/src/monitor/tasks/TaskCheckForProofs.ts +0 -243
  270. package/src/monitor/tasks/TaskCheckNoSends.ts +0 -73
  271. package/src/monitor/tasks/TaskClock.ts +0 -33
  272. package/src/monitor/tasks/TaskFailAbandoned.ts +0 -54
  273. package/src/monitor/tasks/TaskMonitorCallHistory.ts +0 -26
  274. package/src/monitor/tasks/TaskNewHeader.ts +0 -93
  275. package/src/monitor/tasks/TaskPurge.ts +0 -68
  276. package/src/monitor/tasks/TaskReorg.ts +0 -89
  277. package/src/monitor/tasks/TaskReviewStatus.ts +0 -48
  278. package/src/monitor/tasks/TaskSendWaiting.ts +0 -122
  279. package/src/monitor/tasks/TaskSyncWhenIdle.ts +0 -26
  280. package/src/monitor/tasks/TaskUnFail.ts +0 -151
  281. package/src/monitor/tasks/WalletMonitorTask.ts +0 -47
  282. package/src/sdk/CertOpsWallet.ts +0 -18
  283. package/src/sdk/PrivilegedKeyManager.ts +0 -372
  284. package/src/sdk/README.md +0 -13
  285. package/src/sdk/WERR_errors.ts +0 -234
  286. package/src/sdk/WalletError.ts +0 -170
  287. package/src/sdk/WalletErrorFromJson.ts +0 -80
  288. package/src/sdk/WalletServices.interfaces.ts +0 -700
  289. package/src/sdk/WalletSigner.interfaces.ts +0 -11
  290. package/src/sdk/WalletStorage.interfaces.ts +0 -606
  291. package/src/sdk/__test/CertificateLifeCycle.test.ts +0 -131
  292. package/src/sdk/__test/PrivilegedKeyManager.test.ts +0 -738
  293. package/src/sdk/__test/WalletError.test.ts +0 -318
  294. package/src/sdk/__test/validationHelpers.test.ts +0 -21
  295. package/src/sdk/index.ts +0 -10
  296. package/src/sdk/types.ts +0 -226
  297. package/src/services/README.md +0 -11
  298. package/src/services/ServiceCollection.ts +0 -248
  299. package/src/services/Services.ts +0 -603
  300. package/src/services/__tests/ARC.man.test.ts +0 -123
  301. package/src/services/__tests/ARC.timeout.man.test.ts +0 -79
  302. package/src/services/__tests/ArcGorillaPool.man.test.ts +0 -108
  303. package/src/services/__tests/arcServices.test.ts +0 -8
  304. package/src/services/__tests/bitrails.test.ts +0 -56
  305. package/src/services/__tests/getMerklePath.test.ts +0 -15
  306. package/src/services/__tests/getRawTx.test.ts +0 -13
  307. package/src/services/__tests/postBeef.test.ts +0 -104
  308. package/src/services/__tests/verifyBeef.test.ts +0 -50
  309. package/src/services/chaintracker/BHServiceClient.ts +0 -212
  310. package/src/services/chaintracker/ChaintracksChainTracker.ts +0 -71
  311. package/src/services/chaintracker/__tests/ChaintracksChainTracker.test.ts +0 -33
  312. package/src/services/chaintracker/__tests/ChaintracksServiceClient.test.ts +0 -29
  313. package/src/services/chaintracker/chaintracks/Api/BlockHeaderApi.ts +0 -72
  314. package/src/services/chaintracker/chaintracks/Api/BulkIngestorApi.ts +0 -83
  315. package/src/services/chaintracker/chaintracks/Api/BulkStorageApi.ts +0 -92
  316. package/src/services/chaintracker/chaintracks/Api/ChaintracksApi.ts +0 -64
  317. package/src/services/chaintracker/chaintracks/Api/ChaintracksClientApi.ts +0 -189
  318. package/src/services/chaintracker/chaintracks/Api/ChaintracksFetchApi.ts +0 -18
  319. package/src/services/chaintracker/chaintracks/Api/ChaintracksFsApi.ts +0 -58
  320. package/src/services/chaintracker/chaintracks/Api/ChaintracksStorageApi.ts +0 -386
  321. package/src/services/chaintracker/chaintracks/Api/LiveIngestorApi.ts +0 -25
  322. package/src/services/chaintracker/chaintracks/Chaintracks.ts +0 -609
  323. package/src/services/chaintracker/chaintracks/ChaintracksService.ts +0 -199
  324. package/src/services/chaintracker/chaintracks/ChaintracksServiceClient.ts +0 -154
  325. package/src/services/chaintracker/chaintracks/Ingest/BulkIngestorBase.ts +0 -176
  326. package/src/services/chaintracker/chaintracks/Ingest/BulkIngestorCDN.ts +0 -174
  327. package/src/services/chaintracker/chaintracks/Ingest/BulkIngestorCDNBabbage.ts +0 -18
  328. package/src/services/chaintracker/chaintracks/Ingest/BulkIngestorWhatsOnChainCdn.ts +0 -113
  329. package/src/services/chaintracker/chaintracks/Ingest/BulkIngestorWhatsOnChainWs.ts +0 -81
  330. package/src/services/chaintracker/chaintracks/Ingest/LiveIngestorBase.ts +0 -86
  331. package/src/services/chaintracker/chaintracks/Ingest/LiveIngestorTeranodeP2P.ts +0 -59
  332. package/src/services/chaintracker/chaintracks/Ingest/LiveIngestorWhatsOnChainPoll.ts +0 -104
  333. package/src/services/chaintracker/chaintracks/Ingest/LiveIngestorWhatsOnChainWs.ts +0 -66
  334. package/src/services/chaintracker/chaintracks/Ingest/WhatsOnChainIngestorWs.ts +0 -566
  335. package/src/services/chaintracker/chaintracks/Ingest/WhatsOnChainServices.ts +0 -219
  336. package/src/services/chaintracker/chaintracks/Ingest/__tests/BulkIngestorCDNBabbage.test.ts +0 -54
  337. package/src/services/chaintracker/chaintracks/Ingest/__tests/LiveIngestorWhatsOnChainPoll.test.ts +0 -33
  338. package/src/services/chaintracker/chaintracks/Ingest/__tests/WhatsOnChainServices.test.ts +0 -124
  339. package/src/services/chaintracker/chaintracks/Storage/BulkStorageBase.ts +0 -92
  340. package/src/services/chaintracker/chaintracks/Storage/ChaintracksKnexMigrations.ts +0 -104
  341. package/src/services/chaintracker/chaintracks/Storage/ChaintracksStorageBase.ts +0 -382
  342. package/src/services/chaintracker/chaintracks/Storage/ChaintracksStorageIdb.ts +0 -574
  343. package/src/services/chaintracker/chaintracks/Storage/ChaintracksStorageKnex.ts +0 -438
  344. package/src/services/chaintracker/chaintracks/Storage/ChaintracksStorageMemory.ts +0 -29
  345. package/src/services/chaintracker/chaintracks/Storage/ChaintracksStorageNoDb.ts +0 -304
  346. package/src/services/chaintracker/chaintracks/Storage/__tests/ChaintracksStorageIdb.test.ts +0 -102
  347. package/src/services/chaintracker/chaintracks/Storage/__tests/ChaintracksStorageKnex.test.ts +0 -45
  348. package/src/services/chaintracker/chaintracks/__tests/Chaintracks.test.ts +0 -77
  349. package/src/services/chaintracker/chaintracks/__tests/ChaintracksClientApi.test.ts +0 -192
  350. package/src/services/chaintracker/chaintracks/__tests/LocalCdnServer.ts +0 -75
  351. package/src/services/chaintracker/chaintracks/__tests/createIdbChaintracks.test.ts +0 -62
  352. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest349/mainNetBlockHeaders.json +0 -1
  353. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest349/mainNet_0.headers +0 -0
  354. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest349/mainNet_1.headers +0 -0
  355. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest349/mainNet_2.headers +0 -0
  356. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest349/mainNet_3.headers +0 -0
  357. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest379/mainNetBlockHeaders.json +0 -1
  358. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest379/mainNet_0.headers +0 -0
  359. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest379/mainNet_1.headers +0 -0
  360. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest379/mainNet_2.headers +0 -0
  361. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest379/mainNet_3.headers +0 -0
  362. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest399/mainNetBlockHeaders.json +0 -1
  363. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest399/mainNet_0.headers +0 -0
  364. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest399/mainNet_1.headers +0 -0
  365. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest399/mainNet_2.headers +0 -0
  366. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest399/mainNet_3.headers +0 -0
  367. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest402/mainNetBlockHeaders.json +0 -1
  368. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest402/mainNet_0.headers +0 -0
  369. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest402/mainNet_1.headers +0 -0
  370. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest402/mainNet_2.headers +0 -0
  371. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest402/mainNet_3.headers +0 -0
  372. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest402/mainNet_4.headers +0 -0
  373. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest499/mainNetBlockHeaders.json +0 -1
  374. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest499/mainNet_0.headers +0 -0
  375. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest499/mainNet_1.headers +0 -0
  376. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest499/mainNet_2.headers +0 -0
  377. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest499/mainNet_3.headers +0 -0
  378. package/src/services/chaintracker/chaintracks/__tests/data/cdnTest499/mainNet_4.headers +0 -0
  379. package/src/services/chaintracker/chaintracks/createDefaultIdbChaintracksOptions.ts +0 -92
  380. package/src/services/chaintracker/chaintracks/createDefaultKnexChaintracksOptions.ts +0 -111
  381. package/src/services/chaintracker/chaintracks/createDefaultNoDbChaintracksOptions.ts +0 -91
  382. package/src/services/chaintracker/chaintracks/createIdbChaintracks.ts +0 -60
  383. package/src/services/chaintracker/chaintracks/createKnexChaintracks.ts +0 -65
  384. package/src/services/chaintracker/chaintracks/createNoDbChaintracks.ts +0 -60
  385. package/src/services/chaintracker/chaintracks/index.all.ts +0 -12
  386. package/src/services/chaintracker/chaintracks/index.client.ts +0 -4
  387. package/src/services/chaintracker/chaintracks/index.mobile.ts +0 -37
  388. package/src/services/chaintracker/chaintracks/util/BulkFileDataManager.ts +0 -975
  389. package/src/services/chaintracker/chaintracks/util/BulkFileDataReader.ts +0 -60
  390. package/src/services/chaintracker/chaintracks/util/BulkFilesReader.ts +0 -336
  391. package/src/services/chaintracker/chaintracks/util/BulkHeaderFile.ts +0 -247
  392. package/src/services/chaintracker/chaintracks/util/ChaintracksFetch.ts +0 -69
  393. package/src/services/chaintracker/chaintracks/util/ChaintracksFs.ts +0 -141
  394. package/src/services/chaintracker/chaintracks/util/HeightRange.ts +0 -153
  395. package/src/services/chaintracker/chaintracks/util/SingleWriterMultiReaderLock.ts +0 -76
  396. package/src/services/chaintracker/chaintracks/util/__tests/BulkFileDataManager.test.ts +0 -304
  397. package/src/services/chaintracker/chaintracks/util/__tests/ChaintracksFetch.test.ts +0 -60
  398. package/src/services/chaintracker/chaintracks/util/__tests/HeightRange.test.ts +0 -67
  399. package/src/services/chaintracker/chaintracks/util/__tests/SingleWriterMultiReaderLock.test.ts +0 -49
  400. package/src/services/chaintracker/chaintracks/util/blockHeaderUtilities.ts +0 -573
  401. package/src/services/chaintracker/chaintracks/util/dirtyHashes.ts +0 -29
  402. package/src/services/chaintracker/chaintracks/util/validBulkHeaderFilesByFileHash.ts +0 -432
  403. package/src/services/chaintracker/index.all.ts +0 -4
  404. package/src/services/chaintracker/index.client.ts +0 -4
  405. package/src/services/chaintracker/index.mobile.ts +0 -4
  406. package/src/services/createDefaultWalletServicesOptions.ts +0 -77
  407. package/src/services/index.ts +0 -1
  408. package/src/services/processingErrors/arcSuccessError.json +0 -76
  409. package/src/services/providers/ARC.ts +0 -350
  410. package/src/services/providers/Bitails.ts +0 -256
  411. package/src/services/providers/SdkWhatsOnChain.ts +0 -83
  412. package/src/services/providers/WhatsOnChain.ts +0 -883
  413. package/src/services/providers/__tests/WhatsOnChain.test.ts +0 -242
  414. package/src/services/providers/__tests/exchangeRates.test.ts +0 -18
  415. package/src/services/providers/exchangeRates.ts +0 -265
  416. package/src/services/providers/getBeefForTxid.ts +0 -369
  417. package/src/signer/README.md +0 -5
  418. package/src/signer/WalletSigner.ts +0 -17
  419. package/src/signer/methods/acquireDirectCertificate.ts +0 -52
  420. package/src/signer/methods/buildSignableTransaction.ts +0 -183
  421. package/src/signer/methods/completeSignedTransaction.ts +0 -117
  422. package/src/signer/methods/createAction.ts +0 -172
  423. package/src/signer/methods/internalizeAction.ts +0 -106
  424. package/src/signer/methods/proveCertificate.ts +0 -43
  425. package/src/signer/methods/signAction.ts +0 -54
  426. package/src/storage/README.md +0 -14
  427. package/src/storage/StorageIdb.ts +0 -2304
  428. package/src/storage/StorageKnex.ts +0 -1425
  429. package/src/storage/StorageProvider.ts +0 -810
  430. package/src/storage/StorageReader.ts +0 -194
  431. package/src/storage/StorageReaderWriter.ts +0 -432
  432. package/src/storage/StorageSyncReader.ts +0 -34
  433. package/src/storage/WalletStorageManager.ts +0 -943
  434. package/src/storage/__test/StorageIdb.test.ts +0 -43
  435. package/src/storage/__test/WalletStorageManager.test.ts +0 -275
  436. package/src/storage/__test/adminStats.man.test.ts +0 -89
  437. package/src/storage/__test/getBeefForTransaction.test.ts +0 -385
  438. package/src/storage/index.all.ts +0 -11
  439. package/src/storage/index.client.ts +0 -7
  440. package/src/storage/index.mobile.ts +0 -6
  441. package/src/storage/methods/ListActionsSpecOp.ts +0 -70
  442. package/src/storage/methods/ListOutputsSpecOp.ts +0 -129
  443. package/src/storage/methods/__test/GenerateChange/generateChangeSdk.test.ts +0 -1057
  444. package/src/storage/methods/__test/GenerateChange/randomValsUsed1.ts +0 -20
  445. package/src/storage/methods/__test/offsetKey.test.ts +0 -274
  446. package/src/storage/methods/attemptToPostReqsToNetwork.ts +0 -389
  447. package/src/storage/methods/createAction.ts +0 -947
  448. package/src/storage/methods/generateChange.ts +0 -556
  449. package/src/storage/methods/getBeefForTransaction.ts +0 -139
  450. package/src/storage/methods/getSyncChunk.ts +0 -293
  451. package/src/storage/methods/internalizeAction.ts +0 -562
  452. package/src/storage/methods/listActionsIdb.ts +0 -183
  453. package/src/storage/methods/listActionsKnex.ts +0 -226
  454. package/src/storage/methods/listCertificates.ts +0 -73
  455. package/src/storage/methods/listOutputsIdb.ts +0 -203
  456. package/src/storage/methods/listOutputsKnex.ts +0 -263
  457. package/src/storage/methods/offsetKey.ts +0 -89
  458. package/src/storage/methods/processAction.ts +0 -420
  459. package/src/storage/methods/purgeData.ts +0 -251
  460. package/src/storage/methods/purgeDataIdb.ts +0 -10
  461. package/src/storage/methods/reviewStatus.ts +0 -101
  462. package/src/storage/methods/reviewStatusIdb.ts +0 -43
  463. package/src/storage/methods/utils.Buffer.ts +0 -33
  464. package/src/storage/methods/utils.ts +0 -56
  465. package/src/storage/remoting/StorageClient.ts +0 -567
  466. package/src/storage/remoting/StorageMobile.ts +0 -544
  467. package/src/storage/remoting/StorageServer.ts +0 -291
  468. package/src/storage/remoting/__test/StorageClient.test.ts +0 -113
  469. package/src/storage/schema/KnexMigrations.ts +0 -489
  470. package/src/storage/schema/StorageIdbSchema.ts +0 -150
  471. package/src/storage/schema/entities/EntityBase.ts +0 -210
  472. package/src/storage/schema/entities/EntityCertificate.ts +0 -188
  473. package/src/storage/schema/entities/EntityCertificateField.ts +0 -136
  474. package/src/storage/schema/entities/EntityCommission.ts +0 -148
  475. package/src/storage/schema/entities/EntityOutput.ts +0 -290
  476. package/src/storage/schema/entities/EntityOutputBasket.ts +0 -153
  477. package/src/storage/schema/entities/EntityOutputTag.ts +0 -121
  478. package/src/storage/schema/entities/EntityOutputTagMap.ts +0 -123
  479. package/src/storage/schema/entities/EntityProvenTx.ts +0 -319
  480. package/src/storage/schema/entities/EntityProvenTxReq.ts +0 -580
  481. package/src/storage/schema/entities/EntitySyncState.ts +0 -389
  482. package/src/storage/schema/entities/EntityTransaction.ts +0 -306
  483. package/src/storage/schema/entities/EntityTxLabel.ts +0 -121
  484. package/src/storage/schema/entities/EntityTxLabelMap.ts +0 -123
  485. package/src/storage/schema/entities/EntityUser.ts +0 -112
  486. package/src/storage/schema/entities/MergeEntity.ts +0 -73
  487. package/src/storage/schema/entities/__tests/CertificateFieldTests.test.ts +0 -353
  488. package/src/storage/schema/entities/__tests/CertificateTests.test.ts +0 -354
  489. package/src/storage/schema/entities/__tests/CommissionTests.test.ts +0 -371
  490. package/src/storage/schema/entities/__tests/OutputBasketTests.test.ts +0 -278
  491. package/src/storage/schema/entities/__tests/OutputTagMapTests.test.ts +0 -242
  492. package/src/storage/schema/entities/__tests/OutputTagTests.test.ts +0 -288
  493. package/src/storage/schema/entities/__tests/OutputTests.test.ts +0 -464
  494. package/src/storage/schema/entities/__tests/ProvenTxReqTests.test.ts +0 -340
  495. package/src/storage/schema/entities/__tests/ProvenTxTests.test.ts +0 -504
  496. package/src/storage/schema/entities/__tests/SyncStateTests.test.ts +0 -288
  497. package/src/storage/schema/entities/__tests/TransactionTests.test.ts +0 -604
  498. package/src/storage/schema/entities/__tests/TxLabelMapTests.test.ts +0 -361
  499. package/src/storage/schema/entities/__tests/TxLabelTests.test.ts +0 -198
  500. package/src/storage/schema/entities/__tests/stampLogTests.test.ts +0 -90
  501. package/src/storage/schema/entities/__tests/usersTests.test.ts +0 -340
  502. package/src/storage/schema/entities/index.ts +0 -16
  503. package/src/storage/schema/tables/TableCertificate.ts +0 -21
  504. package/src/storage/schema/tables/TableCertificateField.ts +0 -12
  505. package/src/storage/schema/tables/TableCommission.ts +0 -13
  506. package/src/storage/schema/tables/TableMonitorEvent.ts +0 -9
  507. package/src/storage/schema/tables/TableOutput.ts +0 -64
  508. package/src/storage/schema/tables/TableOutputBasket.ts +0 -12
  509. package/src/storage/schema/tables/TableOutputTag.ts +0 -10
  510. package/src/storage/schema/tables/TableOutputTagMap.ts +0 -9
  511. package/src/storage/schema/tables/TableProvenTx.ts +0 -14
  512. package/src/storage/schema/tables/TableProvenTxReq.ts +0 -65
  513. package/src/storage/schema/tables/TableSettings.ts +0 -17
  514. package/src/storage/schema/tables/TableSyncState.ts +0 -18
  515. package/src/storage/schema/tables/TableTransaction.ts +0 -54
  516. package/src/storage/schema/tables/TableTxLabel.ts +0 -10
  517. package/src/storage/schema/tables/TableTxLabelMap.ts +0 -9
  518. package/src/storage/schema/tables/TableUser.ts +0 -16
  519. package/src/storage/schema/tables/index.ts +0 -16
  520. package/src/storage/sync/StorageMySQLDojoReader.ts +0 -696
  521. package/src/storage/sync/index.ts +0 -1
  522. package/src/utility/Format.ts +0 -133
  523. package/src/utility/README.md +0 -3
  524. package/src/utility/ReaderUint8Array.ts +0 -187
  525. package/src/utility/ScriptTemplateBRC29.ts +0 -73
  526. package/src/utility/__tests/utilityHelpers.noBuffer.test.ts +0 -109
  527. package/src/utility/aggregateResults.ts +0 -68
  528. package/src/utility/identityUtils.ts +0 -159
  529. package/src/utility/index.all.ts +0 -7
  530. package/src/utility/index.client.ts +0 -7
  531. package/src/utility/parseTxScriptOffsets.ts +0 -29
  532. package/src/utility/stampLog.ts +0 -69
  533. package/src/utility/tscProofToMerklePath.ts +0 -48
  534. package/src/utility/utilityHelpers.buffer.ts +0 -34
  535. package/src/utility/utilityHelpers.noBuffer.ts +0 -60
  536. package/src/utility/utilityHelpers.ts +0 -275
  537. package/src/wab-client/WABClient.ts +0 -94
  538. package/src/wab-client/__tests/WABClient.man.test.ts +0 -59
  539. package/src/wab-client/auth-method-interactors/AuthMethodInteractor.ts +0 -47
  540. package/src/wab-client/auth-method-interactors/DevConsoleInteractor.ts +0 -73
  541. package/src/wab-client/auth-method-interactors/PersonaIDInteractor.ts +0 -35
  542. package/src/wab-client/auth-method-interactors/TwilioPhoneInteractor.ts +0 -72
  543. package/syncVersions.js +0 -71
  544. package/test/Wallet/StorageClient/storageClient.man.test.ts +0 -75
  545. package/test/Wallet/action/internalizeAction.a.test.ts +0 -286
  546. package/test/Wallet/certificate/acquireCertificate.test.ts +0 -298
  547. package/test/Wallet/certificate/listCertificates.test.ts +0 -346
  548. package/test/Wallet/get/getHeaderForHeight.test.ts +0 -82
  549. package/test/Wallet/get/getHeight.test.ts +0 -52
  550. package/test/Wallet/get/getKnownTxids.test.ts +0 -86
  551. package/test/Wallet/get/getNetwork.test.ts +0 -27
  552. package/test/Wallet/get/getVersion.test.ts +0 -27
  553. package/test/Wallet/live/walletLive.man.test.ts +0 -521
  554. package/test/Wallet/local/localWallet.man.test.ts +0 -93
  555. package/test/Wallet/local/localWallet2.man.test.ts +0 -277
  556. package/test/Wallet/signAction/mountaintop.man.test.ts +0 -130
  557. package/test/Wallet/specOps/specOps.man.test.ts +0 -220
  558. package/test/Wallet/support/janitor.man.test.ts +0 -40
  559. package/test/Wallet/support/operations.man.test.ts +0 -407
  560. package/test/Wallet/support/reqErrorReview.2025.05.06.man.test.ts +0 -347
  561. package/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.ts +0 -203
  562. package/test/Wallet/sync/setActive.test.ts +0 -170
  563. package/test/WalletClient/LocalKVStore.man.test.ts +0 -114
  564. package/test/WalletClient/WERR.man.test.ts +0 -35
  565. package/test/bsv-ts-sdk/LocalKVStore.test.ts +0 -102
  566. package/test/checkDB.ts +0 -57
  567. package/test/checkdb +0 -0
  568. package/test/examples/backup.man.test.ts +0 -59
  569. package/test/examples/pushdrop.test.ts +0 -282
  570. package/test/monitor/Monitor.test.ts +0 -620
  571. package/test/services/Services.test.ts +0 -263
  572. package/test/storage/KnexMigrations.test.ts +0 -86
  573. package/test/storage/StorageMySQLDojoReader.man.test.ts +0 -60
  574. package/test/storage/count.test.ts +0 -177
  575. package/test/storage/find.test.ts +0 -195
  576. package/test/storage/findLegacy.test.ts +0 -67
  577. package/test/storage/idb/allocateChange.test.ts +0 -251
  578. package/test/storage/idb/count.test.ts +0 -158
  579. package/test/storage/idb/find.test.ts +0 -177
  580. package/test/storage/idb/idbSpeed.test.ts +0 -36
  581. package/test/storage/idb/insert.test.ts +0 -268
  582. package/test/storage/idb/transactionAbort.test.ts +0 -108
  583. package/test/storage/idb/update.test.ts +0 -999
  584. package/test/storage/insert.test.ts +0 -278
  585. package/test/storage/update.test.ts +0 -1021
  586. package/test/storage/update2.test.ts +0 -897
  587. package/test/utils/TestUtilsWalletStorage.ts +0 -2526
  588. package/test/utils/localWalletMethods.ts +0 -363
  589. package/test/utils/removeFailedFromDatabase.sql +0 -17
  590. package/test/wallet/action/abortAction.test.ts +0 -47
  591. package/test/wallet/action/createAction.test.ts +0 -299
  592. package/test/wallet/action/createAction2.test.ts +0 -1273
  593. package/test/wallet/action/createActionToGenerateBeefs.man.test.ts +0 -293
  594. package/test/wallet/action/internalizeAction.test.ts +0 -682
  595. package/test/wallet/action/relinquishOutput.test.ts +0 -37
  596. package/test/wallet/construct/Wallet.constructor.test.ts +0 -57
  597. package/test/wallet/list/listActions.test.ts +0 -279
  598. package/test/wallet/list/listActions2.test.ts +0 -1381
  599. package/test/wallet/list/listCertificates.test.ts +0 -118
  600. package/test/wallet/list/listOutputs.test.ts +0 -447
  601. package/test/wallet/sync/Wallet.sync.test.ts +0 -215
  602. package/ts2md.json +0 -44
  603. package/tsconfig.all.json +0 -31
  604. package/tsconfig.client.json +0 -29
  605. package/tsconfig.json +0 -17
  606. package/tsconfig.mobile.json +0 -28
@@ -1,700 +0,0 @@
1
- import {
2
- ArcConfig,
3
- Beef,
4
- Transaction as BsvTransaction,
5
- ChainTracker,
6
- MerklePath,
7
- WalletLoggerInterface
8
- } from '@bsv/sdk'
9
- import { Chain, ReqHistoryNote } from './types'
10
- import { WalletError } from './WalletError'
11
- import { TableOutput } from '../storage/schema/tables/TableOutput'
12
- import { ChaintracksServiceClient } from '../services/chaintracker/chaintracks/ChaintracksServiceClient'
13
- import { ChaintracksClientApi } from '../services/chaintracker/chaintracks/Api/ChaintracksClientApi'
14
- /**
15
- * Defines standard interfaces to access functionality implemented by external transaction processing services.
16
- */
17
- export interface WalletServices {
18
- /**
19
- * The chain being serviced.
20
- */
21
- chain: Chain
22
-
23
- /**
24
- * @returns standard `ChainTracker` service which requires `options.chaintracks` be valid.
25
- */
26
- getChainTracker(): Promise<ChainTracker>
27
-
28
- /**
29
- * @returns serialized block header for height on active chain
30
- * @param height
31
- */
32
- getHeaderForHeight(height: number): Promise<number[]>
33
-
34
- /**
35
- * @returns the height of the active chain
36
- */
37
- getHeight(): Promise<number>
38
-
39
- /**
40
- * Approximate exchange rate US Dollar / BSV, USD / BSV
41
- *
42
- * This is the US Dollar price of one BSV
43
- */
44
- getBsvExchangeRate(): Promise<number>
45
-
46
- /**
47
- * Approximate exchange rate currency per base.
48
- */
49
- getFiatExchangeRate(currency: 'USD' | 'GBP' | 'EUR', base?: 'USD' | 'GBP' | 'EUR'): Promise<number>
50
-
51
- /**
52
- * Attempts to obtain the raw transaction bytes associated with a 32 byte transaction hash (txid).
53
- *
54
- * Cycles through configured transaction processing services attempting to get a valid response.
55
- *
56
- * On success:
57
- * Result txid is the requested transaction hash
58
- * Result rawTx will be an array containing raw transaction bytes.
59
- * Result name will be the responding service's identifying name.
60
- * Returns result without incrementing active service.
61
- *
62
- * On failure:
63
- * Result txid is the requested transaction hash
64
- * Result mapi will be the first mapi response obtained (service name and response), or null
65
- * Result error will be the first error thrown (service name and CwiError), or null
66
- * Increments to next configured service and tries again until all services have been tried.
67
- *
68
- * @param txid transaction hash for which raw transaction bytes are requested
69
- * @param useNext optional, forces skip to next service before starting service requests cycle.
70
- */
71
- getRawTx(txid: string, useNext?: boolean): Promise<GetRawTxResult>
72
-
73
- /**
74
- * Attempts to obtain the merkle proof associated with a 32 byte transaction hash (txid).
75
- *
76
- * Cycles through configured transaction processing services attempting to get a valid response.
77
- *
78
- * On success:
79
- * Result txid is the requested transaction hash
80
- * Result proof will be the merkle proof.
81
- * Result name will be the responding service's identifying name.
82
- * Returns result without incrementing active service.
83
- *
84
- * On failure:
85
- * Result txid is the requested transaction hash
86
- * Result mapi will be the first mapi response obtained (service name and response), or null
87
- * Result error will be the first error thrown (service name and CwiError), or null
88
- * Increments to next configured service and tries again until all services have been tried.
89
- *
90
- * @param txid transaction hash for which proof is requested
91
- * @param useNext optional, forces skip to next service before starting service requests cycle.
92
- */
93
- getMerklePath(txid: string, useNext?: boolean): Promise<GetMerklePathResult>
94
-
95
- /**
96
- *
97
- * @param beef
98
- * @param txids
99
- * @param chain
100
- * @returns
101
- */
102
- postBeef(beef: Beef, txids: string[], logger?: WalletLoggerInterface): Promise<PostBeefResult[]>
103
-
104
- /**
105
- * @param script Output script to be hashed for `getUtxoStatus` default `outputFormat`
106
- * @returns script hash in 'hashLE' format, which is the default.
107
- */
108
- hashOutputScript(script: string): string
109
-
110
- /**
111
- * For an array of one or more txids, returns for each wether it is a 'known', 'mined', or 'unknown' transaction.
112
- *
113
- * Primarily useful for determining if a recently broadcast transaction is known to the processing network.
114
- *
115
- * Also returns the current depth from chain tip if 'mined'.
116
- *
117
- * @param txids
118
- * @param useNext
119
- */
120
- getStatusForTxids(txids: string[], useNext?: boolean): Promise<GetStatusForTxidsResult>
121
-
122
- /**
123
- * Calls getUtxoStatus with the hash of the output's lockingScript,
124
- * and ensures that the output's outpoint matches an unspent use of that script.
125
- *
126
- * @param output
127
- * @returns true if the output appears to currently be spendable.
128
- */
129
- isUtxo(output: TableOutput): Promise<boolean>
130
-
131
- /**
132
- * Attempts to determine the UTXO status of a transaction output.
133
- *
134
- * Cycles through configured transaction processing services attempting to get a valid response.
135
- *
136
- * @param output transaction output identifier in format determined by `outputFormat`.
137
- * @param chain which chain to post to, all of rawTx's inputs must be unspent on this chain.
138
- * @param outputFormat optional, supported values:
139
- * 'hashLE' little-endian sha256 hash of output script
140
- * 'hashBE' big-endian sha256 hash of output script
141
- * 'script' entire transaction output script
142
- * undefined if length of `output` is 32 hex bytes then 'hashBE`, otherwise 'script'.
143
- * @param outpoint if valid, result isUtxo is true only if this txid and vout match an unspent occurance of output script. `${txid}.${vout}` format.
144
- * @param useNext optional, forces skip to next service before starting service requests cycle.
145
- */
146
- getUtxoStatus(
147
- output: string,
148
- outputFormat?: GetUtxoStatusOutputFormat,
149
- outpoint?: string,
150
- useNext?: boolean
151
- ): Promise<GetUtxoStatusResult>
152
-
153
- getScriptHashHistory(
154
- hash: string,
155
- useNext?: boolean,
156
- logger?: WalletLoggerInterface
157
- ): Promise<GetScriptHashHistoryResult>
158
-
159
- /**
160
- * @returns a block header
161
- * @param hash block hash
162
- */
163
- hashToHeader(hash: string): Promise<BlockHeader>
164
-
165
- /**
166
- * @returns whether the locktime value allows the transaction to be mined at the current chain height
167
- * @param txOrLockTime either a bitcoin locktime value or hex, binary, un-encoded Transaction
168
- */
169
- nLockTimeIsFinal(txOrLockTime: string | number[] | BsvTransaction | number): Promise<boolean>
170
-
171
- /**
172
- * Constructs a `Beef` for the given `txid` using only external data retrieval services.
173
- *
174
- * In most cases, the `getBeefForTransaction` method of the `StorageProvider` class should be
175
- * used instead to avoid redundantly retrieving data.
176
- *
177
- * @throws errors if txid does not correspond to a valid transaction as determined by the
178
- * configured services.
179
- *
180
- * @param txid
181
- */
182
- getBeefForTxid(txid: string): Promise<Beef>
183
-
184
- /**
185
- * @param reset if true, ends current interval and starts a new one.
186
- * @returns a history of service calls made to the configured services.
187
- */
188
- getServicesCallHistory(reset?: boolean): ServicesCallHistory
189
- }
190
-
191
- export type ScriptHashFormat = 'hashLE' | 'hashBE' | 'script'
192
- export type GetUtxoStatusOutputFormat = 'hashLE' | 'hashBE' | 'script'
193
-
194
- export interface BsvExchangeRate {
195
- timestamp: Date
196
- base: 'USD'
197
- rate: number
198
- }
199
-
200
- export interface FiatExchangeRates {
201
- timestamp: Date
202
- base: 'USD'
203
- rates: Record<string, number>
204
- }
205
-
206
- export interface WalletServicesOptions {
207
- /**
208
- * 'main' or 'test': which BSV chain to use
209
- */
210
- chain: Chain
211
- /**
212
- * As of 2025-08-31 the `taalApiKey` is unused for default configured services.
213
- * See `arcConfig` instead.
214
- */
215
- taalApiKey?: string
216
- /**
217
- * Api key for use accessing Bitails API at
218
- * mainnet: `https://api.bitails.io/`
219
- * testnet: `https://test-api.bitails.io/`
220
- */
221
- bitailsApiKey?: string
222
- /**
223
- * Api key for use accessing WhatsOnChain API at
224
- * mainnet: `https://api.whatsonchain.com/v1/bsv/main`
225
- * testnet: `https://api.whatsonchain.com/v1/bsv/test`
226
- */
227
- whatsOnChainApiKey?: string
228
- /**
229
- * The initial approximate BSV/USD exchange rate.
230
- */
231
- bsvExchangeRate: BsvExchangeRate
232
- /**
233
- * Update interval for BSV/USD exchange rate.
234
- * Default is 15 minutes.
235
- */
236
- bsvUpdateMsecs: number
237
- /**
238
- * The initial approximate fiat exchange rates with USD as base.
239
- */
240
- fiatExchangeRates: FiatExchangeRates
241
- /**
242
- * Update interval for Fiat exchange rates.
243
- * Default is 24 hours.
244
- */
245
- fiatUpdateMsecs: number
246
- /**
247
- * MAPI callbacks are deprecated at this time.
248
- */
249
- disableMapiCallback?: boolean
250
- /**
251
- * API key for use accessing fiat exchange rates API at
252
- * `http://api.exchangeratesapi.io/v1/latest?access_key=${key}`
253
- *
254
- * Obtain your own api key here:
255
- * https://manage.exchangeratesapi.io/signup/free
256
- */
257
- exchangeratesapiKey?: string
258
- /**
259
- * Due to the default use of a free exchangeratesapiKey with low usage limits,
260
- * the `ChaintracksService` can act as a request rate multiplier.
261
- *
262
- * By default the following endpoint is used:
263
- * `https://mainnet-chaintracks.babbage.systems/getFiatExchangeRates`
264
- */
265
- chaintracksFiatExchangeRatesUrl?: string
266
- /**
267
- * Optional Chaintracks client API instance.
268
- * Default is a new instance of ChaintracksServiceClient configured to use:
269
- * mainnet: `https://mainnet-chaintracks.babbage.systems`
270
- * testnet: `https://testnet-chaintracks.babbage.systems`
271
- */
272
- chaintracks?: ChaintracksClientApi
273
- /**
274
- * TAAL ARC service provider endpoit to use
275
- * Default is:
276
- * mainnet: `https://arc.taal.com`
277
- * testnet: `https://arc-test.taal.com`
278
- */
279
- arcUrl: string
280
- /**
281
- * TAAL ARC service configuration options.
282
- *
283
- * apiKey Default value is undefined.
284
- *
285
- * deploymentId Default value: `wallet-toolbox-${randomBytesHex(16)}`.
286
- *
287
- * callbackUrl Default is undefined.
288
- * callbackToken Default is undefined.
289
- */
290
- arcConfig: ArcConfig
291
- /**
292
- * GorillaPool ARC service provider endpoit to use
293
- * Default is:
294
- * mainnet: `https://arc.gorillapool.io`
295
- * testnet: undefined
296
- */
297
- arcGorillaPoolUrl?: string
298
- /**
299
- * GorillaPool ARC service configuration options.
300
- *
301
- * apiKey Default is undefined.
302
- *
303
- * deploymentId Default value: `wallet-toolbox-${randomBytesHex(16)}`.
304
- *
305
- * callbackUrl Default is undefined.
306
- * callbackToken Default is undefined.
307
- */
308
- arcGorillaPoolConfig?: ArcConfig
309
- }
310
-
311
- export interface GetStatusForTxidsResult {
312
- /**
313
- * The name of the service returning these results.
314
- */
315
- name: string
316
- status: 'success' | 'error'
317
- /**
318
- * The first exception error that occurred during processing, if any.
319
- */
320
- error?: WalletError
321
- results: StatusForTxidResult[]
322
- }
323
-
324
- export interface StatusForTxidResult {
325
- txid: string
326
- /**
327
- * roughly depth of block containing txid from chain tip.
328
- */
329
- depth: number | undefined
330
- /**
331
- * 'mined' if depth > 0
332
- * 'known' if depth === 0
333
- * 'unknown' if depth === undefined, txid may be old an purged or never processed.
334
- */
335
- status: 'mined' | 'known' | 'unknown'
336
- }
337
-
338
- /**
339
- * Properties on result returned from `WalletServices` function `getRawTx`.
340
- */
341
- export interface GetRawTxResult {
342
- /**
343
- * Transaction hash or rawTx (and of initial request)
344
- */
345
- txid: string
346
- /**
347
- * The name of the service returning the rawTx, or undefined if no rawTx
348
- */
349
- name?: string
350
- /**
351
- * Multiple proofs may be returned when a transaction also appears in
352
- * one or more orphaned blocks
353
- */
354
- rawTx?: number[]
355
- /**
356
- * The first exception error that occurred during processing, if any.
357
- */
358
- error?: WalletError
359
- }
360
-
361
- /**
362
- * Properties on result returned from `WalletServices` function `getMerkleProof`.
363
- */
364
- export interface GetMerklePathResult {
365
- /**
366
- * The name of the service returning the proof, or undefined if no proof
367
- */
368
- name?: string
369
- /**
370
- * Multiple proofs may be returned when a transaction also appears in
371
- * one or more orphaned blocks
372
- */
373
- merklePath?: MerklePath
374
-
375
- header?: BlockHeader
376
-
377
- /**
378
- * The first exception error that occurred during processing, if any.
379
- */
380
- error?: WalletError
381
-
382
- notes?: ReqHistoryNote[]
383
- }
384
-
385
- export interface PostTxResultForTxid {
386
- txid: string
387
-
388
- /**
389
- * 'success' - The transaction was accepted for processing
390
- */
391
- status: 'success' | 'error'
392
-
393
- /**
394
- * if true, the transaction was already known to this service. Usually treat as a success.
395
- *
396
- * Potentially stop posting to additional transaction processors.
397
- */
398
- alreadyKnown?: boolean
399
-
400
- /**
401
- * service indicated this broadcast double spends at least one input
402
- * `competingTxs` may be an array of txids that were first seen spends of at least one input.
403
- */
404
- doubleSpend?: boolean
405
-
406
- blockHash?: string
407
- blockHeight?: number
408
- merklePath?: MerklePath
409
-
410
- competingTxs?: string[]
411
-
412
- data?: object | string | PostTxResultForTxidError
413
-
414
- notes?: ReqHistoryNote[]
415
-
416
- /**
417
- * true iff service was unable to process a potentially valid transaction
418
- */
419
- serviceError?: boolean
420
- }
421
-
422
- export interface PostTxResultForTxidError {
423
- status?: string
424
- detail?: string
425
- more?: object
426
- }
427
-
428
- export interface PostBeefResult extends PostTxsResult {}
429
-
430
- /**
431
- * Properties on array items of result returned from `WalletServices` function `postBeef`.
432
- */
433
- export interface PostTxsResult {
434
- /**
435
- * The name of the service to which the transaction was submitted for processing
436
- */
437
- name: string
438
- /**
439
- * 'success' all txids returned status of 'success'
440
- * 'error' one or more txids returned status of 'error'. See txidResults for details.
441
- */
442
- status: 'success' | 'error'
443
-
444
- error?: WalletError
445
-
446
- txidResults: PostTxResultForTxid[]
447
-
448
- /**
449
- * Service response object. Use service name and status to infer type of object.
450
- */
451
- data?: object
452
-
453
- notes?: ReqHistoryNote[]
454
- }
455
-
456
- export interface GetUtxoStatusDetails {
457
- /**
458
- * if isUtxo, the block height containing the matching unspent transaction output
459
- *
460
- * typically there will be only one, but future orphans can result in multiple values
461
- */
462
- height?: number
463
- /**
464
- * if isUtxo, the transaction hash (txid) of the transaction containing the matching unspent transaction output
465
- *
466
- * typically there will be only one, but future orphans can result in multiple values
467
- */
468
- txid?: string
469
- /**
470
- * if isUtxo, the output index in the transaction containing of the matching unspent transaction output
471
- *
472
- * typically there will be only one, but future orphans can result in multiple values
473
- */
474
- index?: number
475
- /**
476
- * if isUtxo, the amount of the matching unspent transaction output
477
- *
478
- * typically there will be only one, but future orphans can result in multiple values
479
- */
480
- satoshis?: number
481
- }
482
-
483
- export interface GetUtxoStatusResult {
484
- /**
485
- * The name of the service to which the transaction was submitted for processing
486
- */
487
- name: string
488
- /**
489
- * 'success' - the operation was successful, non-error results are valid.
490
- * 'error' - the operation failed, error may have relevant information.
491
- */
492
- status: 'success' | 'error'
493
- /**
494
- * When status is 'error', provides code and description
495
- */
496
- error?: WalletError
497
- /**
498
- * true if the output is associated with at least one unspent transaction output
499
- */
500
- isUtxo?: boolean
501
- /**
502
- * Additional details about occurances of this output script as a utxo.
503
- *
504
- * Normally there will be one item in the array but due to the possibility of orphan races
505
- * there could be more than one block in which it is a valid utxo.
506
- */
507
- details: GetUtxoStatusDetails[]
508
- }
509
-
510
- export interface GetScriptHashHistory {
511
- txid: string
512
- height?: number
513
- }
514
-
515
- export interface GetScriptHashHistoryResult {
516
- /**
517
- * The name of the service to which the transaction was submitted for processing
518
- */
519
- name: string
520
- /**
521
- * 'success' - the operation was successful, non-error results are valid.
522
- * 'error' - the operation failed, error may have relevant information.
523
- */
524
- status: 'success' | 'error'
525
- /**
526
- * When status is 'error', provides code and description
527
- */
528
- error?: WalletError
529
- /**
530
- * Transaction txid (and height if mined) that consumes the script hash. May not be a complete history.
531
- */
532
- history: GetScriptHashHistory[]
533
- }
534
-
535
- /**
536
- * These are fields of 80 byte serialized header in order whose double sha256 hash is a block's hash value
537
- * and the next block's previousHash value.
538
- *
539
- * All block hash values and merkleRoot values are 32 byte hex string values with the byte order reversed from the serialized byte order.
540
- */
541
- export interface BaseBlockHeader {
542
- /**
543
- * Block header version value. Serialized length is 4 bytes.
544
- */
545
- version: number
546
- /**
547
- * Hash of previous block's block header. Serialized length is 32 bytes.
548
- */
549
- previousHash: string
550
- /**
551
- * Root hash of the merkle tree of all transactions in this block. Serialized length is 32 bytes.
552
- */
553
- merkleRoot: string
554
- /**
555
- * Block header time value. Serialized length is 4 bytes.
556
- */
557
- time: number
558
- /**
559
- * Block header bits value. Serialized length is 4 bytes.
560
- */
561
- bits: number
562
- /**
563
- * Block header nonce value. Serialized length is 4 bytes.
564
- */
565
- nonce: number
566
- }
567
-
568
- /**
569
- * A `BaseBlockHeader` extended with its computed hash and height in its chain.
570
- */
571
- export interface BlockHeader extends BaseBlockHeader {
572
- /**
573
- * Height of the header, starting from zero.
574
- */
575
- height: number
576
- /**
577
- * The double sha256 hash of the serialized `BaseBlockHeader` fields.
578
- */
579
- hash: string
580
- }
581
-
582
- export type GetUtxoStatusService = (
583
- output: string,
584
- outputFormat?: GetUtxoStatusOutputFormat,
585
- outpoint?: string
586
- ) => Promise<GetUtxoStatusResult>
587
-
588
- export type GetStatusForTxidsService = (txids: string[]) => Promise<GetStatusForTxidsResult>
589
-
590
- export type GetScriptHashHistoryService = (hash: string) => Promise<GetScriptHashHistoryResult>
591
-
592
- export type GetMerklePathService = (txid: string, services: WalletServices) => Promise<GetMerklePathResult>
593
-
594
- export type GetRawTxService = (txid: string, chain: Chain) => Promise<GetRawTxResult>
595
-
596
- export type PostTxsService = (beef: Beef, txids: string[], services: WalletServices) => Promise<PostTxsResult>
597
-
598
- export type PostBeefService = (beef: Beef, txids: string[]) => Promise<PostBeefResult>
599
-
600
- export type UpdateFiatExchangeRateService = (
601
- targetCurrencies: string[],
602
- options: WalletServicesOptions
603
- ) => Promise<FiatExchangeRates>
604
-
605
- /**
606
- * Type for the service call history returned by Services.getServicesCallHistory.
607
- */
608
- export type ServicesCallHistory = {
609
- version: number
610
- getMerklePath: ServiceCallHistory
611
- getRawTx: ServiceCallHistory
612
- postBeef: ServiceCallHistory
613
- getUtxoStatus: ServiceCallHistory
614
- getStatusForTxids: ServiceCallHistory
615
- getScriptHashHistory: ServiceCallHistory
616
- updateFiatExchangeRates: ServiceCallHistory
617
- }
618
-
619
- /**
620
- * Minimum data tracked for each service call.
621
- */
622
- export interface ServiceCall {
623
- /**
624
- * string value must be Date's toISOString format.
625
- */
626
- when: Date | string
627
- msecs: number
628
- /**
629
- * true iff service provider successfully processed the request
630
- * false iff service provider failed to process the request which includes thrown errors.
631
- */
632
- success: boolean
633
- /**
634
- * Simple text summary of result. e.g. `not a valid utxo` or `valid utxo`
635
- */
636
- result?: string
637
- /**
638
- * Error code and message iff success is false and a exception was thrown.
639
- */
640
- error?: { message: string; code: string }
641
- }
642
-
643
- /**
644
- * Counts of service calls over a time interval.
645
- */
646
- export interface ServiceCallHistoryCounts {
647
- /**
648
- * count of calls returning success true.
649
- */
650
- success: number
651
- /**
652
- * count of calls returning success false.
653
- */
654
- failure: number
655
- /**
656
- * of failures (success false), count of calls with valid error code and message.
657
- */
658
- error: number
659
- /**
660
- * Counts are of calls over interval `since` to `until`.
661
- * string value must be Date's toISOString format.
662
- */
663
- since: Date | string
664
- /**
665
- * Counts are of calls over interval `since` to `until`.
666
- * string value must be Date's toISOString format.
667
- */
668
- until: Date | string
669
- }
670
-
671
- /**
672
- * History of service calls for a single service, single provider.
673
- */
674
- export interface ProviderCallHistory {
675
- providerName: string
676
- serviceName: string
677
- /**
678
- * Most recent service calls.
679
- * Array length is limited by Services configuration.
680
- */
681
- calls: ServiceCall[]
682
- /**
683
- * Counts since creation of Services instance.
684
- */
685
- totalCounts: ServiceCallHistoryCounts
686
- /**
687
- * Entry [0] is always the current interval being extended by new calls.
688
- * when `getServiceCallHistory` with `reset` true is called, a new interval with zero counts is added to the start of array.
689
- * Array length is limited by Services configuration.
690
- */
691
- resetCounts: ServiceCallHistoryCounts[]
692
- }
693
-
694
- /**
695
- * History of service calls for a single service, all providers.
696
- */
697
- export interface ServiceCallHistory {
698
- serviceName: string
699
- historyByProvider: Record<string, ProviderCallHistory>
700
- }
@@ -1,11 +0,0 @@
1
- import { KeyDeriverApi } from '@bsv/sdk'
2
- import { Chain } from './types'
3
-
4
- /**
5
- */
6
- export interface WalletSigner {
7
- isWalletSigner: true
8
-
9
- chain: Chain
10
- keyDeriver: KeyDeriverApi
11
- }