getStarknetAccount
Retrieves a Starknet WalletAccount instance from a wallet account, allowing you to interact with the Starknet blockchain.Usage
Parameters
| Parameter | Type | Description |
|---|---|---|
walletAccount | StarknetWalletAccount | The wallet account to get the Starknet account for |
client | DynamicClient (optional) | The Dynamic client instance. Only required when using multiple clients. |
Returns
Promise<{ account: WalletAccount }> - A promise that resolves to an object containing a WalletAccount instance from starknet.
Errors
| Error | Description |
|---|---|
NotStarknetProviderError | Thrown if the wallet account’s provider is not a Starknet provider |
Related functions
- isStarknetWalletAccount - Check if a wallet account is a Starknet account
- addStarknetExtension - Add Starknet blockchain support