1

How to save the bundle trytes to reattach it after a snapshot? How to do this using the JavaScript library?

2
  1. Starting from the bundle hash, call the findTransactions API to get the transaction hashes of all transactions in your bundle.

  2. Pass the hashes to getTrytes to retrieve the transactions as tryte-encoded strings. You may want to sort the transactions in the original order (i. e. so that they are chained by trunk transaction hash) to avoid surprises when reattaching them later.

  3. How to store them depends on how persistent you need them and what storage media you have available (RAM, disk, local storage). But since they are all strings, there should not be any problem in this step. Now wait for the snapshot.

  4. Call the sendTrytes utility function. As first parameter, pass your array of tryte strings stored before.

| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.