Unanswered
Is it possible to somehow reduce the transaction execution time or send multiple transactions at one time? (nodejs)
I'm using an example from the tutorial (https://ton-community.github.io/tutorials/01-wallet /) based on the npm ton library and solve a problem where I have an array with wallets and values for transfer and I have to send funds to them quickly enough
I'm new to this area, but I guess I can't make a new transaction until the seqno changes.
My transactions are made with a frequency about 1 transaction in 10 seconds, but on the tonscan.org I saw wallets with 10 transactions sent per second. Is there anything I can do to send all transactions at once or speed up the execution time?
Thanks in advance for any hint! Code below
var lines = fs.readFileSync('to_pay.txt', 'utf8').split(/\r?\n/);
for (const item of lines) {
var data = item.split(' ')
const walletContract = client.open(wallet);
const seqno = await walletContract.getSeqno();
console.log('seqno is '+ seqno)
await walletContract.sendTransfer({
secretKey: key.secretKey,
seqno: seqno,
messages: [
internal({
to: data[0],
value: data[1],
body: "Transfer",
bounce: false,
})
]
});
6K Views
0
Answers
one year ago
one year ago
Tags