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

@iamnotdou/ccp

v0.2.2

Published

CCP — Containment Certificate Protocol CLI. Issue, verify, and enforce bounded-loss certificates for AI agents on Hedera.

Downloads

502

Readme

@iamnotdou/ccp

Containment Certificate Protocol — CLI and MCP server for AI agents on Hedera.

CCP lets AI agents prove they are economically safe to transact with. Instead of reputation (which fails for stochastic, ephemeral agents), CCP uses agent-independent smart contract constraints backed by locked exogenous reserves and auditor stake-at-risk.

The agent cannot modify its own cage. That is the point.

Install

npm install -g @iamnotdou/ccp

MCP Server (for AI Agents)

The MCP server exposes 18 tools over Model Context Protocol. Only AGENT_PRIVATE_KEY is required.

{
  "mcpServers": {
    "ccp": {
      "command": "npx",
      "args": ["@iamnotdou/ccp", "mcp"],
      "env": {
        "AGENT_PRIVATE_KEY": "0x..."
      }
    }
  }
}

Contract addresses, RPC, and HCS topic default to Hedera Testnet. No hosting required — the MCP server runs as a local child process.

Tools

Read (no key needed)

| Tool | Description | |------|-------------| | ccp_status | Full system overview: spending limits, reserve, balances, certificate | | ccp_addresses | Contract addresses and network config | | ccp_cert_verify | Verify agent meets containment requirements | | ccp_cert_get | Get certificate details by hash | | ccp_cert_lookup | Find active certificate for an agent address | | ccp_reserve_status | Reserve balance, lock status, C2/C3 adequacy | | ccp_spending_status | Spending config and period tracking | | ccp_auditor_status | Auditor attestation count, stake, challenges | | ccp_auditor_audit | Read-only containment audit | | ccp_challenge_get | Challenge details by ID | | ccp_challenge_list | List challenges for a certificate | | ccp_hcs_timeline | HCS event timeline from Hedera Consensus Service |

Write (key required)

| Tool | Key | Description | |------|-----|-------------| | ccp_spending_pay | AGENT | Pay below $5k (agent-only signature) | | ccp_spending_pay_cosign | AGENT + LEDGER | Pay $5k-$10k (Ledger co-sign) | | ccp_cert_publish | OPERATOR + AUDITOR + LEDGER | Publish new certificate (full flow) | | ccp_cert_revoke | OPERATOR | Revoke a certificate | | ccp_reserve_deposit | OPERATOR | Deposit USDC into reserve vault | | ccp_reserve_lock | OPERATOR | Lock reserve for N days |

Missing keys return { "error": "KEY_NOT_CONFIGURED" } — no crash.

Agent Workflow

1. ccp_status              → "where am I?"
2. ccp_cert_verify         → "am I trusted?"
3. ccp_spending_status     → "how much can I spend?"
4. ccp_spending_pay        → "pay" (< $5k)
5. ccp_hcs_timeline        → "what happened?"

Spending Rules

| Amount | Signature | Tool | |--------|-----------|------| | $0 - $5,000 | Agent only | ccp_spending_pay | | $5,001 - $10,000 | Agent + Ledger | ccp_spending_pay_cosign | | > $10,000 | BLOCKED | Hard limit, cannot be bypassed | | Period > $50,000 | BLOCKED | Resets after 24h |

These limits are enforced by smart contracts. Even with Ledger co-signature, the agent cannot exceed them.

CLI

ccp status                              # system overview
ccp cert:verify <agentAddress>          # verify containment
ccp cert:get <certHash>                 # certificate details
ccp cert:lookup <agentAddress>          # find active cert
ccp cert:publish                        # publish new cert
ccp cert:revoke <certHash>              # revoke cert
ccp reserve:status                      # reserve vault info
ccp reserve:deposit <amount>            # deposit USDC
ccp reserve:lock <days>                 # lock reserve
ccp spending:status                     # spending limits
ccp spending:pay <to> <amount>          # pay (agent-only)
ccp spending:pay:cosign <to> <amount>   # pay (Ledger co-sign)
ccp auditor:status                      # auditor record
ccp auditor:audit                       # containment audit
ccp challenge:get <id>                  # challenge details
ccp challenge:list <certHash>           # challenges for cert
ccp hcs:timeline                        # event timeline
ccp addresses                           # contract addresses
ccp actors                              # actor addresses
ccp help                                # help

Contracts (Hedera Testnet)

| Contract | Address | |----------|---------| | CCPRegistry | 0x776CAbA2d5E63F96358f1624976D6Aaa6b780ed1 | | SpendingLimit | 0x281Feb02bb3AA41d3A75E24a06A1f142eEEA5C85 | | ReserveVault | 0xb2fFaf44Ae415b0e1dFc99c8E07dfDE2a5369Aa6 | | AuditorStaking | 0xe786eB0F88b8A30e0ABf4C634fc414084b2134eC | | FeeEscrow | 0xe619F278352B4eED4465a176Df0B2A2F2CAf3557 | | ChallengeManager | 0x6238a4f9ad158dA64a4478FE64Ba0416b176cFC7 | | HCS Topic | 0.0.8510266 |

Chain ID: 296 | RPC: https://testnet.hashio.io/api

How CCP Works

┌─────────────────────────────────────────────┐
│          CONTAINMENT CERTIFICATE            │
├─────────────────────────────────────────────┤
│                                             │
│  ┌──────────────┐ ┌──────────┐ ┌─────────┐ │
│  │ CONTAINMENT  │ │ RESERVE  │ │  AUDIT  │ │
│  │              │ │          │ │         │ │
│  │ SpendingLimit│ │ $150k    │ │ Auditor │ │
│  │ • $10k/tx   │ │ USDC     │ │ staked  │ │
│  │ • $50k/day  │ │ locked   │ │ $13.5k  │ │
│  │ • Ledger    │ │ 3x ratio │ │ at risk │ │
│  │   cosign    │ │          │ │         │ │
│  └──────────────┘ └──────────┘ └─────────┘ │
│                                             │
│  Agent-independent. The cage holds because  │
│  the agent cannot modify it.                │
│                                             │
└─────────────────────────────────────────────┘

Three layers of trust:

  1. Containment — Smart contract spending limits + Ledger co-signing. Agent-independent.
  2. Reserve — $150k USDC locked on-chain. Exogenous, verifiable, non-recoverable during cert validity.
  3. Auditor stake — $13.5k at risk. Slashed if attestation proven false (30% to challenger, 50% to verifiers, 20% burned).

Env Variables

Only AGENT_PRIVATE_KEY is required. Everything else has Hedera Testnet defaults.

| Variable | Default | Required | |----------|---------|----------| | AGENT_PRIVATE_KEY | — | Yes (for write ops) | | OPERATOR_PRIVATE_KEY | — | For cert/reserve management | | AUDITOR_PRIVATE_KEY | — | For attestation | | LEDGER_PRIVATE_KEY | — | For co-signed payments | | HEDERA_RPC_URL | https://testnet.hashio.io/api | No | | HEDERA_CHAIN_ID | 296 | No | | HCS_TOPIC_ID | 0.0.8510266 | No | | REGISTRY_ADDRESS | Testnet default | No | | RESERVE_VAULT_ADDRESS | Testnet default | No | | SPENDING_LIMIT_ADDRESS | Testnet default | No | | AUDITOR_STAKING_ADDRESS | Testnet default | No | | FEE_ESCROW_ADDRESS | Testnet default | No | | CHALLENGE_MANAGER_ADDRESS | Testnet default | No | | USDC_ADDRESS | Testnet default | No |

Links

License

MIT