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 🙏

© 2026 – Pkg Stats / Ryan Hefner

wal-sdk

v1.0.0

Published

Programmatic wallet for CDP (Coinbase Developer Platform) with Base USDC and x402. Use as CLI, SDK, or in AI agents (Cursor/Codex) and cloud (Vercel AI SDK).

Readme

wal-sdk

Programmatic wallet using @coinbase/cdp-core with TypeScript.

Use wal-sdk as a CLI, SDK (import and call from your code), AI agent skill (via SKILL.md in Cursor, Codex, CC, etc.), or in cloud/serverless environments (Vercel AI SDK and similar). When running in Node.js, localStorage is emulated via localstorage-polyfill so the CDP SDK can store tokens. In the browser, the native window.localStorage is used.

Setup

  1. Install dependencies:

    npm install
  2. Copy .env.example to .env and set your CDP Project ID:

    cp .env.example .env

    Edit .env and replace your-project-id with your actual Project ID from the CDP Portal.

Usage

CLI

Run the CLI with:

npx wal-sdk [command] [options]

Commands

| Command | Description | | ---------------------------- | ----------------------------------------------------------- | | auth login <email> | Sign in with email OTP | | auth verify <flowId> <otp> | Complete sign-in with verification code | | auth logout | Sign out | | status | Show authentication status | | address | Show EVM address | | balance | Show wallet balances | | send <amount> <to> | Send USDC to address or ENS | | faucet | Show Base Sepolia faucet URL | | x402 bazaar search <query> | Search x402 bazaar by keyword | | x402 bazaar list | List bazaar resources | | x402 pay <url> | Make a paid x402 request with automatic USDC payment | | x402 details <url> | Inspect payment requirements for an endpoint | | x402 bazaar details <url> | Same as x402 details (alias) |

Options by Command

auth login <email>

| Argument | Description | | -------- | ----------- | | email | Your email address for OTP sign-in |

auth verify <flowId> <otp>

| Argument | Description | | -------- | ----------- | | flowId | Flow ID from the login step | | otp | 6-digit verification code from email |

balance

| Option | Description | | ------ | ----------- | | -c, --chain <chain> | Chain to use (default: base). Choices: base, base-sepolia | | --base-sepolia | Use Base Sepolia testnet | | --base | Use Base mainnet |

send <amount> <to>

| Argument | Description | | -------- | ----------- | | amount | Amount as $1.00, 1.00, or atomic units (e.g. 1000000 = $1.00) | | to | Recipient address or ENS name (e.g. vitalik.eth) |

| Option | Description | | ------ | ----------- | | -c, --chain <chain> | Chain to use (default: base). Choices: base, base-sepolia | | --json | Output as JSON | | -V, --verbose | Print transaction details before sending |

x402 bazaar search <query>

| Argument | Description | | -------- | ----------- | | query | Search keyword |

| Option | Description | | ------ | ----------- | | -k, --top <n> | Number of results (default: 5) | | --network <network> | Filter by network. Choices: base, base-sepolia | | -c, --chain <chain> | Filter by chain (same as --network). Choices: base, base-sepolia | | --force-refresh | Re-fetch from CDP API | | --json | Output as JSON |

x402 bazaar list

| Option | Description | | ------ | ----------- | | --network <network> | Filter by network. Choices: base, base-sepolia | | -c, --chain <chain> | Filter by chain (same as --network). Choices: base, base-sepolia | | --full | Show complete details including schemas | | --json | Output as JSON |

x402 bazaar details <url> / x402 details <url>

| Argument | Description | | -------- | ----------- | | url | x402 endpoint URL to inspect |

| Option | Description | | ------ | ----------- | | --network <network> | Filter payment options by network. Choices: base, base-sepolia | | -c, --chain <chain> | Filter by chain (same as --network). Choices: base, base-sepolia | | --json | Output as JSON |

x402 pay <url>

| Argument | Description | | -------- | ----------- | | url | Endpoint URL for paid request |

| Option | Description | | ------ | ----------- | | -X, --method <method> | HTTP method (default: GET) | | -d, --data <json> | Request body as JSON string | | -q, --query <params> | Query parameters as JSON string | | --headers <json> | Custom HTTP headers as JSON string | | -m, --max-amount <amount> | Max payment in USDC atomic units (1000000 = $1.00) | | --correlation-id <id> | Group related operations | | --network <network> | Filter payment options by network. Choices: base, base-sepolia | | -c, --chain <chain> | Filter by chain (same as --network). Choices: base, base-sepolia | | --verbose | Show debug output (address, payment headers) | | --json | Output as JSON |

Examples

# Authentication
npx wal-sdk auth login [email protected]
npx wal-sdk auth verify <flow-id> <6-digit-code>
npx wal-sdk auth logout

# Wallet
npx wal-sdk status
npx wal-sdk address
npx wal-sdk balance                    # Base mainnet (default)
npx wal-sdk balance --base-sepolia     # Base Sepolia testnet
npx wal-sdk balance --chain base-sepolia
npx wal-sdk send $1.00 0x...recipient...   # Send USDC (Base mainnet)
npx wal-sdk send 1000000 vitalik.eth       # Send 1 USDC to ENS
npx wal-sdk send $0.01 0x... -c base-sepolia  # Send on Base Sepolia
npx wal-sdk faucet

# x402 Bazaar (discovery)
# Results are cached at ~/.config/wal-sdk/bazaar/ (auto-refresh after 12h). On 429, cached data is used.
npx wal-sdk x402 bazaar search "weather"
npx wal-sdk x402 bazaar search "weather" --network base
npx wal-sdk x402 bazaar search "sentiment" -k 10 --chain base-sepolia
npx wal-sdk x402 bazaar list --network base
npx wal-sdk x402 bazaar list --chain base-sepolia
npx wal-sdk x402 bazaar list --full
npx wal-sdk x402 details https://example.com/api/weather
npx wal-sdk x402 bazaar details https://example.com/api/weather  # alias

# x402 Pay (requires auth, uses CDP fetchWithX402)
npx wal-sdk x402 pay https://example.com/api/weather
npx wal-sdk x402 pay https://example.com/api/sentiment -X POST -d '{"text": "I love this product"}'
npx wal-sdk x402 pay https://example.com/api/data --max-amount 100000  # max $0.10
npx wal-sdk x402 pay https://example.com/api/weather -c base-sepolia   # pay on Base Sepolia

Help

npx wal-sdk --help
npx wal-sdk balance --help

SDK / Programmatic

Import and call the run functions from your code:

import { runAddress, runBalance, runSend, runX402Pay } from "wal-sdk";

See API Documentation for the full reference.

AI Agents & Cloud

wal-sdk can be used in AI coding assistants (Cursor, Codex, CC) via SKILL.md, and in serverless/cloud environments (Vercel AI SDK, etc.). A separate project provides SKILL.md and deployment examples.