LiveAuth MCP Server
LiveAuth MCP 服务器
面向 AI 智能体和 MCP 工具的认证、按次计费计量和签名收据:基于比特币原生、闪电网络支付,且兼容 L402。
此 MCP 服务器让任何 AI 智能体能够通过工作量证明(免费,无需账户)或闪电网络微支付(sats)对您的 API 进行认证,然后以按次定价、幂等收入事件和审计员可离线验证的 HMAC 签名收据,对后续工具调用进行计量和变现。
适用场景:
将 API 或 MCP 工具置于真实计算成本或真实 sats 之后(从设计上防垃圾信息,而非依赖验证码)。
按次向 AI 智能体收费,无需为其注册账户。
为每次付费工具调用签发防篡改的审计追踪(签名的
mcp-call-receipt-v1)。为预付费 MCP 会话提供基于闪电网络的 L402 捆绑访问。
5 秒快速体验——无需账户,无需 API 密钥:
npx @liveauth-labs/mcp-server无需配置,服务器即使用 LiveAuth 的匿名演示项目和真实 PoW 流程。仅当您需要特定项目的策略、定价或归属时,才添加 LIVEAUTH_API_KEY。
可用工具(Glama / MCP 自动发现)
工具 | 用途 |
| 开始会话。返回 PoW 挑战、闪电网络发票或 L402 捆绑提示。 |
| 提交已解决的 PoW 挑战、已支付的闪电网络发票或 L402 macaroon → 获得 JWT。 |
| 在调用后计量用量。提供 |
| 用刷新令牌换取新的 JWT——无需重新认证。 |
| 轮询会话/支付状态(闪电网络确认、过期)。 |
| 获取会话的 BOLT11 发票(兼容 lnget)。 |
| 查询剩余预算、已用调用次数和限流窗口。 |
完整的参数和响应模式见下文工具参考。
Related MCP server: Agent Receipts
5 分钟快速入门
选项 1 — 免凭证 PoW(无账户、无密钥、无钱包)
npx @liveauth-labs/mcp-server在 MCP 客户端中,调用 liveauth_mcp_start,然后仅使用返回的 quoteId 调用 liveauth_mcp_confirm。该包会在本地复用其现有的 PoW 求解器,LiveAuth API 在签发短期会话 JWT 之前会验证签名的挑战。
选项 2 — 生产模式
在 liveauth.app 获取 API 密钥。
添加到 Claude Desktop 的
claude_desktop_config.json:
{
"mcpServers": {
"liveauth": {
"command": "npx",
"args": ["-y", "@liveauth-labs/mcp-server"],
"env": {
"LIVEAUTH_API_BASE": "https://api.liveauth.app",
"LIVEAUTH_API_KEY": "la_pk_your_public_key"
}
}
}
}重启 Claude。完成。
选项 3 — 编程方式(CLI / SDK)
export LIVEAUTH_API_KEY=la_pk_xxx
npx @liveauth-labs/mcp-server该包同时也是 TypeScript SDK——见下文SDK 用法。CLI 可执行文件为 liveauth-mcp。
为什么选择 LiveAuth?
对于 API 提供商 / 工具开发者:
在协议层阻止机器人。PoW 和闪电网络 sats 不可重放、不可钓鱼,且不需要用户账户。
按次以 sats 收费。我们签署一份您可以向审计员、客户或会计展示的收据。
用一行代码(
createMcpGate)包装任何 MCP 工具,即可获得按工具收入、按工具最低/最高定价和幂等重试。
对于 AI 智能体 / 智能体构建者:
无许可访问付费 API——解决 PoW 或支付 sats,获得 JWT。无需注册、无需邮箱、无需 OAuth 流程。
使用 PoW、闪电网络发票或 L402 捆绑 macaroon 进行智能体访问。
项目在配置后可通过自定义闪电网络节点结算;否则支付使用 LiveAuthCore 配置的节点。
关键数据: 如果您的工具正被机器人抓取,每次调用收取 1 sat 就足以让抓取者无利可图。我们称之为攻击成本经济学,这正是我们存在的全部理由。
安装
npm install -g @liveauth-labs/mcp-server或直接使用 npx:
npx @liveauth-labs/mcp-serverGoose
LiveAuth for Goose 使用与其他客户端相同的基于标准的 stdio MCP 服务器——没有 Goose 包装器、守护进程或重复的认证运行时。
或打印官方深层链接和当前回退方案:
npx @liveauth-labs/mcp-server setup goose对于一次性 Goose CLI 会话:
goose session --with-extension "liveauth:npx -y @liveauth-labs/mcp-server"当深层链接不可用时,手动进行 Goose stdio 配置:
extensions:
liveauth:
type: stdio
name: LiveAuth
enabled: true
cmd: npx
args: ["-y", "@liveauth-labs/mcp-server"]
env_keys: []
envs: {}
timeout: 300不要破坏性地编辑现有 Goose 配置。优先使用深层链接或 goose configure;如果您稍后添加项目配置,请通过 Goose 的扩展密钥设置输入,而不是共享的明文 YAML。
Goose 快速测试
询问 Goose:
使用 LiveAuth 启动默认认证流程。确认返回的报价,然后显示我的 LiveAuth 用量。
初始流程使用匿名演示项目的 PoW 挑战,不需要钱包。项目公钥为可选:
变量 | 何时设置 |
| 项目特定策略、定价和归属。 |
| 自托管 LiveAuth API,而非 |
| 显式选择旧的本地模拟闪电网络演示。 |
当请求付费流程时,工具结果保留现有发票字段,并包含可移植的结构化数据:
{
"lightning": {
"invoice": "lnbc...",
"lightningUri": "lightning:lnbc...",
"amountSats": 21,
"expiresAt": "2030-03-17T17:46:40.000Z",
"status": "pending"
}
}支持 MCP Apps 的客户端可以渲染包含的二维码、打开钱包操作、过期时间以及实时的已支付/待支付/已过期状态。其他客户端将 JSON 和二维码图像内容作为普通 MCP 结果接收。
Goose 故障排查
如果链接无法打开,运行
npx @liveauth-labs/mcp-server setup goose并使用其单会话或手动回退方案。如果
npx不可用,请安装当前版本的 Node.js(Node 18 或更新版本)。如果提供的项目密钥被拒绝,请将其移除以验证匿名 PoW 流程;无效和已撤销的密钥有意不回退到演示模式。
如果闪电网络发票过期,请再次调用
liveauth_mcp_start获取新的报价。将刷新令牌和任何非公开凭证远离日志和明文配置。
LiveAuth 让智能体在运行时获取授权,而不是要求每个工具预先配置永久凭证。
SDK 用法
该包也可以作为 TypeScript/JavaScript SDK 导入。导入该包不会启动 stdio MCP 服务器;CLI 位于 liveauth-mcp 可执行文件。
客户端认证辅助
import { createMcpClient } from '@liveauth-labs/mcp-server';
const liveauth = createMcpClient({
publicKey: 'la_pk_xxx',
baseUrl: 'https://api.liveauth.app',
onInvoice(invoice) {
// Render invoice.bolt11 as a QR code for a paid Lightning test.
console.log(invoice.bolt11);
},
});
const session = await liveauth.start();
const token = await liveauth.confirm(session);
console.log(token.jwt);客户端存储已确认的 JWT,在返回刷新令牌时于过期前刷新,并通过 liveauth.token 暴露当前令牌。当您的应用关闭时,调用 liveauth.destroy() 以清除令牌状态和刷新定时器。
要要求真实的付费发票:
const session = await liveauth.start({ forceLightning: true });
console.log(session.invoice?.bolt11);
// Poll this after the invoice is paid.
const token = await liveauth.confirmLightning(session);服务器门控辅助
import { createMcpGate } from '@liveauth-labs/mcp-server';
const gate = createMcpGate({
publicKey: 'la_pk_xxx',
baseUrl: 'https://api.liveauth.app',
});
const result = await gate.invoke(
jwtFromYourTransport,
{ message: 'hello' },
async (input, context) => ({
content: [{ type: 'text', text: input.message }],
charge: context.liveAuth.charge,
}),
{}
);gate.invoke(...) 验证 JWT,收取配置的 sats 费用或后端项目默认费用,并将 context.liveAuth 传入您的处理器。旧的 gate.gateTool(...) 名称仍然受支持。
付费工具归属
如果您的 MCP 服务器有已注册的 LiveAuth 工具 ID,请在创建门控时传递 toolId。费用随后将发送到:
POST /api/mcp/tools/{toolId}/charge而不是旧的通用端点:
POST /api/mcp/charge您也可以传递已注册的工具 slug/名称作为 toolName。在该模式下,费用发送到通用端点,工具身份放在请求体中:
POST /api/mcp/charge工具收费保留相同的会话预算检查,但也会记录不可变的收入事件,包含总 sats、LiveAuth 平台费用、开发者净 sats、工具方法名、付费项目/会话/令牌、元数据和幂等键。当省略 costSats 时,LiveAuthCore 使用已注册工具的默认价格;没有 toolId 或 toolName 时,回退到项目的全局 MCP 价格。
已注册工具还可以有付费调用 webhook URL。每次成功的新付费调用时,LiveAuthCore 会排队一个 liveauth.mcp.tool.paid_call webhook,包含工具身份、总/平台/净 sats、收入事件 ID、元数据和签名收据。如果工具 webhook URL 为空,LiveAuthCore 回退到项目的 webhook URL;幂等重试不会排队重复项。
import { createMcpGate } from '@liveauth-labs/mcp-server';
const gate = createMcpGate({
publicKey: process.env.LIVEAUTH_PUBLIC_KEY!,
baseUrl: process.env.LIVEAUTH_API_URL ?? 'https://api.liveauth.app',
toolName: 'paid-research-tool',
});
const result = await gate.invoke(
jwtFromYourTransport,
{ url: 'https://example.com' },
async (input, context) => {
const page = await fetch(input.url).then(r => r.text());
return {
text: page,
revenueEventId: context.liveAuth.charge.revenueEventId,
receipt: context.liveAuth.charge.receipt,
netSats: context.liveAuth.charge.netSats,
};
},
{ requestId: 'req_123' },
{
toolMethodName: 'web_fetch',
idempotencyKey: 'req_123',
agentId: 'agent_abc',
metadata: {
urlHost: new URL('https://example.com').hostname,
},
}
);当设置了 toolId 或 toolName 时,GateToolOptions 支持:
选项 | 用途 |
| 可选,本次调用收取的 sats。省略时使用已注册工具定价或项目全局价格。 |
| 可选,使用通用端点时按调用覆盖工具 slug/名称。 |
| 工具内的方法,如 |
| 重试安全键。对同一工具重复使用会返回原始收入事件和签名收据,而不是重复收费。 |
| 可选,调用方/智能体标识符,用于报告。 |
| 用于审计上下文的小型 JSON 对象。请勿在此存储私有工具输出。 |
工具收费响应包含正常的预算计数器以及收入核算:
{
"status": "ok",
"callsUsed": 3,
"satsUsed": 15,
"grossSats": 5,
"platformFeeSats": 1,
"netSats": 4,
"feeBasisPoints": 500,
"revenueEventId": "event-guid",
"toolId": "tool-guid",
"toolName": "Paid Research Tool",
"toolSlug": "paid-research-tool",
"receipt": {
"version": "mcp-call-receipt-v1",
"payload": "base64url-canonical-json",
"signature": "base64url-hmac-sha256",
"signatureAlgorithm": "HMAC-SHA256",
"keyId": "liveauth-mcp-receipt-v1",
"body": {
"receiptId": "mcp_receipt_eventguid",
"revenueEventId": "event-guid",
"mcpToolId": "tool-guid",
"toolName": "Paid Research Tool",
"toolSlug": "paid-research-tool",
"toolMethodName": "web_fetch",
"grossSats": 5,
"platformFeeSats": 1,
"netSats": 4,
"idempotencyKey": "req_123"
}
}
}收据是 LiveAuthCore 为付费工具收费返回的签名按次审计工件。当您需要收费证明或后续对账时,请将其与工具结果一起存储。
如果未配置 toolId 或 toolName,SDK 继续使用 /api/mcp/charge 以保持向后兼容的用量计量。
配置
Claude Desktop
添加到您的 claude_desktop_config.json:
{
"mcpServers": {
"liveauth": {
"command": "npx",
"args": ["-y", "@liveauth-labs/mcp-server"],
"env": {
"LIVEAUTH_API_BASE": "https://api.liveauth.app",
"LIVEAUTH_API_KEY": "la_pk_your_public_key"
}
}
}
}免凭证模式: 如果您省略 LIVEAUTH_API_KEY,服务器在无项目头的情况下调用正常的 MCP 端点。LiveAuth 绑定其配置的匿名演示项目,返回签名的 PoW 挑战,并保留正常的验证、JWT、限流和计量边界。LIVEAUTH_DEMO=true 仍然是显式选择旧的本地模拟闪电网络预览。
其他环境变量:
变量 | 默认值 | 用途 |
| (未设置) | 您的 LiveAuth 项目公钥( |
|
| 自托管 LiveAuth 的覆盖地址。 |
|
| 显式使用旧的本地模拟闪电网络演示。 |
其他 MCP 客户端
服务器使用 stdio(JSON-RPC 2.0)。使用以下命令启动:
liveauth-mcp它也能与任何兼容 MCP 的客户端配合使用:Cursor、VS Code、ChatGPT、Windsurf、Continue、Cline。
工具参考
每个 MCP 工具的完整模式。每个工具都兼容 JSON-RPC 2.0,并在 src/index.test.ts 和 src/cli.test.ts 下经过测试。
liveauth_mcp_start
启动一个新的 LiveAuth MCP 会话。默认返回 PoW 挑战,如果 forceLightning=true 则返回 Lightning 发票。
参数:
forceLightning(布尔值,可选):如果为 true,则请求 Lightning 发票而不是 PoW 挑战forceL402(布尔值,可选):如果为 true,则启动一个应使用 L402 捆绑 macaroon 确认的会话
返回(PoW):
{
"quoteId": "uuid-of-session",
"powChallenge": {
"projectId": "guid",
"projectPublicKey": "la_pk_...",
"challengeHex": "a1b2c3...",
"targetHex": "0000ffff...",
"difficultyBits": 18,
"expiresAtUnix": 1234567890,
"signature": "sig..."
},
"invoice": null
}返回(Lightning):
{
"quoteId": "uuid-of-session",
"powChallenge": null,
"invoice": {
"bolt11": "lnbc...",
"amountSats": 50,
"expiresAtUnix": 1234567890,
"paymentHash": "abc123..."
},
"lightning": {
"invoice": "lnbc...",
"lightningUri": "lightning:lnbc...",
"amountSats": 50,
"expiresAt": "2009-02-13T23:31:30.000Z",
"expiresAtUnix": 1234567890,
"status": "pending"
}
}返回(L402 捆绑):
{
"quoteId": "uuid-of-session",
"powChallenge": null,
"invoice": null,
"authHint": "l402_bundle"
}liveauth_mcp_confirm
提交已解决的工作量证明挑战,让包解决其缓存的挑战,轮询 Lightning 支付,或出示 L402 macaroon 以接收 JWT 认证令牌。
参数:
quoteId(字符串):来自启动响应的 quoteIdchallengeHex(字符串,可选,仅 PoW):来自启动响应的挑战十六进制值nonce(数字,可选,仅 PoW):解决 PoW 挑战的 noncehashHex(字符串,可选,仅 PoW):生成的哈希(projectPublicKey:challengeHex:nonce的 sha256)expiresAtUnix(数字,可选,仅 PoW):来自挑战的过期时间戳difficultyBits(数字,可选,仅 PoW):来自挑战的难度位数signature(字符串,可选,仅 PoW):来自挑战的签名macaroon(字符串,仅 L402):从 L402 捆绑声明流程返回的捆绑 macaroon
当挑战来自此 MCP 服务器时,仅使用 quoteId 调用 confirm 会复用包现有的 PoW 求解器。显式解字段仍受支持以保持兼容性。
返回:
{
"jwt": "eyJhbGc...",
"expiresIn": 600,
"remainingBudgetSats": 10000,
"refreshToken": "abc123def456..."
}注意: 安全存储 refreshToken。它会在 MCP 工具数据中返回,但绝不会写入 stderr 或应用程序日志。使用 liveauth_mcp_refresh 获取新的 JWT,无需重新认证。
liveauth_mcp_charge
在发出经过认证的调用后计量 API 使用量。捆绑的 MCP 服务器调用通用的 /api/mcp/charge 端点。提供 toolName 可让 LiveAuth 解析已注册的工具,应用其配置的价格,并创建付费工具收入事件;省略 toolName 则保持向后兼容的通用计量。
参数:
callCostSats(数字,可选):API 调用的成本(以 sats 计)。省略则使用后端定价。toolName(字符串,可选):已注册的 MCP 工具 slug/名称,用于按工具定价和归因。
返回:
{
"status": "ok",
"callsUsed": 5,
"satsUsed": 15
}如果超出预算:
{
"status": "deny",
"callsUsed": 100,
"satsUsed": 1000,
"reason": "budget_exceeded"
}liveauth_mcp_status
检查 MCP 会话的状态。用于轮询 Lightning 支付确认。
参数:
quoteId(字符串):来自启动响应的 quoteId
返回:
{
"quoteId": "uuid-of-session",
"status": "pending",
"paymentStatus": "pending",
"expiresAt": "2026-02-17T12:00:00Z"
}当 paymentStatus 为 "paid" 时,会话已确认。再次调用 liveauth_mcp_confirm 以获取 JWT。
liveauth_mcp_lnurl
获取会话的 Lightning 发票(兼容 lnget)。使用此方法检索 BOLT11 发票,以便使用任何 Lightning 钱包支付。
参数:
quoteId(字符串):来自启动响应的 quoteId
返回:
{
"pr": "lnbc2100n1...",
"routes": []
}注意: 这与 lnget 和其他 Lightning 支付工具兼容。当 liveauth_mcp_confirm 返回 "payment pending" 时,使用此方法轮询发票。
liveauth_mcp_usage
查询当前使用量和剩余预算,不产生任何费用。在发出 API 调用之前使用此方法检查状态。
参数:(无需任何参数)
返回:
{
"status": "active",
"callsUsed": 5,
"satsUsed": 15,
"maxSatsPerDay": 10000,
"remainingBudgetSats": 9985,
"maxCallsPerMinute": 60,
"expiresAt": "2026-02-17T12:00:00Z",
"dayWindowStart": "2026-02-17T00:00:00Z"
}liveauth_mcp_refresh
刷新 JWT 令牌,无需重新认证。使用 confirm 返回的 refreshToken 在当前令牌过期时获取新的 JWT。
参数:
refreshToken(字符串):来自 confirm 响应的 refreshToken
返回:
{
"jwt": "eyJhbGc...",
"expiresIn": 600,
"remainingBudgetSats": 9985
}注意: 安全保存 refreshToken。你需要它来延长会话,而无需解决新的 PoW 或进行另一次 Lightning 支付。
使用示例
PoW 认证
调用
liveauth_mcp_start获取 PoW 挑战和 quoteId使用 quoteId 调用
liveauth_mcp_confirm;MCP 服务器使用现有的包求解器解决其缓存的挑战高级客户端仍可提交显式解(
hash = sha256(projectPublicKey:challengeHex:nonce),其中hash < targetHex)在 API 请求的
Authorization: Bearer <token>头中使用 JWT每次通用 API 调用后,使用调用成本调用
liveauth_mcp_charge,或省略以使用项目全局 MCP 价格对于货币化的 MCP 工具,使用
createMcpGate({ toolId })或createMcpGate({ toolName })包装处理器,使每次调用都创建收入事件和签名收据
Lightning 认证
使用
forceLightning: true调用liveauth_mcp_start获取 Lightning 发票使用
liveauth_mcp_lnurl(或轮询liveauth_mcp_status)获取 BOLT11 发票使用你的 Lightning 节点/钱包支付发票
使用 quoteId 轮询
liveauth_mcp_status,直到 paymentStatus 为 "paid"仅使用 quoteId 调用
liveauth_mcp_confirm以接收 JWT将 JWT 与通用
liveauth_mcp_charge计量或 SDK 付费工具归因一起使用
认证流程
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ AI Agent │────▶│ MCP Server │────▶│ LiveAuth API │
│ │ │ │ │ │
│ 1. Start │ │ /api/mcp/start │ │ Returns PoW │
│ 2. Solve PoW │ │ │ │ challenge │
│ 3. Confirm │ │ /api/mcp/confirm│ │ Returns JWT │
│ 4. API calls │ │ │ │ │
│ 5. Charge │ │ /api/mcp/charge │ │ Meter usage │
└─────────────────┘ └─────────────────┘ └─────────────────┘付费工具服务器使用相同的 JWT,但通过归因端点收费:
Agent calls MCP tool
→ Tool server calls POST /api/mcp/tools/{toolId}/charge
or POST /api/mcp/charge with toolName
→ LiveAuth validates JWT and budget
→ LiveAuth records gross / platform fee / net revenue and returns a signed receipt
→ Tool handler runs and returns the resultL402 捆绑流程
LiveAuthCore 支持基于 Lightning 的 L402 捆绑,用于预付费 MCP 访问。购买捆绑,支付后声明 macaroon,然后以 L402 模式启动 MCP 会话并使用该 macaroon 确认。
# 1. Create a bundle invoice.
curl -X POST https://api.liveauth.app/api/public/l402/bundle/invoice \
-H "Content-Type: application/json" \
-d '{"publicKey":"la_pk_xxx","tier":"starter","agentId":"agent_abc"}'
# 2. After the invoice is paid, claim a macaroon.
curl -X POST https://api.liveauth.app/api/public/l402/bundle/claim \
-H "Content-Type: application/json" \
-d '{"publicKey":"la_pk_xxx","paymentHash":"payment_hash_from_step_1"}'
# 3. Start and confirm an MCP session with the macaroon.
curl -X POST https://api.liveauth.app/api/mcp/start \
-H "X-LW-Public: la_pk_xxx" \
-H "Content-Type: application/json" \
-d '{"forceL402":true}'
curl -X POST https://api.liveauth.app/api/mcp/confirm \
-H "X-LW-Public: la_pk_xxx" \
-H "Content-Type: application/json" \
-d '{"quoteId":"quote_id_from_step_3","macaroon":"macaroon_from_step_2"}'开发
# Install dependencies
npm install
# Build
npm run build
# Run locally
node dist/cli.js资源
许可证
MIT
分类: authentication · payments · lightning · l402 · bitcoin · pay-per-call · metering · agent-tools · anti-abuse · mcp-server · typescript
Available Tools
7 toolsliveauth_mcp_chargeA
Meter API usage after making an authenticated call. Call this with the cost in sats for each API request made using the JWT.
| Name | Required | Description | Default |
|---|---|---|---|
| toolName | No | Optional registered MCP tool slug or name for per-tool pricing and revenue attribution. | |
| callCostSats | No | Optional cost of the API call in sats. Omit to use LiveAuth project or tool pricing. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description must disclose behavioral traits on its own. It mentions the action 'Meter API usage' but does not explain side effects like deducting sats, idempotency (e.g., calling twice), prerequisites beyond JWT authentication, or error behavior. As a monetary/charge operation, the lack of these details is a significant gap.
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—two short sentences that front-load the core action ('Meter API usage') and then provide the invocation details. There is no redundant or filler content; every sentence 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?
For a tool with two optional parameters, the description gives a decent overview of purpose and usage. However, with no annotations or output schema, it omits important context such as the expected response, idempotency, and failure modes. It is minimally sufficient but not fully complete for a financial metering operation.
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 already provides full documentation for both parameters (100% coverage). The description adds minor context (e.g., 'cost in sats for each API request') but does not meaningfully enrich the understanding of toolName or callCostSats beyond their schema descriptions. The high schema coverage justifies the baseline score of 3.
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 function: 'Meter API usage after making an authenticated call.' It identifies a specific verb (meter/charge) and resource (API usage), and the context (after an authenticated call) distinguishes it from sibling tools like liveauth_mcp_usage, which likely queries usage rather than recording it.
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 explicitly instructs when to call the tool: 'Call this with the cost in sats for each API request made using the JWT.' This clearly conveys per-request usage after authentication. However, it doesn't explicitly mention alternatives or conditions when not to use it, preventing a perfect score.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
liveauth_mcp_confirmA
Submit the solved proof-of-work challenge (or poll for Lightning payment) to receive a JWT. For Lightning, call with just quoteId to check/poll payment status.
| Name | Required | Description | Default |
|---|---|---|---|
| nonce | No | The nonce that solves the PoW challenge (PoW only) | |
| hashHex | No | The resulting hash hex (PoW only) | |
| quoteId | Yes | The quoteId from the start response | |
| macaroon | No | L402 bundle macaroon (L402 only) | |
| signature | No | Signature from the challenge (PoW only) | |
| challengeHex | No | The challenge hex from the start response (PoW only) | |
| expiresAtUnix | No | Expiration timestamp from the challenge (PoW only) | |
| difficultyBits | No | Difficulty bits from the challenge (PoW only) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the burden. It discloses the dual-mode behavior (PoW vs Lightning), that polling is possible, and the outcome (JWT). However, it does not disclose failure modes, side effects like challenge invalidation, or retry semantics, leaving important behavioral gaps.
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?
Two sentences, front-loaded with the main action, and the second provides a specific usage tip. No waste or redundancy.
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?
The tool has 8 parameters and two distinct flows, with no annotations and no output schema. The description covers the core purpose and outcome but lacks details on error conditions, success/failure responses, and safety of repeated calls. It is adequate but not comprehensive for the complexity.
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 coverage is 100%, so baseline is 3. The description adds mode-specific guidance: 'call with just quoteId' for Lightning, implying PoW uses the other fields. This clarifies how to select parameters by mode, going beyond the schema's individual descriptions.
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 states a specific action: submitting a solved proof-of-work challenge or polling for Lightning payment to receive a JWT. This clearly distinguishes it from siblings like start (which likely initiates) and status (which likely checks overall status).
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?
It provides explicit guidance: for Lightning, call with just quoteId to check/poll payment status, and PoW requires the challenge-solution fields. It does not explicitly name alternatives or when-not-to-use, but the sibling names and context make it inferable.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
liveauth_mcp_lnurlB
Get the Lightning invoice for a session (lnget-compatible). Use this to retrieve the BOLT11 invoice for payment.
| Name | Required | Description | Default |
|---|---|---|---|
| quoteId | Yes | The quoteId from the start response |
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 only states that the tool retrieves an invoice, but does not clarify side effects, return format, expiration, or whether it is a read-only operation. The mention of 'lnget-compatible' is vague and adds little 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 short and front-loaded, but the two sentences are somewhat redundant: 'Get the Lightning invoice' is repeated as 'retrieve the BOLT11 invoice.' It could be condensed into a single sentence without losing information, so it is not maximally concise.
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?
The tool has only one parameter with good schema coverage, but no output schema and no annotations. The description does not explain what the response looks like, potential errors, or any behavioral context like payment flow or invoice validity. Given the lack of structured metadata, this is insufficient for an agent to fully understand the tool's role.
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 already provides 100% coverage by describing quoteId as 'The quoteId from the start response.' The description adds no additional meaning about the parameter, so the baseline score of 3 is appropriate.
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 function: 'Get the Lightning invoice for a session' and also mentions 'retrieve the BOLT11 invoice for payment.' This provides a specific verb and resource, but it does not explicitly differentiate from sibling tools like start, status, or charge, so it does not reach a 5.
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 says 'Use this to retrieve the BOLT11 invoice for payment,' which implies the tool is for obtaining an invoice after starting a session. However, it does not explicitly state when to use it versus alternatives, nor does it mention any prerequisites or exclusions. This falls under implied usage rather than clear guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
liveauth_mcp_refreshA
Refresh the JWT token without re-authenticating. Use the refreshToken returned from confirm to get a new JWT.
| Name | Required | Description | Default |
|---|---|---|---|
| refreshToken | Yes | The refreshToken from the confirm response |
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. It discloses a key behavior (no re-authentication required) and the outcome (new JWT). However, it does not mention token rotation, single-use semantics, error handling, or response format, leaving gaps for an agent.
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?
Two concise sentences, no filler. The main purpose is front-loaded, and the parameter guidance is integrated naturally. 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?
For a simple one-parameter tool with no output schema, the description is nearly complete: it explains the purpose, the input source, and the expected result (new JWT). It lacks only minor details like potential errors or whether the refresh token is reusable, but these are not critical for basic invocation.
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 for refreshToken already provides full coverage (100%), and the tool description essentially restates the same source. Since the schema does the heavy lifting, the description adds minimal extra meaning, hence the baseline score of 3.
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 uses a specific verb+resource ('refresh the JWT token') and explicitly states what it achieves ('get a new JWT'). It also distinguishes itself from siblings by referencing the confirm response, making its role in the auth flow clear.
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 clearly states when to use this tool: after confirm, using the refreshToken from confirm. It implies it is the alternative to re-authenticating, providing a clear context. It does not explicitly list exclusions or alternatives, but the sibling set makes the intended use obvious.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
liveauth_mcp_startA
Start a new LiveAuth MCP session. Returns a PoW challenge (default), Lightning invoice, or L402 bundle auth hint.
| Name | Required | Description | Default |
|---|---|---|---|
| forceL402 | No | If true, request an L402 bundle auth session | |
| forceLightning | No | If true, request Lightning invoice instead of PoW challenge |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description must fully disclose behavioral traits. It does state the return types and the default PoW challenge, but it omits potential side effects, such as whether starting a new session invalidates existing ones or requires prior authentication. This leaves important behavioral context undisclosed.
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, front-loaded sentence that directly states the action and the possible outcomes. It contains no redundant or filler phrases, making it highly concise and well-structured.
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?
For a simple tool with two optional parameters and no output schema, the description covers the core return types and default behavior. While it could provide more detail about the response structure or next steps, the information given is sufficient to understand the tool's basic operation.
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 100% coverage with descriptive definitions for both boolean parameters. The description adds no additional parameter-level meaning, so the baseline score of 3 is appropriate.
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 uses a specific verb 'Start' and resource 'LiveAuth MCP session', making the purpose unambiguous. It distinguishes itself from sibling tools by clearly indicating this is the initialization action, and it enumerates the distinct return types (PoW challenge, Lightning invoice, L402 bundle).
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 this is the entry point for starting a session, but it does not explicitly state when to use it versus sibling tools like liveauth_mcp_status or liveauth_mcp_charge. No prerequisites or alternative usage scenarios are provided, so the guidance remains 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.
liveauth_mcp_statusA
Check the status of an MCP session. Use to poll for Lightning payment confirmation. Also returns the invoice via lnurl compatibility.
| Name | Required | Description | Default |
|---|---|---|---|
| quoteId | Yes | The quoteId from the start response |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It reveals that the tool returns an invoice via lnurl compatibility and implies a read-only polling nature, but it doesn't explicitly state read-only behavior, side effects, or what constitutes a 'status.' This is adequate but lacks rich safety or state-change disclosure.
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 two sentences, front-loaded with the primary purpose, and includes a specific usage example. Every sentence adds value with no fluff or redundancy.
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 (single parameter, no output schema), the description covers the essential context: what it does, when to use it, and a hint about the returned invoice. However, it doesn't describe the full status response structure or possible statuses, which might be useful for a polling tool, but overall it's sufficient for the low complexity.
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% with the only parameter 'quoteId' described as 'The quoteId from the start response.' The description adds no additional parameter-level meaning, but the schema already covers it fully, so the baseline of 3 is appropriate.
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 function: 'Check the status of an MCP session' with a specific use case ('poll for Lightning payment confirmation'). It also distinguishes itself from siblings by focusing on status and polling, and the added detail about lnurl compatibility further clarifies the tool's unique role.
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 explicitly says 'Use to poll for Lightning payment confirmation,' which provides clear guidance for when to invoke this tool. It doesn't mention alternatives or exclusions, but the polling context is sufficient for a status tool in a payment flow, making it clear this is the follow-up to start/confirm actions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
liveauth_mcp_usageA
Query current usage and remaining budget for the MCP session. Use this to check how many sats and calls have been used without making a charge.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must carry the full burden. It does disclose a key behavioral trait: 'without making a charge' indicates the call is non-destructive and free. However, it doesn't clarify whether the usage query itself counts as a call or affect the budget, nor does it explain any side effects or limit conditions. This is a minor gap for a read-only usage 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 two sentences long, front-loaded with the core purpose, and contains no filler. Every word contributes to understanding the tool's function and when to use it.
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?
For a simple tool with no parameters and no output schema, the description is complete. It clearly states what it queries (usage and remaining budget), the metrics (sats and calls), and the key safety aspect (no charge). No additional context is necessary.
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 zero parameters, so the baseline is 4. The description adds no parameter details, but none are needed. It correctly focuses on the tool's purpose and usage rather than param syntax.
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 uses a specific verb 'Query' and identifies a clear resource: 'current usage and remaining budget for the MCP session.' It also distinguishes itself from siblings like 'status' and 'charge' by focusing on budget/calls usage, making the purpose unambiguous.
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 explicitly states when to use the tool: 'Use this to check how many sats and calls have been used without making a charge.' This provides clear context and implies it's a non-charging alternative to 'liveauth_mcp_charge'. It doesn't explicitly name alternatives or exclusions, but the guidance is practical and sufficient.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
7 tool updates
v1.0.8- First observed
liveauth_mcp_charge - First observed
liveauth_mcp_confirm - First observed
liveauth_mcp_lnurl - First observed
liveauth_mcp_refresh - First observed
liveauth_mcp_start - First observed
liveauth_mcp_status - First observed
liveauth_mcp_usage
TDQS
Each tool maps to a distinct auth lifecycle step: start initiates, lnurl fetches invoice, confirm resolves auth, refresh renews token, charge/usage handle metering, and status reports state. Slight overlap exists between status and confirm when polling payment, but descriptions clarify their primary roles.
All tools share the consistent liveauth_mcp_ prefix and snake_case format. Most use verbs (start, confirm, refresh, charge), but status, usage, and lnurl are noun-based, creating minor deviations from a strict verb pattern.
With 7 tools, the set is well-scoped for the server's purpose. Each tool covers a specific function without redundancy, fitting comfortably in the ideal 3-15 tool range.
The toolset provides full lifecycle coverage: starting a session, retrieving invoices, confirming authentication, refreshing tokens, and tracking/metering usage. No significant operational gaps are apparent for the stated authentication and payment domain.
Maintenance
Related MCP Connectors
Pay-per-action access to APIs and MCP tools over Lightning L402 and Base USDC x402.
Pay-per-call APIs and MCP services for agents, no accounts or keys, with verifiable receipts.
External counterparty-risk checks and signed receipts for autonomous agents and machine payments.
Bitcoin-anchored, tamper-evident audit-permanence layer for AI agents, FRE 902(13)/(14)-shaped.
Related MCP Servers
- AlicenseAqualityBmaintenanceMCP server that enables AI agents to make autonomous Bitcoin Lightning Network payments using the L402 protocol. Agents can pay for API access, purchase resources, and complete transactions without human intervention — invoice comes in, sats go out, done.179MIT
- AlicenseAqualityCmaintenanceCryptographic accountability for AI agents. Ed25519-signed receipts for every MCP tool call. Constraints, chains, AI judgment, invoicing, and local dashboard included.24131MIT
- AlicenseAqualityAmaintenanceL402 + x402 client MCP. AI agents discover, pay for, and consume any payment-gated API autonomously. Supports Lightning (NWC), Cashu ecash, stablecoins, and human-in-the-loop payments.11284MIT
- AlicenseAqualityCmaintenanceMCP server that gates API calls to AI agents using proof-of-work (free) or Lightning payment (3 sats), providing challenge, verify, and status tools for per-call authentication without accounts.3761MIT
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/dulzuradev/liveauth-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server