diff --git a/challenge/index.ts b/challenge/index.ts index 73e28a5..9304c64 100644 --- a/challenge/index.ts +++ b/challenge/index.ts @@ -28,11 +28,17 @@ const txn = algosdk.makePaymentTxnWithSuggestedParamsFromObject({ to: receiver.addr, amount: 1000000, }); +console.log(txn); + +const signedTxn = txn.signTxn(sender.sk); + +// And send the now Signed transaction! +const txId = await algodClient.sendRawTransaction(signedTxn).do(); +console.log("Transaction ID: ", txId); -await algodClient.sendRawTransaction(txn).do(); const result = await algosdk.waitForConfirmation( algodClient, - txn.txID().toString(), + txId.txId, 3 );