A Bitcoin wallet for your AI agent. SparkBTCBot plugs any agent into the Spark Layer 2 network — Lightning invoices, instant transfers, and agent-to-agent payments via L402, installed in two commands.
SparkBTCBot bridges AI agents and the Spark Bitcoin L2 network, enabling autonomous wallet management, instant payments, Lightning invoices, message signing, and L402 paywall authentication.
Zero-fee Spark transfers and Lightning invoices — settled in seconds, not blocks.
Encrypted seed access for prototyping, or a proxy with key isolation for production.
BIP39 wallets, balance monitoring, Spark & Lightning invoices, token operations, and L1 withdrawals.
Whether you want simple local access or increased security and controls with the proxy version, there's a SparkBTCBot for you.
Direct Spark SDK access from within your AI agent. Install as a plugin or clone locally — start transacting immediately.
claude plugin marketplace add https://github.com/echennells/sparkbtcbot-skill
claude plugin install sparkbtcbot
A hardened HTTP gateway on Vercel. Agents get bearer tokens — never your private keys.
claude plugin marketplace add https://github.com/echennells/sparkbtcbot-proxy
claude plugin install sparkbtcbot-proxy
A quick comparison to help you choose the right tool for your use case.
| Aspect | ⚡ Skill | ⚡ Proxy |
|---|---|---|
| Access Model | Direct SDK — agent holds encrypted seed | HTTP gateway — agent holds bearer token |
| Key Security | Agent has full wallet control | Private key never leaves server |
| Spending Limits | ||
| Access Control | Single user, full permissions | Role-based (admin / invoice / pay-only / read-only) |
| Deployment | Plugin install or local clone | Plugin install or Vercel + Upstash Redis |
| Setup Complexity | Set passphrase, run setup | Deploy to Vercel, provision Redis, create tokens |
| Revocation | Rotate mnemonic | |
| Multi-Agent |
Choose your path and follow the steps below.
Add SparkBTCBot to your agent via the plugin system or by cloning locally.
claude plugin marketplace add https://github.com/echennells/sparkbtcbot-skill
claude plugin install sparkbtcbot
git clone https://github.com/echennells/sparkbtcbot-skill.git \
~/.claude/skills/sparkbtcbot-skill
Set a passphrase and run the setup script to generate an encrypted wallet seed.
cd ~/.claude/skills/sparkbtcbot-skill
npm install
cp .env.example .env
# Set SPARK_PASSPHRASE (12+ chars) in .env
npm run setup
Back up the generated mnemonic offline, delete the backup file, and start transacting.
# Back up the mnemonic printed by setup, then:
rm ~/.spark/MNEMONIC_BACKUP_*.txt
# Now ask your agent: "Check my Spark wallet balance"
Install the proxy plugin for agent usage, or clone and deploy your own instance.
claude plugin marketplace add https://github.com/echennells/sparkbtcbot-proxy
claude plugin install sparkbtcbot-proxy
git clone https://github.com/echennells/sparkbtcbot-proxy.git
cd sparkbtcbot-proxy
npm install
npx vercel --prod
Set your mnemonic and Upstash Redis credentials as Vercel environment variables.
# In Vercel dashboard → Settings → Environment Variables:
SPARK_MNEMONIC="your twelve word mnemonic phrase here..."
API_AUTH_TOKEN="your-admin-fallback-token"
UPSTASH_REDIS_REST_URL="https://your-redis.upstash.io"
UPSTASH_REDIS_REST_TOKEN="your-token"
Generate role-based bearer tokens with spending limits for your AI agents.
curl -X POST https://your-proxy.vercel.app/api/tokens \
-H "Authorization: Bearer $ADMIN_TOKEN" \
-H "Content-Type: application/json" \
-d '{"role":"pay-only","label":"my-agent","maxTxSats":500,"dailyBudgetSats":5000}'