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

clawpot-mcp

v1.0.0

Published

ClawPot MCP Plugin — AI agents enter a USDC lottery via x402 micropayments

Readme

clawpot-mcp

Live: clawpot.vercel.app | API: https://clawpot-production.up.railway.app

MCP (Model Context Protocol) plugin for ClawPot — AI Agent Lottery on Base L2.

Allows AI agents in Claude, Cursor, and other MCP-compatible clients to enter the ClawPot lottery, check pot status, and view history. Payments are handled automatically via PinionOS x402 micropayments.

Stack

  • MCP SDK (@modelcontextprotocol/sdk) — stdio-based tool server
  • PinionOS (pinion-os) — payX402Service for automatic x402 payment handling
  • Ethers 6 — Wallet management
  • TypeScript — ESM modules

Tools

| Tool | Price | Description | |------|-------|-------------| | clawpot_enter | $0.01 USDC | Enter the current lottery round | | clawpot_status | $0.001 USDC | Check pot size, entrant count, countdown | | clawpot_history | $0.001 USDC | View past round winners and prizes |

Each tool call triggers an x402 payment to the ClawPot skill server via PinionOS SDK. The agent's wallet signs an EIP-3009 USDC authorization — no gas needed.

Setup

Add to your Claude Desktop or Cursor MCP config:

{
  "mcpServers": {
    "clawpot": {
      "command": "npx",
      "args": ["clawpot-mcp"],
      "env": {
        "PINION_PRIVATE_KEY": "0x...",
        "CLAWPOT_SERVER_URL": "https://clawpot-production.up.railway.app"
      }
    }
  }
}

Environment Variables

| Variable | Required | Default | Description | |----------|----------|---------|-------------| | PINION_PRIVATE_KEY | Yes | — | Wallet private key for signing x402 payments | | CLAWPOT_SERVER_URL | No | http://localhost:4021 | ClawPot skill server URL |

Project Structure

clawpot-mcp/
├── src/
│   ├── index.ts    # Entry point — starts MCP server
│   ├── server.ts   # MCP server setup with StdioServerTransport
│   └── tools.ts    # Tool definitions and handlers (enter, status, history)
├── package.json
└── tsconfig.json

How It Works

Claude/Cursor → calls clawpot_enter tool
    ↓
clawpot-mcp → payX402Service(wallet, serverUrl + "/pot/enter", ...)
    ↓
x402 flow:  request → 402 → sign EIP-3009 → retry with X-PAYMENT header
    ↓
clawpot-server → verifies payment → calls enterPotFor() on-chain
    ↓
Returns round info → displayed to user

Alternative: PinionOS MCP

Instead of this dedicated plugin, agents can also use the generic PinionOS MCP server which provides 14 tools including pinion_pay_service that can call any x402 endpoint:

{
  "mcpServers": {
    "pinion-os": {
      "command": "npx",
      "args": ["pinion-os"],
      "env": { "PINION_PRIVATE_KEY": "0x..." }
    }
  }
}

With PinionOS MCP, agents discover ClawPot via openclaw.plugin.json and call skills using the generic pinion_pay_service tool.

Development

# Install
bun install

# Run (development)
bun dev

# Build
bun run build

Contracts (Base Sepolia)

| Contract | Address | |----------|---------| | ClawPot Proxy | 0xF5093b74c40ba43c1c013E1cDAc3844b08122b20 | | USDC | 0x036CbD53842c5426634e7929541eC2318f3dCF7e |

Agents need USDC on Base Sepolia for x402 payments. Get testnet USDC from faucet.circle.com. No ETH needed — payments are gasless.

Links