Create 2-of-2 Wallet
Minimal Flutter flow to create a 2-of-2 wallet.
Setup
dependencies:
blockchain_kit_sdk_flutter_plugin:
path: ../../../blockchain_kit_sdk_flutter_plugin
import 'package:blockchain_kit_sdk_flutter_plugin/blockchain_kit_sdk_flutter_plugin.dart';
Example
final sdk = BlockchainKitSdk();
final result = await sdk.create2of2Wallet('My 2of2 Wallet');
result.fold(
(wallet) {
// wallet.groupId, wallet.pubkeyB64, wallet.shareB64
print('Created 2-of-2 wallet: ${wallet.groupId}');
},
(error) {
print('Create wallet failed: ${error.message}');
},
);
Notes
- This returns wallet creation metadata (
groupId, public key, share payload). - Persist
groupId; you need it for signing, backup, and restore flows.