localListenAddresses method

Future<List<String>> localListenAddresses()

Returns the multi-addresses that the local node is listening on

The addresses include a trailing /p2p/ with the local PeerId, and are thus suitable to be passed to addReservedPeer or as a bootnode address for example.

Implementation

Future<List<String>> localListenAddresses() async {
  final response = await _provider.send('system_localListenAddresses', []);
  return (response.result as List).cast<String>().toList();
}