{"endpoints":[{"auth_model":"payment-required","authentication":"L402","payment_requirement":"per-request","protocol_version":"2024-11-05","transport":"streamable-http","type":"mcp","url":"https://mcp.loopxxi.com/mcp"},{"auth_model":"payment-required","authentication":"L402","description":"Read-only REST probe endpoint for btc_price. Returns 402 with Lightning invoice if unpaid.","tool":"btc_price","transport":"https","type":"rest","url":"https://mcp.loopxxi.com/l402/btc_price"}],"examples":{"fiat_credit_flow":["# 1. Obtain a loop_ credit key from Loop Gateway","# 2. Use the credit key as Bearer token on every call","curl -X POST https://mcp.loopxxi.com/mcp -H 'Content-Type: application/json' -H 'Authorization: Bearer loop_\u003cCREDIT_KEY\u003e' -d '{\"jsonrpc\":\"2.0\",\"id\":1,\"method\":\"tools/call\",\"params\":{\"name\":\"btc_price\",\"arguments\":{}}}'"],"l402_flow":["# 1. Call without auth → receive 402 + invoice + token","curl -X POST https://mcp.loopxxi.com/mcp -H 'Content-Type: application/json' -d '{\"jsonrpc\":\"2.0\",\"id\":1,\"method\":\"tools/call\",\"params\":{\"name\":\"btc_price\",\"arguments\":{}}}'","# 2. Pay the BOLT11 invoice out-of-band, then retry with proof","curl -X POST https://mcp.loopxxi.com/mcp -H 'Content-Type: application/json' -H 'Authorization: L402 \u003cTOKEN\u003e:\u003cPREIMAGE\u003e' -d '{\"jsonrpc\":\"2.0\",\"id\":1,\"method\":\"tools/call\",\"params\":{\"name\":\"btc_price\",\"arguments\":{}}}'"],"preflight":"curl -s https://mcp.loopxxi.com/.well-known/agent-payments.json"},"payment_rails":[{"currency":"BTC","description":"Pay per call via BOLT11 invoice. Re-present Authorization: L402 \u003ctoken\u003e:\u003cpreimage\u003e after payment.","name":"L402 Lightning","pricing_model":"per-request","type":"lightning","unit":"sat"},{"currency":"USD","description":"Prepaid fiat credit keys issued by Loop Gateway. Use Authorization: Bearer loop_\u003ccredit_key\u003e.","name":"Fiat credits","pricing_model":"per-request-debit","type":"bearer_token","unit":"credit"}],"provider":{"email":"business@loopxxi.com","name":"Loop XXI LLC","url":"https://loopxxi.com"},"safety_and_terms":{"billing_model":"Per-request pricing. No subscription, no recurring charges.","contact":"business@loopxxi.com","max_price_sats":25,"payment_is_credential":true,"personal_data_required":false,"privacy_url":"https://loopxxi.com/privacy","refund_policy":"All sales are final once a tool result is delivered. Disputes to business@loopxxi.com.","terms_url":"https://loopxxi.com/terms"},"schema_version":"1.0.0","service":{"description":"Pay-per-call MCP server with 15 Bitcoin, data, text, and developer utilities over Lightning or prepaid credits.","id":"loop-mcp","name":"loop-mcp","version":"2.3.0"},"tools":[{"description":"Get the current Bitcoin price in USD and major fiat currencies. Source: mempool.space. Real-time.","input_schema":{"type":"object","properties":{},"required":[]},"name":"btc_price","price_sats":10},{"description":"Returns a composited send-or-wait recommendation for a Bitcoin transaction. Fetches live mempool and fee data, then outputs a machine-actionable verdict (SEND_NOW, WAIT, or URGENT_ONLY) with fee rates in sat/vB, mempool pressure level, and estimated savings if you wait. Ideal for agents that need a single decision call instead of parsing multiple raw mempool endpoints.","input_schema":{"type":"object","properties":{"urgency":{"type":"string","enum":["low","medium","high"],"description":"How time-sensitive is your transaction? low=economy, medium=default, high=next-block."}},"required":[]},"name":"btc_send_decision","price_sats":15},{"description":"Resolve a Lightning Address (user@domain.com) to a payable BOLT11 invoice for a given amount. Handles the full LNURL-pay protocol internally. Returns the invoice plus min/max sendable amounts for validation.","input_schema":{"type":"object","properties":{"address":{"type":"string","description":"Lightning Address in user@domain.com format."},"amount_sats":{"type":"integer","description":"Amount you want to send, in satoshis.","minimum":1}},"required":["address","amount_sats"]},"name":"lightning_address_resolve","price_sats":10},{"description":"Fetch a Bitcoin transaction by txid and return a structured, agent-ready summary: type (P2WPKH/P2TR/P2SH/etc.), input/output counts, fees, fee rate in sat/vB, confirmation status, RBF flag, SegWit/Taproot flags, and a one-line agent_summary string ready for LLM context injection. Saves 500-2000 tokens vs parsing raw TX JSON.","input_schema":{"type":"object","properties":{"txid":{"type":"string","description":"Bitcoin transaction ID (64 hex characters).","minLength":64,"maxLength":64}},"required":["txid"]},"name":"tx_decode_explain","price_sats":25},{"description":"Bitcoin transaction timing intelligence. Returns a congestion forecast for the next 1-4h, a recommended UTC send window when fees are projected at/below your target, a fee trajectory (rising/stable/falling) with a calibrated confidence score, next-block minimum fee, confirmation targets for 3/6/144 blocks, and an RBF-viability flag. A synthesis layer above raw fee data — the decision an autonomous payment agent needs before broadcasting. Source: mempool.space.","input_schema":{"type":"object","properties":{"target_sat_vb":{"type":"number","description":"Your fee ceiling in sat/vB. The recommended window targets at-or-below this rate. Omit to get the lowest-projected window."},"hours_ahead":{"type":"integer","minimum":1,"maximum":6,"description":"How far ahead to search for the optimal window (1-6h, default 4)."}},"required":[]},"name":"optimal_send_window","price_sats":25},{"description":"Validate JSON, identify its root type, and return normalized JSON plus a SHA-256 content hash.","input_schema":{"type":"object","properties":{"json":{"type":"string","description":"JSON text to validate, up to 100 KB."}},"required":["json"]},"name":"json_validate","price_sats":5},{"description":"Extract one value from JSON using a simple dot path with array indexes, for example users[0].email.","input_schema":{"type":"object","properties":{"json":{"type":"string","description":"JSON text, up to 100 KB."},"path":{"type":"string","description":"Dot path such as user.profile.name or users[0].email."}},"required":["json","path"]},"name":"json_extract","price_sats":5},{"description":"Convert CSV, TSV, semicolon, or pipe-delimited text into structured JSON with bounded row output.","input_schema":{"type":"object","properties":{"csv":{"type":"string","description":"Delimited text, up to 100 KB."},"delimiter":{"type":"string","enum":["comma","tab","semicolon","pipe"],"description":"Delimiter name. Default comma."},"header":{"type":"boolean","description":"Use the first row as object keys. Default true."},"max_rows":{"type":"integer","minimum":1,"maximum":1000,"description":"Maximum data rows to return. Default 100."}},"required":["csv"]},"name":"csv_to_json","price_sats":10},{"description":"Return deterministic text statistics, estimated tokens, reading time, and a SHA-256 content hash.","input_schema":{"type":"object","properties":{"text":{"type":"string","description":"Text to analyze, up to 100 KB."}},"required":["text"]},"name":"text_analyze","price_sats":5},{"description":"Generate a SHA-256 or SHA-512 digest in hexadecimal or Base64 form.","input_schema":{"type":"object","properties":{"text":{"type":"string","description":"Input text, up to 100 KB."},"algorithm":{"type":"string","enum":["sha256","sha512"],"description":"Hash algorithm. Default sha256."},"encoding":{"type":"string","enum":["hex","base64"],"description":"Output encoding. Default hex."}},"required":["text"]},"name":"hash_generate","price_sats":5},{"description":"Encode UTF-8 text to Base64 or decode Base64 safely, with standard and URL-safe alphabets.","input_schema":{"type":"object","properties":{"data":{"type":"string","description":"Text or Base64 data, up to 100 KB."},"action":{"type":"string","enum":["encode","decode"]},"url_safe":{"type":"boolean","description":"Use the URL-safe alphabet without padding."}},"required":["data","action"]},"name":"base64_convert","price_sats":5},{"description":"Convert Unix seconds, Unix milliseconds, RFC3339, or ISO dates into normalized UTC timestamp forms.","input_schema":{"type":"object","properties":{"value":{"type":"string","description":"Timestamp value."},"from":{"type":"string","enum":["auto","unix","unix_ms","rfc3339","date"],"description":"Input format. Default auto."}},"required":["value"]},"name":"timestamp_convert","price_sats":5},{"description":"Generate one to one hundred cryptographically random RFC 4122 UUID version 4 identifiers.","input_schema":{"type":"object","properties":{"count":{"type":"integer","minimum":1,"maximum":100,"description":"Number of UUIDs. Default 1."}},"required":[]},"name":"uuid_generate","price_sats":5},{"description":"Parse an HTTP or HTTPS URL into normalized scheme, host, port, path, query, and fragment fields without fetching it.","input_schema":{"type":"object","properties":{"url":{"type":"string","description":"Absolute HTTP or HTTPS URL, up to 4,096 characters."}},"required":["url"]},"name":"url_parse","price_sats":5},{"description":"Decode JWT header and payload claims locally without verifying the signature. The response always marks verification as false.","input_schema":{"type":"object","properties":{"token":{"type":"string","description":"JWT compact serialization, up to 20 KB."}},"required":["token"]},"name":"jwt_decode","price_sats":5}]}