Sign and Execute Transaction
// Create a transaction
const response = await window.martian.sui.connect(['viewAccount', 'suggestTransactions']);
const tx = new TransactionBlock();
tx.moveCall({
target: '0x2::devnet_nft::mint',
arguments: [
tx.pure('Hello'),
tx.pure('Martians'),
tx.pure('http://cdn.martianwallet.xyz/assets/icon.png'),
],
});
const input = {
transactionBlockSerialized: tx.serialize(),
options: {
showEffects: true,
}
}l
const transaction = await window.martian.sui.signAndExecuteTransactionBlock(input);Last updated