loadWallet

Every crypto wallet has a public address and a private key; your private key is used to access and make changes from the wallet. This function is used for programmatically loading the wallet by reading the private key stored locally.

circle-info

For developing frontend applications that interact with the Finnie extension (login with Finnie), check out Koii-X.

circle-info

Each Arweave public address contains 43 characters. All the information pertaining to the Arweave address, including transactions, balance, and other tokens can be viewed on the Arweave block explorerarrow-up-right.

For example, you can view all the information about the Arweave public address 7b4ll1zwenRB8jzyESjFNcRls331buyNl231Pe0V9VI herearrow-up-right.

Parameters

Path to your local wallet file that contains the private key

Example Code

const knode = require("@_koi/sdk/node");
const ktools = new knode.Node();
const walletKeyLocation = "<Path to your local wallet file>";

async function testLoadWallet() {
    const jwk = await ktools.loadFile(walletKeyLocation);
    await ktools.loadWallet(jwk);  
    console.log("Loaded wallet with address", await ktools.getWalletAddress());
}
  
testLoadWallet();

Example Code Output

Returns

Promise <String> - Wallet Address

Last updated