{"uid":"cap_WDmY-kvv7fy61sVwoE-na","slug":"agent-data-tools-lightning-invoice-decoder-de25b6f0","name":"Agent Data Tools – Lightning Invoice Decoder","description":"Pay-per-call tools for AI agents: web page text extraction and summaries, screenshots, image generation, speech-to-text, image description, domain and email-auth intelligence, and live Base token and wallet lookups. No account or API key; pay per request in USDC on Base via x402.","url":"https://agent-data-tools.revmesh2074.workers.dev/ln-invoice?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":["invoice"],"properties":{"invoice":{"type":"string","description":"BOLT11 invoice string starting with ln (lnbc... for mainnet)"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":{"type":"json","example":{"expired":true,"network":"bitcoin","amountBtc":0.0025,"createdAt":"2017-06-01T10:57:38.000Z","expiresAt":"2017-06-01T10:58:38.000Z","amountSats":250000,"description":"1 cup coffee","paymentHash":"0001020304050607080900010203040506070809000102030405060708090102","expirySeconds":60}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_UaRW6YKzSX5vknCrZVVQ4","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Decodes a BOLT11 Lightning Network invoice string and returns parsed payment details including amount, expiry, description, and network.","exampleAgentPrompt":"Can you decode this Lightning invoice for me and tell me how much it's for and whether it's expired? lnbc2500u1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqdq5xysxxatsyp3k7enxv4jsxqzpuaztrnwngzn3kdzygauqzpkklvs234tgk0lpk0lsmxvzzwv9zsk9gqjm63","exampleUseCases":[{"title":"Verify invoice before paying","prompt":"Before I pay this Lightning invoice, can you decode it and tell me the amount in sats, what the payment description says, and whether it's already expired? Here's the invoice: lnbc1500n1p3xyzabcpp5..."},{"title":"Log incoming payment request details","prompt":"I received this BOLT11 Lightning invoice from a vendor — can you extract the payment hash, the amount in BTC, and the expiry time so I can log it in our records? Invoice: lnbc250m1pvjluezpp5..."},{"title":"Check if old invoice is still valid","prompt":"I have an old Lightning invoice sitting around — lnbc100u1p0ndvzkpp5... — can you tell me if it's expired yet and when it was originally created?"}],"resultDescription":"Returns a JSON object with the decoded invoice fields: expired (boolean), network (e.g. 'bitcoin'), amountBtc, amountSats, createdAt (ISO timestamp), expiresAt (ISO timestamp), expirySeconds, description (payment memo), and paymentHash.","failureModes":["Invalid or malformed BOLT11 invoice string returns an error","Missing 'invoice' query parameter results in a validation error","Testnet invoices (lntb...) may differ in network field behavior","Very old invoices may parse correctly but show expired:true"],"whenToPreferThis":"Use this endpoint when you need to programmatically decode a BOLT11 Lightning Network invoice string without running a full Lightning node. It is ideal for agents that need to verify invoice amounts, check expiry, or extract payment hashes before authorizing or logging a payment. Pay-per-call with no API key required makes it suitable for lightweight, occasional invoice inspection tasks.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-11T12:46:44.560Z","isFirstParty":false,"canonicalSlug":"agent-data-tools-lightning-invoice-decoder-de25b6f0"}