getTxInfo method

Future<TxResponse> getTxInfo(
  1. String txHash
)

Implementation

Future<TxResponse> getTxInfo(String txHash) async {
  var rootPath =
      "${TerraClientConfiguration.blockchainResourcePath}${CosmosBaseConstants.COSMOS_TX_TXS}/$txHash";

  print("HASH $txHash");
  var response = await apiRequester.getAsync<TxContainerJSON>(rootPath);
  if (response.successful!) {
    var result = TxContainerJSON.fromJson(response.result!);
    return result.tx_response!;
  }

  throw Exception("");
}