unsubscribe method

Future<String?> unsubscribe({
  1. String identifier = '',
  2. required String topic,
  3. String fee = '0',
  4. int? nonce,
})

unsubscribe from a topic for an identifier. Client using the same key pair and identifier will no longer receive messages from this topic. The signerRPCClient can be a client, multiclient or wallet.

Implementation

Future<String?> unsubscribe({
  String identifier = '',
  required String topic,
  String fee = '0',
  int? nonce,
}) async {
  try {
    return await _methodChannel.invokeMethod('unsubscribe', {
      'seed': this.seed,
      'identifier': identifier,
      'topic': topic,
      'fee': fee,
      'nonce': nonce,
      'seedRpc':
          this.walletConfig.seedRPCServerAddr ?? [DEFAULT_SEED_RPC_SERVER],
    });
  } catch (e) {
    rethrow;
  }
}