@omnity/ree-client-ts-sdk 0.3.3 → 0.3.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -117,6 +117,7 @@ const transaction = await client.createTransaction({
117
117
  // Intention 1: Deposit BTC to Pool 1
118
118
  transaction.addIntention({
119
119
  poolAddress: "bc1p...pool1",
120
+ poolUtxos: [],
120
121
  inputCoins: [
121
122
  {
122
123
  // Deposit 0.0005 BTC
@@ -135,6 +136,7 @@ transaction.addIntention({
135
136
  // Intention 2: Swap runes between pools
136
137
  transaction.addIntention({
137
138
  poolAddress: "bc1q...pool2",
139
+ poolUtxos: [],
138
140
  inputCoins: [
139
141
  {
140
142
  // Send 500 of rune A,
@@ -196,6 +198,7 @@ function WalletComponent() {
196
198
  // Add multiple intentions
197
199
  tx.addIntention({
198
200
  poolAddress: "pool1",
201
+ poolUtxos: [],
199
202
  inputCoins: [{
200
203
  coin: {
201
204
  id: "0:0",
@@ -216,6 +219,7 @@ function WalletComponent() {
216
219
 
217
220
  tx.addIntention({
218
221
  poolAddress: "pool2",
222
+ poolUtxos: [],
219
223
  inputCoins: [{
220
224
  coin: {
221
225
  id: "840000:3",
@@ -283,6 +287,7 @@ function MyComponent({ children }) {
283
287
 
284
288
  tx.addIntention({
285
289
  poolAddress: "bc1q...",
290
+ poolUtxos: [],
286
291
  inputCoins: [
287
292
  {
288
293
  coin: {
@@ -383,7 +388,6 @@ interface Intention {
383
388
  // Target pool address
384
389
  poolAddress: string;
385
390
  // the UTXOs obtained through the pool’s pre methods
386
- // if not provided, will be fetched via the maestro API.
387
391
  poolUtxos?: [];
388
392
  // Coins being sent to the pool
389
393
  inputCoins: InputCoin[];
package/dist/index.d.ts CHANGED
@@ -61,6 +61,8 @@ declare function getAddressType(address: string): AddressType;
61
61
 
62
62
  declare function getScriptByAddress(address: string, network?: Network): Uint8Array<ArrayBufferLike>;
63
63
 
64
+ declare function getUtxoProof(utxos: Utxo[], network: Network): Promise<number[] | null>;
65
+
64
66
  declare function hexToBytes(hex: string): Uint8Array;
65
67
 
66
68
  export declare type InputCoin = {
@@ -605,7 +607,8 @@ export declare namespace utils {
605
607
  toBitcoinNetwork,
606
608
  getScriptByAddress,
607
609
  getAddressType,
608
- formatPoolUtxo
610
+ formatPoolUtxo,
611
+ getUtxoProof
609
612
  }
610
613
  }
611
614