resolveStellarTransactionId method
Resolves a stellar account transaction id such as c1b368c00e9852351361e07cc58c54277e7a6366580044ab152b8db9cd8ec52a The url of the federation server has to be provided. Returns a FederationResponse object.
Implementation
static Future<FederationResponse> resolveStellarTransactionId(
String txId, String federationServerUrl) async {
String id = checkNotNull(txId, "txId can not be null");
String server = checkNotNull(
federationServerUrl, "federationServerUrl can not be null");
Uri serverURI = Uri.parse(server);
http.Client httpClient = new http.Client();
_FederationRequestBuilder requestBuilder =
new _FederationRequestBuilder(httpClient, serverURI);
FederationResponse response =
await requestBuilder.forStringToLookUp(id).forType("txid").execute();
return response;
}