@arkade-os/sdk 0.4.30 → 0.4.32

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 (53) hide show
  1. package/dist/adapters/expo.d.cts +2 -2
  2. package/dist/adapters/expo.d.ts +2 -2
  3. package/dist/adapters/indexedDB.cjs +2 -2
  4. package/dist/adapters/indexedDB.js +1 -1
  5. package/dist/{ark-C0TMXvwO.d.cts → ark-ibLW4Hte.d.cts} +1 -1
  6. package/dist/{ark-C0TMXvwO.d.ts → ark-ibLW4Hte.d.ts} +1 -1
  7. package/dist/{asyncStorageTaskQueue-Iip3xMF_.d.ts → asyncStorageTaskQueue-BEOFPNc0.d.ts} +1 -1
  8. package/dist/{asyncStorageTaskQueue-DHOoNvRy.d.cts → asyncStorageTaskQueue-VGHXWR9F.d.cts} +1 -1
  9. package/dist/{chunk-PCEE6DRL.cjs → chunk-I2UIKZM5.cjs} +7 -7
  10. package/dist/{chunk-PCEE6DRL.cjs.map → chunk-I2UIKZM5.cjs.map} +1 -1
  11. package/dist/{chunk-XWJFOP5G.cjs → chunk-KQK4PP6L.cjs} +77 -22
  12. package/dist/chunk-KQK4PP6L.cjs.map +1 -0
  13. package/dist/{chunk-GRJKJNBO.js → chunk-SHEBNWOQ.js} +3 -3
  14. package/dist/{chunk-GRJKJNBO.js.map → chunk-SHEBNWOQ.js.map} +1 -1
  15. package/dist/{chunk-6NY27WL6.js → chunk-XROGFOPX.js} +77 -22
  16. package/dist/chunk-XROGFOPX.js.map +1 -0
  17. package/dist/contracts/handlers/index.d.cts +3 -3
  18. package/dist/contracts/handlers/index.d.ts +3 -3
  19. package/dist/{delegate-Ds4Hi7Xy.d.ts → delegate-BXaR1RNG.d.ts} +1 -1
  20. package/dist/{delegate-CEk9RHVj.d.cts → delegate-BvNTw44a.d.cts} +1 -1
  21. package/dist/{index-DA9r_7Vg.d.ts → index-BusKawmy.d.ts} +2 -2
  22. package/dist/{index-WIAY0DDn.d.cts → index-C-5Tw7VA.d.cts} +2 -2
  23. package/dist/index.cjs +86 -86
  24. package/dist/index.d.cts +6 -6
  25. package/dist/index.d.ts +6 -6
  26. package/dist/index.js +1 -1
  27. package/dist/repositories/realm/index.cjs +10 -10
  28. package/dist/repositories/realm/index.d.cts +1 -1
  29. package/dist/repositories/realm/index.d.ts +1 -1
  30. package/dist/repositories/realm/index.js +1 -1
  31. package/dist/repositories/sqlite/index.cjs +10 -10
  32. package/dist/repositories/sqlite/index.d.cts +1 -1
  33. package/dist/repositories/sqlite/index.d.ts +1 -1
  34. package/dist/repositories/sqlite/index.js +1 -1
  35. package/dist/{taskRunner-JNjIWWJi.d.ts → taskRunner-B1igKGAo.d.ts} +1 -1
  36. package/dist/{taskRunner-CdEVYgoP.d.cts → taskRunner-By92TQ1m.d.cts} +1 -1
  37. package/dist/wallet/expo/background.cjs +8 -8
  38. package/dist/wallet/expo/background.d.cts +3 -3
  39. package/dist/wallet/expo/background.d.ts +3 -3
  40. package/dist/wallet/expo/background.js +2 -2
  41. package/dist/wallet/expo/index.cjs +9 -9
  42. package/dist/wallet/expo/index.d.cts +4 -4
  43. package/dist/wallet/expo/index.d.ts +4 -4
  44. package/dist/wallet/expo/index.js +2 -2
  45. package/dist/{wallet-CMgzKP0o.d.cts → wallet-B_rxgQTu.d.cts} +2 -2
  46. package/dist/{wallet-BGL6SzKQ.d.ts → wallet-CyM4F7Bs.d.ts} +2 -2
  47. package/dist/worker/expo/index.cjs +6 -6
  48. package/dist/worker/expo/index.d.cts +4 -4
  49. package/dist/worker/expo/index.d.ts +4 -4
  50. package/dist/worker/expo/index.js +2 -2
  51. package/package.json +1 -1
  52. package/dist/chunk-6NY27WL6.js.map +0 -1
  53. package/dist/chunk-XWJFOP5G.cjs.map +0 -1
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var chunkXWJFOP5G_cjs = require('../../chunk-XWJFOP5G.cjs');
3
+ var chunkKQK4PP6L_cjs = require('../../chunk-KQK4PP6L.cjs');
4
4
  require('../../chunk-6FLL2Q36.cjs');
