NWC MCP Server
NWC MCP サーバー
Nostr Wallet Connect ( NWCまたはNIP-47 ) を使用して、ビットコイン ライトニング ウォレットを LLM に接続します。
このMCPサーバーは公式MCP TypeScript SDKを使用しています
クイックスタート
クロードデスクトップに追加
claude_desktop_config.json に以下を追加します:
{
"mcpServers": {
"nwc": {
"command": "npx",
"args": ["-y", "@getalby/nwc-mcp-server"],
"env": {
"NWC_CONNECTION_STRING": "YOUR NWC CONNECTION STRING HERE"
}
}
}
}グースに追加
タイプ
goose configure拡張機能の追加 -> コマンドライン拡張機能
nwcと呼ぶ実行すべきコマンド:
npx -y @getalby/nwc-mcp-serverタイムアウト: 30
説明: なし
環境変数: はい
環境変数名:
NWC_CONNECTION_STRING環境変数の値:
nostr+walletconnect://...(ここにNWC接続シークレットを入力してください)
クラインに追加
以下のコードをコピーして、cline プロンプトに貼り付けてください。接続文字列の更新を促すメッセージが表示されます。
Add the following to my MCP servers list:
"nwc": {
"command": "npx",
"args": ["-y", "@getalby/nwc-mcp-server"],
"env": {
"NWC_CONNECTION_STRING": "nostr+walletconnect://..."
},
"disabled": false,
"autoApprove": []
}N8N(コミュニティノード)に追加
現在、この MCP サーバーはコマンド ライン (STDIO) 経由でのみ動作します。
n8n-nodes-mcpコミュニティノードをインストールし、ツールを有効にしてn8nを実行できます。例:
N8N_COMMUNITY_PACKAGES_ALLOW_TOOL_USAGE=true npx n8n空のワークフローを作成し、AIエージェントノードを追加します。LLMモデルを設定し、新しいツール「MCPクライアント」を追加します(横にキューブが表示され、コミュニティノードであることを示します)。
コマンド ライン (STDIO) を選択して資格情報を追加し、MCP クライアントを構成します。
コマンド: npx引数: -y @getalby/nwc-mcp-server環境NWC_CONNECTION_STRING=nostr+walletconnect://your_key_here (パスワード フィールドはプレーンテキストに切り替えることができないため、テキスト エディターで行全体を作成して貼り付けます)
完全な例については、N8N有料チャットワークフローをご覧ください。
Related MCP server: Lightning Tools MCP Server
ソースから
前提条件
Node.js 20以上
糸
NWCをサポートするライトニングウォレットからの接続文字列
インストール
yarn install建物
yarn buildNWC接続を追加する
.env.exampleを.envにコピーし、接続文字列を更新します。
ツールを検査する(LLMなしで使用/テストする)
yarn inspect
サポートされているツール
ツールディレクトリを参照
Available Tools
6 toolsget_balanceA
Get the balance of the connected lightning wallet
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool retrieves balance but does not describe any behavioral traits such as whether it requires authentication, has rate limits, returns real-time or cached data, or handles errors. This leaves significant gaps for a tool interacting with a financial system.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence that directly states the tool's purpose with no unnecessary words. It is front-loaded and appropriately sized, making it easy to parse without sacrificing clarity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity of a financial tool with no annotations and no output schema, the description is incomplete. It does not explain what the balance value represents (e.g., currency units, format), whether it includes pending transactions, or any error conditions. For a tool with zero structured coverage beyond input schema, more context is needed.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has 0 parameters with 100% schema description coverage, so the schema fully documents the lack of inputs. The description adds no parameter information, which is appropriate here, but it does not compensate for any gaps (none exist). Baseline is 4 for zero-parameter tools as no additional semantics are needed.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the specific action ('Get') and target resource ('balance of the connected lightning wallet'), distinguishing it from sibling tools like get_info (general info) or lookup_invoice (invoice-specific). It precisely defines what the tool does without being vague or tautological.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage context (when you need the wallet balance) but does not explicitly state when to use this tool versus alternatives like get_wallet_service_info or other financial tools. No exclusions or specific scenarios are mentioned, leaving usage guidance at an implied level.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_infoB
Get NWC capabilities of the connected lightning wallet, and general information about the wallet and underlying lightning node
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool retrieves information, implying a read-only operation, but lacks details on permissions, rate limits, error handling, or response format, which are critical for a tool interacting with a wallet.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence that front-loads the key action ('Get') and specifies the information types. It avoids unnecessary words, though it could be slightly more structured by separating the different information categories.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity of interacting with a lightning wallet and the absence of annotations and output schema, the description is incomplete. It doesn't explain what specific data is returned (e.g., balance, node ID, capabilities list), error conditions, or dependencies, leaving gaps for an AI agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 0 parameters with 100% coverage, so no parameter documentation is needed. The description appropriately focuses on the tool's purpose without redundant parameter details, aligning with the baseline expectation for zero-parameter tools.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: retrieving NWC capabilities, wallet information, and lightning node details. It specifies the resource (connected lightning wallet) and the type of information returned, though it doesn't explicitly differentiate from sibling tools like 'get_wallet_service_info' or 'get_balance'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance is provided on when to use this tool versus alternatives. While the description implies it's for general information retrieval, it doesn't specify use cases, prerequisites, or contrast with siblings such as 'get_wallet_service_info' for more specific data.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_wallet_service_infoB
Get NWC capabilities, supported encryption and notification types of the connected lightning wallet
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It implies a read-only operation ('Get') but doesn't specify whether it requires authentication, has rate limits, or details the return format. While it hints at querying a connected wallet, it lacks comprehensive behavioral context, resulting in an average score.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence that front-loads the key action and details without any wasted words. It directly communicates the tool's function in a structured manner, making it highly concise and well-organized.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (0 parameters, no output schema, no annotations), the description is minimally adequate. It states what the tool does but lacks details on behavioral traits, usage context, or output format, leaving gaps that could hinder an AI agent's understanding in more complex scenarios.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has 0 parameters with 100% schema description coverage, so the schema fully documents the absence of inputs. The description adds no parameter-specific information, which is appropriate here, but it doesn't compensate for any gaps since there are none. A baseline of 4 is applied as per the rules for zero parameters.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Get') and the specific information retrieved ('NWC capabilities, supported encryption and notification types of the connected lightning wallet'), making the purpose immediately understandable. However, it doesn't explicitly differentiate this from sibling tools like 'get_info' or 'get_balance', which prevents a perfect score.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives like 'get_info' or 'get_balance', nor does it mention any prerequisites or contextual cues for invocation. This lack of comparative or situational advice limits its utility for an AI agent.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
lookup_invoiceC
Look up lightning invoice details from a BOLT-11 invoice or payment hash
| Name | Required | Description | Default |
|---|---|---|---|
| payment_hash | No | The payment hash of the invoice to look up | |
| invoice | No | The BOLT 11 invoice to look up |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool is for 'look up' (implying a read operation), but doesn't clarify if it requires authentication, has rate limits, returns specific error conditions, or what 'details' include. For a tool with zero annotation coverage, this is a significant gap in transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence with zero waste. It front-loads the core purpose and uses precise terminology ('BOLT-11 invoice', 'payment hash'), making it easy to parse quickly. Every word earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the lack of annotations and output schema, the description is incomplete. It doesn't explain what 'details' are returned (e.g., status, amount, timestamps), potential errors, or behavioral aspects like idempotency. For a tool with 2 parameters and no structured output documentation, this leaves critical gaps for an agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description mentions the two input types ('BOLT-11 invoice or payment hash'), but the input schema already has 100% coverage with clear descriptions for 'payment_hash' and 'invoice'. The description adds minimal value beyond the schema, such as implying these are alternative inputs, but doesn't explain their relationship (e.g., if both can be used together). Baseline 3 is appropriate given high schema coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Look up lightning invoice details from a BOLT-11 invoice or payment hash.' It specifies the verb ('look up'), resource ('lightning invoice details'), and input types. However, it doesn't explicitly differentiate from sibling tools like 'get_info' or 'make_invoice', which prevents a perfect score.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'get_info' (which might provide general info) or 'pay_invoice' (which might involve payment actions), nor does it specify prerequisites or exclusions. This leaves the agent with minimal context for tool selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
make_invoiceC
Create a lightning invoice
| Name | Required | Description | Default |
|---|---|---|---|
| amount | Yes | amount in millisats | |
| expiry | No | expiry in seconds | |
| description | No | note, memo or description describing the invoice | |
| description_hash | No | hash of a note, memo or description that is too long to fit within the invoice | |
| metadata | No | Optional metadata to include with the payment |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It states the action ('Create') but lacks critical details: it doesn't mention whether this is a read-only or mutating operation (though 'Create' implies mutation), what permissions are required, potential side effects (e.g., generating a payment request), rate limits, or what the output looks like (especially problematic without an output schema).
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise ('Create a lightning invoice')—just three words—with zero wasted language. It's front-loaded with the core action and resource, making it efficient for quick understanding, though this brevity contributes to gaps in other dimensions.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity (a financial transaction tool with 5 parameters, no annotations, and no output schema), the description is incomplete. It doesn't address behavioral aspects like mutation effects, authentication needs, or output format, nor does it provide usage context. For a tool that creates invoices in a payment system, more detail is warranted to ensure safe and correct use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema description coverage is 100%, meaning all parameters are documented in the schema itself. The description adds no additional parameter semantics beyond what's in the schema (e.g., it doesn't explain relationships between parameters like 'description' and 'description_hash'). With high schema coverage, the baseline score of 3 is appropriate as the description doesn't compensate but also doesn't detract.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Create') and the resource ('a lightning invoice'), providing a specific verb+resource combination. However, it doesn't differentiate this tool from sibling tools like 'lookup_invoice' or 'pay_invoice', which would require mentioning that this generates new invoices rather than querying or paying existing ones.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing a lightning wallet), contrast with sibling tools (e.g., 'lookup_invoice' for querying, 'pay_invoice' for paying), or specify appropriate contexts (e.g., for receiving payments).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
pay_invoiceC
Pay a lightning invoice
| Name | Required | Description | Default |
|---|---|---|---|
| invoice | Yes | The lightning invoice to pay | |
| amount | No | Optional amount in millisats to pay a zero-amount invoice | |
| metadata | No | Optional metadata to include with the payment |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It states the action but lacks critical details like whether this is a destructive operation, what permissions are needed, potential side effects (e.g., fund transfer), or error handling, leaving significant gaps for a payment tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence with zero waste, front-loading the core action. It's appropriately sized for the tool's complexity, making it easy to parse quickly.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (a payment operation with financial implications), no annotations, and no output schema, the description is incomplete. It fails to address behavioral aspects, return values, or error cases, leaving the agent with insufficient context for safe and effective use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema already documents all parameters. The description adds no additional meaning beyond the schema, such as explaining the 'amount' parameter's role with zero-amount invoices or 'metadata' usage. Baseline 3 is appropriate when the schema does the heavy lifting.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('pay') and resource ('a lightning invoice'), making the tool's purpose immediately understandable. However, it doesn't differentiate from sibling tools like 'make_invoice' or 'lookup_invoice' beyond the verb, which keeps it from a perfect score.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites, such as having sufficient balance, or clarify scenarios like paying zero-amount invoices with the 'amount' parameter, leaving usage context ambiguous.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
Most tools have distinct purposes, but get_info and get_wallet_service_info overlap significantly in functionality, which could cause confusion for an agent. The other tools (balance, invoice operations) are clearly differentiated.
All tool names follow a consistent verb_noun pattern with snake_case (e.g., get_balance, make_invoice, pay_invoice). This predictability makes the set easy to navigate and understand.
With 6 tools, this server is well-scoped for managing a lightning wallet, covering key operations like balance, info, and invoice handling. The count is neither too sparse nor overwhelming for the domain.
The toolset covers essential lightning wallet operations, but there are minor gaps, such as no explicit tools for managing notifications or encryption settings, which are mentioned in get_wallet_service_info. Core workflows like invoice creation and payment are well-supported.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Personal finance, bank account, and shared memory connector for Claude, ChatGPT, Gemini Spark & more
Non-custodial crypto payments for AI assistants: balances, payments, and create payment links.
Connects AI assistants to CloudQuell multi-cloud and AI cost, savings, anomaly, and budget data.
Monetize and manage your Tip4Serv store directly from your LLM.
Related MCP Servers
- AlicenseNot gradedqualityFmaintenanceEnables AI models to interact with the Lightning Network by providing an MCP-compliant API to pay invoices.206MIT
- AlicenseBqualityFmaintenanceEnables interaction with lightning addresses and common lightning tools via your LLM, providing Lightning Network functionality through natural language.3211MIT
- AlicenseNot gradedqualityDmaintenanceEnables Bitcoin Lightning wallet integration with LLMs through Nostr Wallet Connect (NWC). Supports lightning payments, LNURL operations, and L402 authentication for AI-powered bitcoin transactions.30Apache 2.0
- AlicenseAqualityDmaintenanceEnables AI agents to perform Bitcoin and Lightning Network payments using a non-custodial, zero-trust architecture. It provides 13 tools for wallet management, invoice creation, and payment processing while keeping node credentials local to the user's machine.1317MIT
Appeared in Searches
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/getAlby/nwc-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server