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

@nexuspay/sdk

v1.2.2

Published

๐Ÿš€ Ultra-simple cross-chain wallet SDK - Initialize with just projectName + apiKey. Bulletproof gasless transactions across EVM/SVM chains with ANY social identifier support

Downloads

15

Readme

NexusSDK v1.1.1 โšก

Production-Ready Cross-Chain Wallet SDK for Third-Party Applications

NPM Version License Downloads

Create real blockchain wallets for any social identifier on both Ethereum and Solana with a single API call. Perfect for gaming platforms, enterprise applications, NFT marketplaces, and DeFi protocols.

๐Ÿš€ Quick Start

npm install @nexuspay/sdk
import { NexusSDK } from '@nexuspay/sdk';

const sdk = new NexusSDK({
  apiKey: 'your-api-key', // Get from https://backend-amber-zeta-94.vercel.app/
  environment: 'production',
  chains: ['ethereum', 'solana']
});

await sdk.initialize();

// Create real blockchain wallets instantly
const wallet = await sdk.createWallet({
  socialId: '[email protected]',
  socialType: 'email',
  chains: ['ethereum', 'solana'],
  paymaster: true // Your app pays gas fees
});

console.log('โœ… Real wallets deployed!');
console.log('๐Ÿ”— Ethereum:', wallet.addresses.ethereum);
console.log('โšก Solana:', wallet.addresses.solana);

โœจ Key Features

๐Ÿ”ง Third-Party Ready

  • Request Caching: Automatic 5-minute caching for better performance
  • Batch Operations: Create multiple wallets efficiently
  • Health Monitoring: Built-in health checks and statistics
  • Webhook Support: Safe identifier generation for webhook systems
  • Configuration Validation: Ensure proper SDK setup

โšก Real Blockchain Deployment

  • EVM Chains: Smart contract wallets on Ethereum, Polygon, Arbitrum, Base, Optimism
  • SVM Chains: Native account creation on Solana
  • Instant Deployment: Wallets are immediately visible on block explorers
  • Unified Addresses: Same address across all EVM chains

๐Ÿ’ฐ Flexible Gas Payment

  • Paymaster ON: Your app pays all gas fees (perfect for gaming/enterprise)
  • Paymaster OFF: Users pay their own gas fees (great for DeFi/marketplaces)
  • Real-time Control: Set gas payment per wallet creation

๐ŸŽฏ Unlimited Social Types

Create wallets for ANY identifier type:

// Gaming
{ socialId: 'player_123', socialType: 'gamePlayerId' }
// Enterprise  
{ socialId: 'emp_jane_doe', socialType: 'employeeId' }
// NFT Communities
{ socialId: 'ape_holder_rare', socialType: 'nftCollectorId' }
// Custom Business Logic
{ socialId: 'premium_tier_3', socialType: 'customerTierId' }

๐ŸŽฎ Perfect For Gaming

// Create wallets for 1000 players instantly
const playerWallets = await sdk.createWalletBatch([
  { socialId: 'player_001', socialType: 'gameId', chains: ['polygon'], paymaster: true },
  { socialId: 'player_002', socialType: 'gameId', chains: ['polygon'], paymaster: true },
  // ... more players
]);

// All gas fees sponsored by your game
console.log(`๐ŸŽฎ ${playerWallets.length} player wallets ready!`);

๐Ÿข Enterprise Ready

// Employee wallet system
const employeeWallet = await sdk.createWallet({
  socialId: 'emp_engineering_jane_doe_001',
  socialType: 'enterpriseEmployeeId',
  chains: ['ethereum', 'base'],
  paymaster: true, // Company sponsors all transactions
  metadata: {
    department: 'Engineering',
    clearanceLevel: 'L5',
    startDate: '2024-01-15'
  }
});

// Webhook integration
const webhookId = sdk.generateWebhookId(
  'emp_engineering_jane_doe_001', 
  'enterpriseEmployeeId'
);

๐ŸŽจ NFT Marketplace Integration

// Collector wallets with metadata
const collectorWallet = await sdk.createWallet({
  socialId: 'whale_collector_ultra_rare',
  socialType: 'nftCollectorTier',
  chains: ['ethereum'],
  paymaster: false, // Collectors pay their own gas
  metadata: {
    tier: 'Ultra Rare',
    collections: ['BoredApes', 'CryptoPunks'],
    totalValue: '500 ETH'
  }
});

๐Ÿ“Š Third-Party Integration Features

Health Monitoring

const health = await sdk.healthCheck();
console.log('API Status:', health.status);
console.log('SDK Version:', health.sdk.version);

Performance Analytics

const stats = sdk.getStats();
console.log('Cache Hit Rate:', stats.cacheSize);
console.log('Supported Chains:', stats.supportedChains);

