Hello Support,
In the Rust SDK, we can perform operations to wait for a transaction to finalize and check the result, as shown in the example below:
// Submit the transaction to the chain
let item = BlockItem::AccountTransaction(tx);
let transaction_hash = client.send_block_item(&item).await.context(“Failed to send block item”)?;
let (block_hash, block_status) = client.wait_until_finalized(&transaction_hash).await.context(“Failed to wait for transaction to be finalized”)?;
if block_status.is_reject() {
return Err(anyhow!(“Contract update failed: transaction rejected with tx: {}”, transaction_hash));
}
Has a similar feature been implemented in the Wallet API, particularly around the sendTransaction(..)
function? For instance, if the transaction is not rejected by the user, we could wait for finalization. While it is possible to manually query the chain for this, I was wondering if there is any built-in functionality already available.