1

Here is my scenario:

I have a transaction that needs to be signed by A and B. I want to create this transaction and send it to each of them to be signed. The issue is that I need to to merge the two signature into the same transaction.

Is this possible somehow?

1

This is possible. Something like the following steps would help you..

(I took this directly from the JS SDK documentation)

  • Use TransactionBuilder to build a new transaction.
  • Make sure to set a long enough timeout on that transaction to give your signers enough time to sign!
  • Once you build the transaction, use transaction.toXDR() to get the base64-encoded XDR string.
  • Send this XDR string to your other parties. They can use the instructions for getKeypairSignature to sign the transaction.
  • They should send you back their publicKey and the signature string from getKeypairSignature, both of which you pass to this function (addSignature of Transaction object)

Please review the docs here: Stellar JS SDK TXN Documentation

1
  • I must have missed it, thank you a lot it seems exactly what I need indeed
    – GioGio
    Apr 1 at 8:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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