Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@keyban/sdk-base
Advanced tools
Keyban Javascript SDK provides core functionalities for the MPC wallet solution, supporting web and Node.js apps with TypeScript, custom storage, and Ethereum blockchain integration.
The Keyban JavaScript SDK provides the core functionality for Keyban's MPC wallet solution, simplifying the development of web and Node.js applications. It offers essential configurations, utilities, and functions that serve as the foundation for creating decentralized wallet experiences.
tsup
for optimized builds in development and production.npm install @keyban/sdk-base
import { KeybanClient, KeybanChain, KeybanAccount } from '@keyban/sdk-base';
const client = new KeybanClient({
appId: "your-keyban-app-id", // Your Keyban application ID
accessTokenProvider: async () => "access-token", // Function to provide the access token
chain: KeybanChain.KeybanTestnet, // Select the desired blockchain network
});
const account: KeybanAccount = await client.initialize();
const transferEstimate = await account.estimateTransfer("0xRecipientAddress", BigInt('1000000000000000000')); // 1 ETH in wei
await account.transfer("0xRecipientAddress", BigInt('1000000000000000000'));
console.log(`Transferred 1 ETH to 0xRecipientAddress`);
const tokenBalances = await client.getTokenBalances(account.address);
console.log('ERC-20 Token Balances:', tokenBalances);
const erc20Estimate = await account.estimateERC20Transfer({
contractAddress: "0xTokenContractAddress", // ERC-20 contract address
to: "0xRecipientAddress", // Recipient address
value: BigInt('500000000000000000'), // Amount to transfer (0.5 tokens in wei)
});
await account.transferERC20({
contractAddress: "0xTokenContractAddress",
to: "0xRecipientAddress",
value: BigInt('500000000000000000'),
});
console.log(`Transferred 0.5 tokens to 0xRecipientAddress`);
const nfts = await client.getNfts(account.address);
console.log('Owned NFTs:', nfts);
const nftEstimate = await account.estimateNftTransfer({
contractAddress: "0xNftContractAddress",
to: "0xRecipientAddress",
tokenId: BigInt(1), // Token ID
standard: 'ERC721', // 'ERC721' or 'ERC1155'
});
await account.transferNft({
contractAddress: "0xNftContractAddress",
to: "0xRecipientAddress",
tokenId: BigInt(1),
standard: 'ERC721',
});
console.log(`Transferred NFT with Token ID 1 to 0xRecipientAddress`);
The Keyban SDK supports the following blockchains:
KeybanChain.KeybanTestnet
KeybanChain.PolygonAmoy
Support for additional blockchains and mainnets will be introduced in future releases.
Developers can define their own storage and signing strategies. The SDK offers flexibility with custom storage mechanisms, and future releases will bring more built-in storage options.
For more detailed API references and advanced features, visit the official Keyban API Reference Portal.
FAQs
Keyban Javascript SDK provides core functionalities for the MPC wallet solution, supporting web and Node.js apps with TypeScript, custom storage, and Ethereum blockchain integration.
We found that @keyban/sdk-base demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.