Lightning Enable MCP logo

Lightning Enable MCP

by refined-element

Lightning wallet, L402 payments, invoices, API discovery, spending controls, and agent-commerce tools for MCP clients.

Install Lightning Enable MCP

Pick your client, then add it in one click or paste the config.

STDIOPython
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "refined-element-lightning-enable-mcp": {
      "command": "uvx",
      "args": [
        "lightning-enable-mcp"
      ],
      "env": {
        "STRIKE_API_KEY": "YOUR_VALUE_HERE",
        "NWC_CONNECTION_STRING": "YOUR_VALUE_HERE",
        "LND_REST_HOST": "YOUR_VALUE_HERE",
        "LND_MACAROON_HEX": "YOUR_VALUE_HERE",
        "LND_TLS_CERT_PATH": "YOUR_VALUE_HERE",
        "LND_SKIP_TLS_VERIFY": "YOUR_VALUE_HERE",
        "LND_FEE_LIMIT_SATS": "YOUR_VALUE_HERE",
        "OPENNODE_API_KEY": "YOUR_VALUE_HERE"
      }
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Values are written into the snippet above so you can paste it as is. They never leave your browser.

Claude Code command
claude mcp add --env STRIKE_API_KEY=YOUR_VALUE_HERE --env NWC_CONNECTION_STRING=YOUR_VALUE_HERE --env LND_REST_HOST=YOUR_VALUE_HERE --env LND_MACAROON_HEX=YOUR_VALUE_HERE --env LND_TLS_CERT_PATH=YOUR_VALUE_HERE --env LND_SKIP_TLS_VERIFY=YOUR_VALUE_HERE --env LND_FEE_LIMIT_SATS=YOUR_VALUE_HERE --env OPENNODE_API_KEY=YOUR_VALUE_HERE --transport stdio refined-element-lightning-enable-mcp -- uvx lightning-enable-mcp

Run in your terminal. Add --scope project to share it with your team through .mcp.json.

Automated check passed— started and listed 18 tools correctly ().

Overview

refined-element/lightning-enable-mcp connects MCP-enabled agents to Lightning wallets for invoice payments, invoice creation, balance checks, and L402-protected API access. It supports Strike, NWC, LND, and OpenNode wallet configurations, with L402 payments requiring a wallet that returns a payment preimage. Agents can also discover paid APIs, track spending, sell API access through L402, and use agent-to-agent commerce features. Reach for it when an agent needs to pay for services over Lightning or expose its own paid endpoints.

Use cases

  • Pay L402-protected APIs from an AI agent
  • Create and monitor Lightning invoices
  • Discover paid APIs through the L402 registry
  • Publish an API with Lightning-based access control
  • Track agent payment budgets and receipts

Key features

  • BOLT11 Lightning invoice payments
  • Automatic L402 challenge handling
  • Multi-wallet support for Strike, NWC, LND, and OpenNode
  • Invoice creation and payment status checks
  • L402 API discovery and service publishing
  • Budget limits and payment receipts

Tools18

What Lightning Enable MCP lets your agent do. Expand a tool for its parameters.

Verified live~3.3k tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked

Recent health check succeeded.

27/28 checks healthy over the last 117d

What it can do

From the 18 tools this server returned when we ran it; 18 declare their own safety hints.

Can delete or modify data · 8Handles credentials · 4Makes network requests · 4Read-only tools · 10
Network at startup3 connections
Files written at startup12

Observed 2026-11-06 in an isolated sandbox. A description of reach, not a security audit.

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 13d ago via OSV.dev · lightning-enable-mcp (PyPI)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars9Stargazers on the source repository.
Last commit21d agoMost recent push to the default branch.
Availability100%Our rolling endpoint + install checks that succeeded.
Install checkPassedOur sandbox started it and listed its tools.
Tools exposed18Callable tools this server registers over MCP.

How Lightning Enable MCP works

What refined-element/lightning-enable-mcp does

refined-element/lightning-enable-mcp gives MCP-compatible agents access to Bitcoin Lightning payment and commerce operations. It can pay BOLT11 invoices, create invoices for receiving funds, check invoice status, inspect wallet balances, and retrieve wallet information. L402 support lets an agent pay an invoice-and-macaroon challenge and use the resulting token to access a protected resource.

The server also connects agents to the L402 API registry. An agent can search for APIs by keyword or category, retrieve an API manifest, and use the docs tool to search or read Lightning Enable documentation locally without web access. Budget and receipt tools provide spending controls and payment history for the session or durable log.

How it works

Start with setup_wallet. With no connection string, it reports the selected wallet provider and credential source without exposing the credential. An NWC connection string can be supplied to connect a wallet; the server validates the connection, checks that it responds, and stores it in ~/.lightning-enable/config.json with user-only file permissions. The server should be restarted after saving a new wallet configuration.

Wallet selection prioritizes LND, then NWC, Strike, and OpenNode. Environment variables take precedence over values in the configuration file. The test_l402_payment tool can make a public one-satoshi payment to verify the complete L402 flow.

Setup and configuration

Install one of the available packages or run the container:

  • .NET: dotnet tool install -g LightningEnable.Mcp
  • Python: pip install lightning-enable-mcp
  • Python without installation: uvx lightning-enable-mcp
  • Docker: docker pull refinedelement/lightning-enable-mcp:latest

Wallet credentials can be supplied through environment variables. Strike uses STRIKE_API_KEY; NWC uses NWC_CONNECTION_STRING; and LND uses LND_REST_HOST with LND_MACAROON_HEX. LND can additionally use a certificate path, TLS verification setting, fee limit, and payment timeout. OpenNode uses OPENNODE_API_KEY for direct payments and invoicing.

Claude Desktop can run either the .NET executable or the Python uvx command through its MCP configuration. A packaged MCPB bundle is also available for Claude Desktop and provides wallet settings through its extension interface.

Tools and capabilities

  • Pay BOLT11 invoices and return payment preimages.
  • Pay L402 challenges or fetch URLs while automatically handling L402 payment.
  • Create invoices and check whether they have been paid.
  • Read balances, currency information for Strike, wallet details, budgets, and receipts.
  • Check BTC prices, exchange currencies, and send on-chain funds through supported wallets.
  • Discover L402 APIs and inspect their manifests.
  • Configure, publish, proxy, price, and verify L402-protected services.
  • Discover, request, settle, publish, unpublish, attest, and review agent services through the ASA tools.
  • Create a Lightning Enable account or renew its 30-day Agentic Commerce subscription.

Limitations and notes

A wallet is needed before the payment-related tools can operate. OpenNode supports invoicing and direct payments but does not return a preimage, so it cannot pay L402 challenges by itself. Producer and Agent Service Agreement features require an Agentic Commerce subscription. On-chain sending includes safeguards such as a confirmation nonce, and payment approval can require a human-readable confirmation code when a payment exceeds the configured auto-approval threshold.

Written by AllMCPs with AI assistance from the project’s README and listing data. How we build listings

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Lightning Enable MCP

refined-element/lightning-enable-mcp is an MCP server that connects AI agents to Lightning wallets and L402 services. Its main tools pay BOLT11 invoices, create invoices, check balances, handle paid API challenges, discover L402 APIs, track spending, and publish or manage agent services.

Install it with the .NET tool, Python package, `uvx`, or Docker. Use `dotnet tool install -g LightningEnable.Mcp`, `pip install lightning-enable-mcp`, `uvx lightning-enable-mcp`, or pull the `refinedelement/lightning-enable-mcp:latest` image.

Connect a wallet with `setup_wallet` or configure wallet environment variables. The tool accepts an NWC connection string and stores it locally after validation; supported environment-based options include Strike, NWC, LND, and OpenNode.

No, OpenNode cannot pay L402 challenges because it does not return a payment preimage. OpenNode remains available for direct Lightning payments and invoice creation, while L402 use requires a compatible wallet such as LND, NWC, or Strike.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewLightning Enable MCP AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/refined-element-lightning-enable-mcp?style=directory)](https://allmcps.com/mcp/refined-element-lightning-enable-mcp)
HTML Embed
<a href="https://allmcps.com/mcp/refined-element-lightning-enable-mcp"><img src="https://allmcps.com/api/badge/refined-element-lightning-enable-mcp?style=directory" alt="Lightning Enable MCP on AllMCPs" /></a>