getAccountInfo method

Future<Map<String, dynamic>> getAccountInfo(
  1. String adress
)

Implementation

Future<Map<String, dynamic>> getAccountInfo(String adress) async {
  final res = await networkClient.postHTTP('', {
    "method": "account_info",
    "params": [
      {
        "account": adress,
        "strict": true,
        "ledger_index": "current",
        "queue": true
      }
    ],
    "id": "dontcare",
    "jsonrpc": "2.0",
  });
  if (res.isSuccess && res.data['result']['error'] == null) {
    return res.data['result'];
  } else {
    throw res.data;
  }
}