@sluzen/mcp
v0.1.0
Published
Sluzen MCP server: HTTP 402 schemes on XRPL (Payment | PayChan | allowlisted RLUSD). Local seed only.
Readme
@sluzen/mcp
MCP (stdio) surface for HTTP 402 schemes on XRPL (Payment | PayChan | allowlisted RLUSD).
Wraps live Sluzen APIs and @sluzen/sdk. Does not invent rails. Private keys / seeds stay on the MCP host only. Never paste a seed into sluzen.network.
Rail contract: .ops/TERMS_RAIL.md §2.3 (PayChan) · §2.4 (RLUSD). Specs: .ops/SPEC_PAYCHAN.md, .ops/SPEC_RLUSD.md.
Schemes
| Loop | Challenge | Sign (local) | Deliver to Sluzen | Latency (honest) |
|------|-----------|--------------|-------------------|------------------|
| A Payment XRP | scheme: exact, asset: XRP | sign_payment_xrp | proxy_pay or facilitator_settle | Ledger submitAndWait |
| B PayChan | scheme: paychan, asset: XRP | sign_paychan_claim | proxy_pay (JSON) or facilitator_authorize | Claim verify / authorize: sub-second possible |
| C Payment RLUSD | scheme: exact, asset: RLUSD + allowlisted iou | sign_payment_rlusd | same as A | Ledger submitAndWait |
Open PaymentChannelCreate and on-chain PaymentChannelClaim stay on the agent or issuer host. Sluzen verifies claims and debits prepaid take; it does not hold session keys or custody funds.
GET /facilitator/supported lists exact + paychan (XRP). RLUSD appears only on per-route challenges.
Custody ban
- Seeds:
CLIENT_WALLET_SEED(or tool override) on the local MCP host. - No MoR, refund, dispute, or Operator-held session keys.
- Prepaid / 0.8% take: already enforced by the proxy; this package does not reimplement fees.
Tools
| Tool | Role |
|------|------|
| health | GET /health |
| facilitator_supported | GET /facilitator/supported |
| challenge | Proxy unpaid path or POST /facilitator/challenge |
| sign_payment_xrp | Local exact XRP Payment blob |
| sign_payment_rlusd | Local allowlisted RLUSD IOU Payment blob (fail-closed) |
| sign_paychan_claim | Local off-chain claim + JSON PAYMENT-SIGNATURE |
| proxy_pay | Retry with PAYMENT-SIGNATURE |
| facilitator_verify | Read-only verify (exact or PayChan triad) |
| facilitator_settle | Exact only (use_authorize if PayChan JSON) |
| facilitator_authorize | PayChan debit + cursor |
Fail-closed when currency is not allowlisted, PayChan params are invalid, or local seed is missing.
Env
| Variable | Required | Notes |
|----------|----------|--------|
| CLIENT_WALLET_SEED | For sign tools | Local host only |
| XRPL_NODE | For exact Payment sign (autofill) | WebSocket rippled |
| SLUZEN_API_BASE | No | Default https://api.sluzen.network |
Claude Desktop (stdio)
{
"mcpServers": {
"sluzen": {
"command": "node",
"args": ["C:/Pons/sluzen-mcp/dist/bin/sluzen-mcp.js"],
"env": {
"CLIENT_WALLET_SEED": "(local seed)",
"XRPL_NODE": "wss://s.altnet.rippletest.net:51233",
"SLUZEN_API_BASE": "https://api.sluzen.network"
}
}
}
}Build first: npm --prefix sluzen-mcp install && npm --prefix sluzen-mcp run build (and npm --prefix sluzen-sdk run build).
AgentKit-style example
examples/paid-tool.ts picks scheme A/B/C from the challenge and pays via proxy or facilitator. No EVM / multi-rail co-branding.
Develop
npm --prefix sluzen-sdk run build
npm --prefix sluzen-mcp install
npm --prefix sluzen-mcp run build
npm --prefix sluzen-mcp testLicense
ISC
