Skip to main content

createFromWallet method

*[<Null safety>](https://dart.dev/null-safety)*

Future<Client> createFromWallet (Api api, Signer wallet, {List<Codec<Object>> customCodecs = const []})

This creates a new Client instance using the Signer to trigger signature prompts to acquire user authentication keys.

Implementation

static Future<Client> createFromWallet(
Api api,
Signer wallet, {
List<Codec> customCodecs = const [],
}) async {
var client = await _createUninitialized(api, wallet.address, customCodecs);
await client._auth.authenticateWithCredentials(wallet);
await client._contacts.ensureSavedContact(client._auth.keys);
return client;
}