npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

zetachain-sdk

v1.0.0

Published

Unified SDK for ZetaChain cross-chain integrations

Downloads

6

Readme

ZetaChain SDK

A comprehensive TypeScript/JavaScript SDK for ZetaChain's cross-chain infrastructure.

Installation

npm install zetachain-sdk

Quick Start

import ZetaChainSDK from 'zetachain-sdk';

const sdk = new ZetaChainSDK({
  apiKey: 'your-api-key-here'
});

// Get balances across multiple networks
const balances = await sdk.getBalances('0x742d35Cc6C7486B4E1f5312b2E6a9F9E2A91D1b0', ['ethereum', 'polygon']);

// Create a new account
const account = await sdk.createAccount('MyWallet', 'evm');

// Send a cross-chain transaction
const transaction = await sdk.sendTransaction({
  from: '0xfrom...',
  to: '0xto...',
  amount: '1000000',
  network: 'ethereum'
});

Features

  • Account Management - Create, list, and manage blockchain accounts
  • Balance Queries - Check balances across multiple networks
  • Cross-Chain Transactions - Send transactions between different blockchains
  • Network Information - Get real-time network status and details
  • Address Validation - Validate addresses for different networks
  • Gas Estimation - Estimate transaction fees
  • Unit Conversion - Convert between different units
  • Bridge Operations - Bridge assets between chains

Supported Networks

  • Ethereum
  • Polygon
  • BSC (Binance Smart Chain)
  • Solana
  • Sui
  • Bitcoin
  • TON

API Reference

Account Management

// List all accounts
const accounts = await sdk.listAccounts();

// Create a new account
const account = await sdk.createAccount('wallet-name', 'evm');

// Delete an account
await sdk.deleteAccount('wallet-name');

Balance Operations

// Get balances for multiple networks
const balances = await sdk.getBalances(address, ['ethereum', 'polygon']);

// Get balance for a single network
const balance = await sdk.getBalance(address, 'ethereum');

Transaction Operations

// Send a transaction
const tx = await sdk.sendTransaction({
  from: '0xfrom...',
  to: '0xto...',
  amount: '1000000',
  network: 'ethereum'
});

// Estimate gas costs
const gasEstimate = await sdk.estimateGas('ethereum', 'transfer');

Network Operations

// Get network information
const networkInfo = await sdk.getNetworkInfo('ethereum');

// Get all supported networks
const networks = await sdk.getSupportedNetworks();

Cross-Chain Operations

// Get cross-chain quote
const quote = await sdk.getCrossChainQuote('ethereum', 'polygon', '1000000');

// Bridge assets between chains
const bridgeTx = await sdk.bridgeAssets('ethereum', 'polygon', '1000000', fromAddress, toAddress);

Utility Methods

// Validate an address
const isValid = await sdk.validateAddress('0x...', 'ethereum');

// Convert units
const converted = await sdk.convertUnits('1', 'ether', 'wei');

TypeScript Support

The SDK is written in TypeScript and includes full type definitions:

import ZetaChainSDK, { Account, Balance, Transaction, NetworkInfo } from 'zetachain-sdk';

Error Handling

try {
  const balances = await sdk.getBalances(address);
} catch (error) {
  console.error('ZetaChain API error:', error.message);
}

Configuration

const sdk = new ZetaChainSDK({
  apiKey: 'your-api-key',
  baseUrl: 'https://custom-endpoint.com' // Optional, defaults to official endpoint
});

License

MIT