5
5
  require('../../chunk-IEO3XDKI.cjs');
6
6
  require('../../chunk-WMIPYZSB.cjs');
@@ -37,7 +37,7 @@ var RealmWalletRepository = class {
37
37
  await this.ensureInit();
38
38
  this.realm.write(() => {
39
39
  for (const vtxo of vtxos) {
40
- const s = chunkXWJFOP5G_cjs.serializeVtxo(vtxo);
40
+ const s = chunkKQK4PP6L_cjs.serializeVtxo(vtxo);
41
41
  this.realm.create(
42
42
  "ArkVtxo",
43
43
  {
@@ -85,7 +85,7 @@ var RealmWalletRepository = class {
85
85
  throw new Error("RealmWalletRepository requires an address");
86
86
  }
87
87
  for (const vtxo of vtxos) {
88
- if (!chunkXWJFOP5G_cjs.isVtxoForScript(vtxo, key.script)) {
88
+ if (!chunkKQK4PP6L_cjs.isVtxoForScript(vtxo, key.script)) {
89
89
  throw new Error(
90
90
  `VTXO ${vtxo.txid}:${vtxo.vout} script mismatch: expected ${key.script}, got ${vtxo.script}`
91
91
  );
@@ -110,7 +110,7 @@ var RealmWalletRepository = class {
110
110
  await this.ensureInit();
111
111
  this.realm.write(() => {
112
112
  for (const utxo of utxos) {
113
- const s = chunkXWJFOP5G_cjs.serializeUtxo(utxo);
113
+ const s = chunkKQK4PP6L_cjs.serializeUtxo(utxo);
114
114
  this.realm.create(
115
115
  "ArkUtxo",
116
116
  {
@@ -163,7 +163,7 @@ var RealmWalletRepository = class {
163
163
  amount: tx.amount,
164
164
  settled: tx.settled,
165
165
  createdAt: tx.createdAt,
166
- assetsJson: tx.assets ? JSON.stringify(chunkXWJFOP5G_cjs.serializeAssets(tx.assets)) : null
166
+ assetsJson: tx.assets ? JSON.stringify(chunkKQK4PP6L_cjs.serializeAssets(tx.assets)) : null
167
167
  },
168
168
  "modified"
169
169
  );
@@ -233,9 +233,9 @@ function vtxoObjectToDomain(obj) {
233
233
  // Post-migration every row has `script`, but the backfill is
234
234
  // idempotent: derive from `address` if the legacy column is still
235
235
  // null (e.g. the migration hasn't run yet on this handle).
236
- script: obj.script ?? chunkXWJFOP5G_cjs.scriptFromArkAddress(obj.address)
236
+ script: obj.script ?? chunkKQK4PP6L_cjs.scriptFromArkAddress(obj.address)
237
237
  };
238
- return chunkXWJFOP5G_cjs.deserializeVtxo(serialized);
238
+ return chunkKQK4PP6L_cjs.deserializeVtxo(serialized);
239
239
  }
240
240
  function utxoObjectToDomain(obj) {
241
241
  const serialized = {
@@ -254,7 +254,7 @@ function utxoObjectToDomain(obj) {
254
254
  status: JSON.parse(obj.statusJson),
255
255
  extraWitness: obj.extraWitnessJson ? JSON.parse(obj.extraWitnessJson) : void 0
256
256
  };
257
- return chunkXWJFOP5G_cjs.deserializeUtxo(serialized);
257
+ return chunkKQK4PP6L_cjs.deserializeUtxo(serialized);
258
258
  }
259
259
  function txObjectToDomain(obj) {
260
260
  const tx = {
@@ -269,7 +269,7 @@ function txObjectToDomain(obj) {
269
269
  createdAt: obj.createdAt
270
270
  };
271
271
  if (obj.assetsJson) {
272
- tx.assets = chunkXWJFOP5G_cjs.deserializeAssets(JSON.parse(obj.assetsJson));
272
+ tx.assets = chunkKQK4PP6L_cjs.deserializeAssets(JSON.parse(obj.assetsJson));
273
273
  }
274
274
  return tx;
275
275
  }
@@ -499,7 +499,7 @@ function runArkRealmMigrations(oldRealm, newRealm) {
499
499
  for (let i = 0; i < newVtxos.length; i++) {
500
500
  const newVtxo = newVtxos[i];
501
501
  if (!newVtxo.script) {
502
- newVtxo.script = chunkXWJFOP5G_cjs.scriptFromArkAddress(newVtxo.address);
502
+ newVtxo.script = chunkKQK4PP6L_cjs.scriptFromArkAddress(newVtxo.address);
503
503
  }
504
504
  }
505
505
  }
@@ -1,4 +1,4 @@
1
- import { W as WalletRepository, E as ExtendedVirtualCoin, a2 as VtxoRepositoryKey, d as ExtendedCoin, A as ArkTransaction, a3 as WalletState, C as ContractRepository, a4 as ContractFilter, r as Contract } from '../../ark-C0TMXvwO.cjs';
1
+ import { W as WalletRepository, E as ExtendedVirtualCoin, s as VtxoRepositoryKey, d as ExtendedCoin, A as ArkTransaction, t as WalletState, C as ContractRepository, u as ContractFilter, r as Contract } from '../../ark-ibLW4Hte.cjs';
2
2
  import '@scure/btc-signer/transaction.js';
3
3
  import '@scure/btc-signer/utils.js';
4
4
  import '@scure/btc-signer/psbt.js';
@@ -1,4 +1,4 @@
1
- import { W as WalletRepository, E as ExtendedVirtualCoin, a2 as VtxoRepositoryKey, d as ExtendedCoin, A as ArkTransaction, a3 as WalletState, C as ContractRepository, a4 as ContractFilter, r as Contract } from '../../ark-C0TMXvwO.js';
1
+ import { W as WalletRepository, E as ExtendedVirtualCoin, s as VtxoRepositoryKey, d as ExtendedCoin, A as ArkTransaction, t as WalletState, C as ContractRepository, u as ContractFilter, r as Contract } from '../../ark-ibLW4Hte.js';
2
2
  import '@scure/btc-signer/transaction.js';
3
3
  import '@scure/btc-signer/utils.js';
4
4
  import '@scure/btc-signer/psbt.js';
@@ -1,4 +1,4 @@
1
- import { serializeVtxo, isVtxoForScript, serializeUtxo, serializeAssets, scriptFromArkAddress, deserializeVtxo, deserializeUtxo, deserializeAssets } from '../../chunk-6NY27WL6.js';
1
+ import { serializeVtxo, isVtxoForScript, serializeUtxo, serializeAssets, scriptFromArkAddress, deserializeVtxo, deserializeUtxo, deserializeAssets } from '../../chunk-XROGFOPX.js';
2
2
  import '../../chunk-6NWNOLL3.js';
3
3
  import '../../chunk-YA4G7RFB.js';
4
4
  import '../../chunk-TU3LVAPX.js';
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var chunkXWJFOP5G_cjs = require('../../chunk-XWJFOP5G.cjs');
3
+ var chunkKQK4PP6L_cjs = require('../../chunk-KQK4PP6L.cjs');
4
4
  require('../../chunk-6FLL2Q36.cjs');
5
5
  require('../../chunk-IEO3XDKI.cjs');
6
6
  require('../../chunk-WMIPYZSB.cjs');
@@ -126,7 +126,7 @@ var SQLiteWalletRepository = class {
126
126
  for (const row of nullRows) {
127
127
  await this.db.run(
128
128
  `UPDATE ${this.tables.vtxos} SET script = ? WHERE txid = ? AND vout = ?`,
129
- [chunkXWJFOP5G_cjs.scriptFromArkAddress(row.address), row.txid, row.vout]
129
+ [chunkKQK4PP6L_cjs.scriptFromArkAddress(row.address), row.txid, row.vout]
130
130
  );
131
131
  }
132
132
  const tempName = `${this.tables.vtxos}__migrate_tmp`;
@@ -204,7 +204,7 @@ var SQLiteWalletRepository = class {
204
204
  async saveVtxos(address, vtxos) {
205
205
  await this.ensureInit();
206
206
  for (const vtxo of vtxos) {
207
- const s = chunkXWJFOP5G_cjs.serializeVtxo(vtxo);
207
+ const s = chunkKQK4PP6L_cjs.serializeVtxo(vtxo);
208
208
  await this.db.run(
209
209
  `INSERT OR REPLACE INTO ${this.tables.vtxos}
210
210
  (txid, vout, value, address,
@@ -259,7 +259,7 @@ var SQLiteWalletRepository = class {
259
259
  throw new Error("SQLiteWalletRepository requires an address");
260
260
  }
261
261
  for (const vtxo of vtxos) {
262
- if (!chunkXWJFOP5G_cjs.isVtxoForScript(vtxo, key.script)) {
262
+ if (!chunkKQK4PP6L_cjs.isVtxoForScript(vtxo, key.script)) {
263
263
  throw new Error(
264
264
  `VTXO ${vtxo.txid}:${vtxo.vout} script mismatch: expected ${key.script}, got ${vtxo.script}`
265
265
  );
@@ -283,7 +283,7 @@ var SQLiteWalletRepository = class {
283
283
  async saveUtxos(address, utxos) {
284
284
  await this.ensureInit();
285
285
  for (const utxo of utxos) {
286
- const s = chunkXWJFOP5G_cjs.serializeUtxo(utxo);
286
+ const s = chunkKQK4PP6L_cjs.serializeUtxo(utxo);
287
287
  await this.db.run(
288
288
  `INSERT OR REPLACE INTO ${this.tables.utxos}
289
289
  (txid, vout, value, address,
@@ -339,7 +339,7 @@ var SQLiteWalletRepository = class {
339
339
  tx.amount,
340
340
  tx.settled ? 1 : 0,
341
341
  tx.createdAt,
342
- tx.assets ? JSON.stringify(chunkXWJFOP5G_cjs.serializeAssets(tx.assets)) : null
342
+ tx.assets ? JSON.stringify(chunkKQK4PP6L_cjs.serializeAssets(tx.assets)) : null
343
343
  ]
344
344
  );
345
345
  }
@@ -413,9 +413,9 @@ function vtxoRowToDomain(row) {
413
413
  // Post-migration every row has `script`, but the backfill is
414
414
  // idempotent: derive from `address` if the legacy column is still
415
415
  // null (e.g. the migration hasn't run yet on this handle).
416
- script: row.script ?? chunkXWJFOP5G_cjs.scriptFromArkAddress(row.address)
416
+ script: row.script ?? chunkKQK4PP6L_cjs.scriptFromArkAddress(row.address)
417
417
  };
418
- return chunkXWJFOP5G_cjs.deserializeVtxo(serialized);
418
+ return chunkKQK4PP6L_cjs.deserializeVtxo(serialized);
419
419
  }
420
420
  function utxoRowToDomain(row) {
421
421
  const serialized = {
@@ -434,7 +434,7 @@ function utxoRowToDomain(row) {
434
434
  status: JSON.parse(row.status_json),
435
435
  extraWitness: row.extra_witness_json ? JSON.parse(row.extra_witness_json) : void 0
436
436
  };
437
- return chunkXWJFOP5G_cjs.deserializeUtxo(serialized);
437
+ return chunkKQK4PP6L_cjs.deserializeUtxo(serialized);
438
438
  }
439
439
  function txRowToDomain(row) {
440
440
  const tx = {
@@ -449,7 +449,7 @@ function txRowToDomain(row) {
449
449
  createdAt: row.created_at
450
450
  };
451
451
  if (row.assets_json) {
452
- tx.assets = chunkXWJFOP5G_cjs.deserializeAssets(JSON.parse(row.assets_json));
452
+ tx.assets = chunkKQK4PP6L_cjs.deserializeAssets(JSON.parse(row.assets_json));
453
453
  }
454
454
  return tx;
455
455
  }
@@ -1,4 +1,4 @@
1
- import { W as WalletRepository, E as ExtendedVirtualCoin, a2 as VtxoRepositoryKey, d as ExtendedCoin, A as ArkTransaction, a3 as WalletState, C as ContractRepository, a4 as ContractFilter, r as Contract } from '../../ark-C0TMXvwO.cjs';
1
+ import { W as WalletRepository, E as ExtendedVirtualCoin, s as VtxoRepositoryKey, d as ExtendedCoin, A as ArkTransaction, t as WalletState, C as ContractRepository, u as ContractFilter, r as Contract } from '../../ark-ibLW4Hte.cjs';
2
2
  import '@scure/btc-signer/transaction.js';
3
3
  import '@scure/btc-signer/utils.js';
4
4
  import '@scure/btc-signer/psbt.js';
@@ -1,4 +1,4 @@
1
- import { W as WalletRepository, E as ExtendedVirtualCoin, a2 as VtxoRepositoryKey, d as ExtendedCoin, A as ArkTransaction, a3 as WalletState, C as ContractRepository, a4 as ContractFilter, r as Contract } from '../../ark-C0TMXvwO.js';
1
+ import { W as WalletRepository, E as ExtendedVirtualCoin, s as VtxoRepositoryKey, d as ExtendedCoin, A as ArkTransaction, t as WalletState, C as ContractRepository, u as ContractFilter, r as Contract } from '../../ark-ibLW4Hte.js';
2
2
  import '@scure/btc-signer/transaction.js';
3
3
  import '@scure/btc-signer/utils.js';
4
4
  import '@scure/btc-signer/psbt.js';
@@ -1,4 +1,4 @@
1
- import { scriptFromArkAddress, serializeVtxo, isVtxoForScript, serializeUtxo, serializeAssets, deserializeVtxo, deserializeUtxo, deserializeAssets } from '../../chunk-6NY27WL6.js';
1
+ import { scriptFromArkAddress, serializeVtxo, isVtxoForScript, serializeUtxo, serializeAssets, deserializeVtxo, deserializeUtxo, deserializeAssets } from '../../chunk-XROGFOPX.js';
2
2
  import '../../chunk-6NWNOLL3.js';
3
3
  import '../../chunk-YA4G7RFB.js';
4
4
  import '../../chunk-TU3LVAPX.js';
@@ -1,4 +1,4 @@
1
- import { W as WalletRepository, C as ContractRepository, n as IndexerProvider, m as ArkProvider, q as VirtualCoin, r as Contract, E as ExtendedVirtualCoin } from './ark-C0TMXvwO.js';
1
+ import { W as WalletRepository, C as ContractRepository, n as IndexerProvider, m as ArkProvider, q as VirtualCoin, r as Contract, E as ExtendedVirtualCoin } from './ark-ibLW4Hte.js';
2
2
 
3
3
  /**
4
4
  * A task item represents a unit of work in the inbox.
@@ -1,4 +1,4 @@
1
- import { W as WalletRepository, C as ContractRepository, n as IndexerProvider, m as ArkProvider, q as VirtualCoin, r as Contract, E as ExtendedVirtualCoin } from './ark-C0TMXvwO.cjs';
1
+ import { W as WalletRepository, C as ContractRepository, n as IndexerProvider, m as ArkProvider, q as VirtualCoin, r as Contract, E as ExtendedVirtualCoin } from './ark-ibLW4Hte.cjs';
2
2
 
3
3
  /**
4
4
  * A task item represents a unit of work in the inbox.
@@ -1,8 +1,8 @@
1
1
  'use strict';
2
2
 
3
- var chunkPCEE6DRL_cjs = require('../../chunk-PCEE6DRL.cjs');
3
+ var chunkI2UIKZM5_cjs = require('../../chunk-I2UIKZM5.cjs');
4
4
  var chunkGIGILVVP_cjs = require('../../chunk-GIGILVVP.cjs');
5
- var chunkXWJFOP5G_cjs = require('../../chunk-XWJFOP5G.cjs');
5
+ var chunkKQK4PP6L_cjs = require('../../chunk-KQK4PP6L.cjs');
6
6
  require('../../chunk-6FLL2Q36.cjs');
7
7
  require('../../chunk-IEO3XDKI.cjs');
8
8
  require('../../chunk-WMIPYZSB.cjs');
@@ -36,7 +36,7 @@ function defineExpoBackgroundTask(taskName, options) {
36
36
  taskQueue,
37
37
  walletRepository,
38
38
  contractRepository,
39
- processors = [chunkPCEE6DRL_cjs.contractPollProcessor]
39
+ processors = [chunkI2UIKZM5_cjs.contractPollProcessor]
40
40
  } = options;
41
41
  TaskManager__namespace.defineTask(taskName, async () => {
42
42
  try {
@@ -46,22 +46,22 @@ function defineExpoBackgroundTask(taskName, options) {
46
46
  }
47
47
  const indexerProvider = new chunkGIGILVVP_cjs.ExpoIndexerProvider(config.arkServerUrl);
48
48
  const arkProvider = new chunkGIGILVVP_cjs.ExpoArkProvider(config.arkServerUrl);
49
- const deps = chunkPCEE6DRL_cjs.createTaskDependencies({
49
+ const deps = chunkI2UIKZM5_cjs.createTaskDependencies({
50
50
  walletRepository,
51
51
  contractRepository,
52
52
  indexerProvider,
53
53
  arkProvider
54
54
  });
55
- await chunkPCEE6DRL_cjs.runTasks(taskQueue, processors, deps);
55
+ await chunkI2UIKZM5_cjs.runTasks(taskQueue, processors, deps);
56
56
  const results = await taskQueue.getResults();
57
57
  if (results.length > 0) {
58
58
  await taskQueue.acknowledgeResults(results.map((r) => r.id));
59
59
  }
60
- const existing = await taskQueue.getTasks(chunkPCEE6DRL_cjs.CONTRACT_POLL_TASK_TYPE);
60
+ const existing = await taskQueue.getTasks(chunkI2UIKZM5_cjs.CONTRACT_POLL_TASK_TYPE);
61
61
  if (existing.length === 0) {
62
62
  const task = {
63
- id: chunkXWJFOP5G_cjs.getRandomId(),
64
- type: chunkPCEE6DRL_cjs.CONTRACT_POLL_TASK_TYPE,
63
+ id: chunkKQK4PP6L_cjs.getRandomId(),
64
+ type: chunkI2UIKZM5_cjs.CONTRACT_POLL_TASK_TYPE,
65
65
  data: {},
66
66
  createdAt: Date.now()
67
67
  };
@@ -1,6 +1,6 @@
1
- import { W as WalletRepository, C as ContractRepository } from '../../ark-C0TMXvwO.cjs';
2
- import { A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-DHOoNvRy.cjs';
3
- import { T as TaskProcessor } from '../../taskRunner-CdEVYgoP.cjs';
1
+ import { W as WalletRepository, C as ContractRepository } from '../../ark-ibLW4Hte.cjs';
2
+ import { A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-VGHXWR9F.cjs';
3
+ import { T as TaskProcessor } from '../../taskRunner-By92TQ1m.cjs';
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,6 +1,6 @@
1
- import { W as WalletRepository, C as ContractRepository } from '../../ark-C0TMXvwO.js';
2
- import { A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-Iip3xMF_.js';
3
- import { T as TaskProcessor } from '../../taskRunner-JNjIWWJi.js';
1
+ import { W as WalletRepository, C as ContractRepository } from '../../ark-ibLW4Hte.js';
2
+ import { A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-BEOFPNc0.js';
3
+ import { T as TaskProcessor } from '../../taskRunner-B1igKGAo.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,6 +1,6 @@
1
- import { contractPollProcessor, createTaskDependencies, runTasks, CONTRACT_POLL_TASK_TYPE } from '../../chunk-GRJKJNBO.js';
1
+ import { contractPollProcessor, createTaskDependencies, runTasks, CONTRACT_POLL_TASK_TYPE } from '../../chunk-SHEBNWOQ.js';
2
2
  import { ExpoIndexerProvider, ExpoArkProvider } from '../../chunk-ABWRLTX5.js';
3
- import { getRandomId } from '../../chunk-6NY27WL6.js';
3
+ import { getRandomId } from '../../chunk-XROGFOPX.js';
4
4
  import '../../chunk-6NWNOLL3.js';
5
5
  import '../../chunk-YA4G7RFB.js';
6
6
  import '../../chunk-TU3LVAPX.js';
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- var chunkPCEE6DRL_cjs = require('../../chunk-PCEE6DRL.cjs');
4
- var chunkXWJFOP5G_cjs = require('../../chunk-XWJFOP5G.cjs');
3
+ var chunkI2UIKZM5_cjs = require('../../chunk-I2UIKZM5.cjs');
4
+ var chunkKQK4PP6L_cjs = require('../../chunk-KQK4PP6L.cjs');
5
5
  var chunk6FLL2Q36_cjs = require('../../chunk-6FLL2Q36.cjs');
6
6
  var chunkIEO3XDKI_cjs = require('../../chunk-IEO3XDKI.cjs');
7
7
  require('../../chunk-WMIPYZSB.cjs');
@@ -52,14 +52,14 @@ var ExpoWallet = class _ExpoWallet {
52
52
  */
53
53
  static async setup(config) {
54
54
  warnOnRemovedBackgroundFields(config.background);
55
- const wallet = await chunkXWJFOP5G_cjs.Wallet.create(config);
56
- const processors = config.background.processors ?? [chunkPCEE6DRL_cjs.contractPollProcessor];
55
+ const wallet = await chunkKQK4PP6L_cjs.Wallet.create(config);
56
+ const processors = config.background.processors ?? [chunkI2UIKZM5_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) => chunkXWJFOP5G_cjs.extendVirtualCoinForContract(vtxo, contract)
62
+ extendVtxo: (vtxo, contract) => chunkKQK4PP6L_cjs.extendVirtualCoinForContract(vtxo, contract)
63
63
  };
64
64
  const { taskQueue } = config.background;
65
65
  if ("persistConfig" in taskQueue) {
@@ -93,7 +93,7 @@ var ExpoWallet = class _ExpoWallet {
93
93
  }, intervalMs);
94
94
  }
95
95
  async runForegroundPoll() {
96
- await chunkPCEE6DRL_cjs.runTasks(this.taskQueue, this.processors, this.deps);
96
+ await chunkI2UIKZM5_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(chunkPCEE6DRL_cjs.CONTRACT_POLL_TASK_TYPE);
104
+ const existing = await this.taskQueue.getTasks(chunkI2UIKZM5_cjs.CONTRACT_POLL_TASK_TYPE);
105
105
  if (existing.length > 0) return;
106
106
  const task = {
107
- id: chunkXWJFOP5G_cjs.getRandomId(),
108
- type: chunkPCEE6DRL_cjs.CONTRACT_POLL_TASK_TYPE,
107
+ id: chunkKQK4PP6L_cjs.getRandomId(),
108
+ type: chunkI2UIKZM5_cjs.CONTRACT_POLL_TASK_TYPE,
109
109
  data: {},
110
110
  createdAt: Date.now()
111
111
  };
@@ -1,9 +1,9 @@
1
- import { W as Wallet } from '../../wallet-CMgzKP0o.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-C0TMXvwO.cjs';
3
- import { a as TaskQueue, T as TaskProcessor } from '../../taskRunner-CdEVYgoP.cjs';
1
+ import { W as Wallet } from '../../wallet-B_rxgQTu.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-ibLW4Hte.cjs';
3
+ import { a as TaskQueue, T as TaskProcessor } from '../../taskRunner-By92TQ1m.cjs';
4
4
  import '@scure/btc-signer/utils.js';
5
5
  import '@scure/btc-signer/psbt.js';
6
- import '../../delegate-CEk9RHVj.cjs';
6
+ import '../../delegate-BvNTw44a.cjs';
7
7
  import '@scure/btc-signer/transaction.js';
8
8
  import '@scure/btc-signer';
9
9
 
@@ -1,9 +1,9 @@
1
- import { W as Wallet } from '../../wallet-BGL6SzKQ.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-C0TMXvwO.js';
3
- import { a as TaskQueue, T as TaskProcessor } from '../../taskRunner-JNjIWWJi.js';
1
+ import { W as Wallet } from '../../wallet-CyM4F7Bs.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-ibLW4Hte.js';
3
+ import { a as TaskQueue, T as TaskProcessor } from '../../taskRunner-B1igKGAo.js';
4
4
  import '@scure/btc-signer/utils.js';
5
5
  import '@scure/btc-signer/psbt.js';
6
- import '../../delegate-Ds4Hi7Xy.js';
6
+ import '../../delegate-BXaR1RNG.js';
7
7
  import '@scure/btc-signer/transaction.js';
8
8
  import '@scure/btc-signer';
9
9
 
@@ -1,5 +1,5 @@
1
- import { contractPollProcessor, runTasks, CONTRACT_POLL_TASK_TYPE } from '../../chunk-GRJKJNBO.js';
2
- import { Wallet, getRandomId, extendVirtualCoinForContract } from '../../chunk-6NY27WL6.js';
1
+ import { contractPollProcessor, runTasks, CONTRACT_POLL_TASK_TYPE } from '../../chunk-SHEBNWOQ.js';
2
+ import { Wallet, getRandomId, extendVirtualCoinForContract } from '../../chunk-XROGFOPX.js';
3
3
  import { RestArkProvider } from '../../chunk-6NWNOLL3.js';
4
4
  import { DefaultVtxo } from '../../chunk-YA4G7RFB.js';
5
5
  import '../../chunk-TU3LVAPX.js';
@@ -1,7 +1,7 @@
1
1
  import { Bytes } from '@scure/btc-signer/utils.js';
2
- 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-C0TMXvwO.cjs';
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-ibLW4Hte.cjs';
3
3
  import { TransactionOutput } from '@scure/btc-signer/psbt.js';
4
- import { D as DefaultVtxo, a as DelegateVtxo } from './delegate-CEk9RHVj.cjs';
4
+ import { D as DefaultVtxo, a as DelegateVtxo } from './delegate-BvNTw44a.cjs';
5
5
 
6
6
  /**
7
7
  * Batch namespace provides utilities for joining and processing batch session.
@@ -1,7 +1,7 @@
1
1
  import { Bytes } from '@scure/btc-signer/utils.js';
2
- 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-C0TMXvwO.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-ibLW4Hte.js';
3
3
  import { TransactionOutput } from '@scure/btc-signer/psbt.js';
4
- import { D as DefaultVtxo, a as DelegateVtxo } from './delegate-Ds4Hi7Xy.js';
4
+ import { D as DefaultVtxo, a as DelegateVtxo } from './delegate-BXaR1RNG.js';
5
5
 
6
6
  /**
7
7
  * Batch namespace provides utilities for joining and processing batch session.
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- var chunkPCEE6DRL_cjs = require('../../chunk-PCEE6DRL.cjs');
4
- require('../../chunk-XWJFOP5G.cjs');
3
+ var chunkI2UIKZM5_cjs = require('../../chunk-I2UIKZM5.cjs');
4
+ require('../../chunk-KQK4PP6L.cjs');
5
5
  require('../../chunk-6FLL2Q36.cjs');
6
6
  require('../../chunk-IEO3XDKI.cjs');
7
7
  require('../../chunk-WMIPYZSB.cjs');
@@ -120,19 +120,19 @@ var AsyncStorageTaskQueue = class {
120
120
 
121
121
  Object.defineProperty(exports, "CONTRACT_POLL_TASK_TYPE", {
122
122
  enumerable: true,
123
- get: function () { return chunkPCEE6DRL_cjs.CONTRACT_POLL_TASK_TYPE; }
123
+ get: function () { return chunkI2UIKZM5_cjs.CONTRACT_POLL_TASK_TYPE; }
124
124
  });
125
125
  Object.defineProperty(exports, "contractPollProcessor", {
126
126
  enumerable: true,
127
- get: function () { return chunkPCEE6DRL_cjs.contractPollProcessor; }
127
+ get: function () { return chunkI2UIKZM5_cjs.contractPollProcessor; }
128
128
  });
129
129
  Object.defineProperty(exports, "createTaskDependencies", {
130
130
  enumerable: true,
131
- get: function () { return chunkPCEE6DRL_cjs.createTaskDependencies; }
131
+ get: function () { return chunkI2UIKZM5_cjs.createTaskDependencies; }
132
132
  });
133
133
  Object.defineProperty(exports, "runTasks", {
134
134
  enumerable: true,
135
- get: function () { return chunkPCEE6DRL_cjs.runTasks; }
135
+ get: function () { return chunkI2UIKZM5_cjs.runTasks; }
136
136
  });
137
137
  exports.AsyncStorageTaskQueue = AsyncStorageTaskQueue;
138
138
  exports.InMemoryTaskQueue = InMemoryTaskQueue;
@@ -1,7 +1,7 @@
1
- import { T as TaskProcessor } from '../../taskRunner-CdEVYgoP.cjs';
2
- export { C as CreateTaskDependenciesOptions, I as InMemoryTaskQueue, b as TaskDependencies, c as TaskItem, a as TaskQueue, d as TaskResult, e as createTaskDependencies, r as runTasks } from '../../taskRunner-CdEVYgoP.cjs';
3
- export { a as AsyncStorageLike, A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-DHOoNvRy.cjs';
4
- import '../../ark-C0TMXvwO.cjs';
1
+ import { T as TaskProcessor } from '../../taskRunner-By92TQ1m.cjs';
2
+ export { C as CreateTaskDependenciesOptions, I as InMemoryTaskQueue, b as TaskDependencies, c as TaskItem, a as TaskQueue, d as TaskResult, e as createTaskDependencies, r as runTasks } from '../../taskRunner-By92TQ1m.cjs';
3
+ export { a as AsyncStorageLike, A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-VGHXWR9F.cjs';
4
+ import '../../ark-ibLW4Hte.cjs';
5
5
  import '@scure/btc-signer/transaction.js';
6
6
  import '@scure/btc-signer/utils.js';
7
7
  import '@scure/btc-signer/psbt.js';
@@ -1,7 +1,7 @@
1
- import { T as TaskProcessor } from '../../taskRunner-JNjIWWJi.js';
2
- export { C as CreateTaskDependenciesOptions, I as InMemoryTaskQueue, b as TaskDependencies, c as TaskItem, a as TaskQueue, d as TaskResult, e as createTaskDependencies, r as runTasks } from '../../taskRunner-JNjIWWJi.js';
3
- export { a as AsyncStorageLike, A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-Iip3xMF_.js';
4
- import '../../ark-C0TMXvwO.js';
1
+ import { T as TaskProcessor } from '../../taskRunner-B1igKGAo.js';
2
+ export { C as CreateTaskDependenciesOptions, I as InMemoryTaskQueue, b as TaskDependencies, c as TaskItem, a as TaskQueue, d as TaskResult, e as createTaskDependencies, r as runTasks } from '../../taskRunner-B1igKGAo.js';
3
+ export { a as AsyncStorageLike, A as AsyncStorageTaskQueue } from '../../asyncStorageTaskQueue-BEOFPNc0.js';
4
+ import '../../ark-ibLW4Hte.js';
5
5
  import '@scure/btc-signer/transaction.js';
6
6
  import '@scure/btc-signer/utils.js';
7
7
  import '@scure/btc-signer/psbt.js';
@@ -1,5 +1,5 @@
1
- export { CONTRACT_POLL_TASK_TYPE, contractPollProcessor, createTaskDependencies, runTasks } from '../../chunk-GRJKJNBO.js';
2
- import '../../chunk-6NY27WL6.js';
1
+ export { CONTRACT_POLL_TASK_TYPE, contractPollProcessor, createTaskDependencies, runTasks } from '../../chunk-SHEBNWOQ.js';
2
+ import '../../chunk-XROGFOPX.js';
3
3
  import '../../chunk-6NWNOLL3.js';
4
4
  import '../../chunk-YA4G7RFB.js';
5
5
  import '../../chunk-TU3LVAPX.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arkade-os/sdk",
3
- "version": "0.4.30",
3
+ "version": "0.4.32",
4
4
  "description": "TypeScript SDK for building Bitcoin wallets using the Arkade protocol",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",