relayXmrTx method

Future<void> relayXmrTx(
  1. String metadata
)

Relays a signed XMR transaction to the network.

This method sends a RelayXmrTxRequest with the transaction metadata to relay the transaction to the Monero network.

Example:

await walletsService.relayXmrTx(txMetadata);

Implementation

Future<void> relayXmrTx(String metadata) async {
  if (!havenoChannel.isConnected) {
    throw DaemonNotConnectedException();
  }
  try {
    await havenoChannel.walletsClient!
        .relayXmrTx(RelayXmrTxRequest(metadata: metadata));
  } on GrpcError catch (e) {
    handleGrpcError(e);
  }
}