Keyring Controller
All the wallet management & Chain Interactions executing on the client side is managed by this class.
Create an instance
const keyring = new KeyringController({
baseUrl: 'http://localhost:8000',
walletType: {
embedded: true, // for external wallet it should be false
supportAa: true, // false if dapp only wants EOA wallets
},
sentryDns, // string
environment, // ENV
sessionSignatures, //[OPTIONAL] SESSION SIG FROM litController.initSession
currentAccount, //[OPTIONAL] fetch PKPs FROM litController.fetchPKPs
customAuthMethod,
accessToken,
aa,
selectedWallet,
} as TriaArgs);
export type TriaArgs = {
baseUrl: string;
sentryDns?: string;
walletType?: WalletType;
selectedChainName?: ChainName;
environment?: ENV;
currentAccount?: IRelayPKP;
sessionSignatures?: string;
customAuthMethod?: LitCustomAuthMethod;
accessToken?: string;
aa?: AaDetails;
selectedWallet?: "EOA" | "AA";
};
export type ENV = 'testnet' | 'mainnet-staging' | 'mainnet';Functions
Reconstruction of Vault
Social Login [v2]
Create Account [v2]
Get Vault [v2]
Add Wallet
Export Mnemonic
Export Private Key
Update SubName
Remove Address
Detect Logged in Account
Last updated