let a = new TonWeb.boc.Cell();
a.bits.writeUint(0, 32);
a.bits.writeString("contribute");
let payload = TonWeb.utils.bytesToBase64(await a.toBoc());
console.log(await connector.sendTransaction({
validUntil: Math.floor(new Date() / 1000) + 360,
messages: [
{
address: "Something",
amount: "100000000",
payload: payload
}
]
}));
Answered
What is the easiest way to send a transaction with TonConnect 2.0?
What's the easiest way to send a transaction with TonConnect 2.0?
For example,
message: "contribute"
value: "0.1 TON"
address: "[SOME_ADDRESS]"
2K Views
1
Answer
one year ago
one year ago
Tags