Batch Operations

// Efficient bulk operations
const results = await sdk.createWalletBatch(requests);
const wallets = await sdk.getWalletBatch(walletIds);

Webhook Integration

// Safe webhook identifiers
const webhookId = sdk.generateWebhookId(socialId, socialType);
const { socialId, socialType } = sdk.parseWebhookId(webhookId);

๐ŸŒ Production Endpoint

Base URL: https://backend-amber-zeta-94.vercel.app

Get Your API Key

Visit https://backend-amber-zeta-94.vercel.app/ to generate your production API key.

Core Endpoints

  • POST /api/wallets/deploy - Create and deploy wallets
  • GET /api/wallets/{socialId} - Get wallet information
  • GET /health - API health check
  • POST /api/payments - Cross-chain payments

๐Ÿ”ง Configuration Options

const sdk = new NexusSDK({
  apiKey: 'your-api-key',           // Required: Get from production URL
  environment: 'production',        // 'production' | 'development'
  chains: ['ethereum', 'solana'],   // Supported chains to use
  endpoints: {
    api: 'https://backend-amber-zeta-94.vercel.app' // Production endpoint
  }
});

๐Ÿ“š Documentation

๐Ÿ› ๏ธ Framework Examples

React Hook

import { NexusSDK } from '@nexuspay/sdk';

function useWallet() {
  const [sdk] = useState(() => new NexusSDK({
    apiKey: process.env.REACT_APP_NEXUS_API_KEY,
    environment: 'production'
  }));

  useEffect(() => {
    sdk.initialize();
  }, []);

  return { sdk };
}

Next.js API Route

// pages/api/create-wallet.ts
const sdk = new NexusSDK({
  apiKey: process.env.NEXUS_API_KEY!,
  environment: 'production'
});

export default async function handler(req, res) {
  const wallet = await sdk.createWallet(req.body);
  res.json({ success: true, wallet });
}

Express.js Integration

import { NexusSDK } from '@nexuspay/sdk';

const sdk = new NexusSDK({
  apiKey: process.env.NEXUS_API_KEY,
  environment: 'production'
});

app.post('/wallets', async (req, res) => {
  const wallet = await sdk.createWallet(req.body);
  res.json(wallet);
});

๐Ÿ” Security & Best Practices

โœ… Secure API Key Storage

// โœ… Good: Server-side environment variable
const sdk = new NexusSDK({
  apiKey: process.env.NEXUS_API_KEY
});

// โŒ Bad: Client-side exposure
const sdk = new NexusSDK({
  apiKey: 'npay_your_key_here' // Never expose keys!
});

โœ… Error Handling

try {
  const wallet = await sdk.createWallet(options);
  return { success: true, wallet };
} catch (error) {
  if (error.message.includes('rate limit')) {
    return { error: 'Rate limited, try again later' };
  }
  return { error: 'Wallet creation failed' };
}

๐Ÿ“ˆ Performance Features

  • Request Caching: 5-minute cache for GET requests
  • Batch Operations: Create multiple wallets efficiently
  • Connection Pooling: Optimized for high-throughput applications
  • Rate Limiting: 1000 requests/minute in production

๐ŸŒŠ Supported Chains

EVM Chains (Unified Addresses)

  • Ethereum - Mainnet + Sepolia Testnet
  • Polygon - Mainnet + Mumbai Testnet
  • Arbitrum - Mainnet + Goerli Testnet
  • Base - Mainnet + Goerli Testnet
  • Optimism - Mainnet + Goerli Testnet
  • Avalanche - Mainnet + Fuji Testnet
  • BSC - Mainnet + Testnet

SVM Chains

  • Solana - Mainnet + Devnet + Testnet

๐Ÿ’ก Use Cases

๐ŸŽฎ Gaming Platforms

  • Player wallet creation with game currency
  • Guild treasury management
  • NFT reward distribution
  • Sponsored gas for better UX

๐Ÿข Enterprise Applications

  • Employee crypto payment systems
  • Company treasury management
  • Compliance-ready wallet tracking
  • Department-specific wallet organization

๐ŸŽจ NFT Marketplaces

  • Collector wallet management
  • Creator payout systems
  • Royalty distribution
  • Community membership wallets

๐Ÿ’ฐ DeFi Protocols

  • User wallet abstraction
  • Protocol treasury management
  • Yield farming automation
  • Cross-chain liquidity management

๐Ÿ“ž Support

๐Ÿ“ License

MIT License - see LICENSE for details.


Ready to deploy real blockchain wallets in your app? ๐Ÿš€

Get your API key at https://backend-amber-zeta-94.vercel.app/ and start building!