The instruction to be included in the transaction.
An object that contains a Solana wallet and network connection.
A promise that resolves to the result of sending the raw transaction or an error if the transaction fails to be sent after three attempts.
Generated using TypeDoc
This function sends a versioned transaction to the Solana blockchain.
It first fetches the recent blockhash and creates a
TransactionMessage
, which includes instructions to set the compute unit limit and the instruction passed to the function.Then, it fetches the lookup table account data and deserializes it. This data is used to compile the transaction message.
It then creates a new versioned transaction and tries to sign and send it to the Solana blockchain. If any error occurs, it retries up to three times before logging the error and returning it.
Throws
Will log any errors that occur while signing or sending the transaction.