mcp-server-insumer

On-chain token verification across 31 blockchains. 16 tools for ECDSA-signed attestations, discount codes, merchant discovery, and autonomous onboarding.

mcp-server-insumer

MCP server for InsumerAPI -- on-chain verification across 31 blockchains. Returns ECDSA-signed booleans without exposing wallet balances. Up to 10 conditions per request, each with its own chainId. Optional Merkle storage proofs for trustless verification.

Enables AI agents (Claude Desktop, Cursor, Windsurf, and any MCP-compatible client) to autonomously verify on-chain conditions, discover merchants, generate signed discount codes, and onboard new merchants.

In production: DJD Agent Score (Coinbase x402 ecosystem) uses InsumerAPI for AI agent wallet trust scoring. Case study.

Also available as: LangChain (6 tools, PyPI) | OpenAI GPT (GPT Store) | insumer-verify (client-side verification, npm)

Quick Start

Claude Desktop

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "insumer": {
      "command": "npx",
      "args": ["-y", "mcp-server-insumer"],
      "env": {
        "INSUMER_API_KEY": "insr_live_..."
      }
    }
  }
}

Cursor / Windsurf

Add to your MCP settings:

{
  "insumer": {
    "command": "npx",
    "args": ["-y", "mcp-server-insumer"],
    "env": {
      "INSUMER_API_KEY": "insr_live_..."
    }
  }
}

Get an API Key

  1. Go to insumermodel.com/developers
  2. Sign up for a free key (instant, no credit card)
  3. Set it as INSUMER_API_KEY

Tools (17)

Key Discovery (free)

ToolDescription
insumer_jwksGet the JWKS containing InsumerAPI's ECDSA P-256 public signing key. Use the kid from attestation responses to match the correct key.

On-Chain Verification (cost credits)

ToolDescription
insumer_attestVerify on-chain conditions (token balances, NFT ownership). Returns ECDSA-signed boolean with kid (signing key ID), evaluatedCondition (exact logic), conditionHash (SHA-256 tamper-evidence), and blockNumber/blockTimestamp (RPC chain freshness). 1 credit. Optional proof: "merkle" for EIP-1186 Merkle storage proofs (2 credits).
insumer_verifyCreate signed discount code (INSR-XXXXX, 30-min expiry) for a wallet at a merchant. 1 credit.

Discovery (free)

ToolDescription
insumer_list_merchantsBrowse the merchant directory. Filter by token, verification status.
insumer_get_merchantGet full public merchant profile.
insumer_list_tokensList all registered tokens and NFTs. Filter by chain, symbol, type.
insumer_check_discountCalculate discount for a wallet at a merchant.

Credits

ToolDescription
insumer_creditsCheck credit balance and tier.
insumer_buy_creditsBuy verification credits with USDC (25 credits / 1 USDC).
insumer_confirm_paymentConfirm USDC payment for a discount code.

Merchant Onboarding (owner-only)

ToolDescription
insumer_create_merchantCreate new merchant. Receives 100 free credits.
insumer_merchant_statusGet full private merchant details.
insumer_configure_tokensSet token discount tiers.
insumer_configure_nftsSet NFT collection discounts.
insumer_configure_settingsSet discount mode, cap, USDC payments.
insumer_publish_directoryPublish merchant to public directory.
insumer_buy_merchant_creditsBuy merchant verification credits with USDC.

Supported Chains (31)

EVM: Ethereum, BNB Chain, Base, Avalanche, Polygon, Arbitrum, Optimism, Chiliz, Soneium, Plume, Sonic, Gnosis, Mantle, Scroll, Linea, zkSync Era, Blast, Taiko, Ronin, Celo, Moonbeam, Moonriver, Viction, opBNB, World Chain, Unichain, Ink, Sei, Berachain, ApeChain

Non-EVM: Solana

Example Agent Workflow

1. insumer_list_merchants → find merchants accepting UNI
2. insumer_check_discount → calculate discount for user's wallet
3. insumer_verify → generate discount code
4. insumer_confirm_payment → confirm USDC payment (if applicable)

Development

npm install
npm run build

# Test with MCP Inspector
npx @modelcontextprotocol/inspector node build/index.js

License

MIT

Related Servers