legacy
TxTypeLegacyTransaction represents a type of transactions existed previously in kaia.
**This type of transaction can create an account, transfer tokens, deploy a smart contract, execute a smart contract, or perform a mix of aforementioned.
Import the web3 and @kaiachain/web3js-ext packages to add kaia features on web3
Define sender, reciver address and sender private key
Set up the provider with the specified kairos testnet URL. A provider in web3js is a read-only abstraction to access the blockchain data.
Also, you can change the provider URL from kairos to quicknode
Create a KlaytnWeb3 instance using the provider
Define transaction data with from (the sender address), to (receiver address), value (amount to transfer, use toPeb to set the value in Klay then it will be converted)
The privateKeyToAccount method create account instance from sender's private key.
The signTransaction method signs transaction with sender account.
The sendSignedTransaction method send the signed transaction into blockchain.
The getTransactionReceipt method returns the receipt of transaction.
Finally, get the result.