Snapback is an MCP server. Connect, call the free tools, and pay per call with x402 — no human, no account. Three URLs and you're running.
curl -s https://api.snapback.sh/mcp -X POST \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'
# → 19 tools. Free (no token): diagnose_infra_error, detect_loop,
# budget_guard, search_docs, what_others_did, session_start/step/end.{"jsonrpc":"2.0","id":1,"method":"tools/call",
"params":{"name":"diagnose_infra_error",
"arguments":{"error":"BlockhashNotFound"}}}
# → {family, fix, confidence, source:"library",
# action_class, auto_safe, gate:{auto_apply_ok}}Call tools via tools/call (never as a top-level method → -32601). Parse result.content[0].text.
Every verdict returns the fields you gate on. Auto-apply only when all three hold; otherwise escalate to a human. The response already computes it for you as gate.auto_apply_ok:
# the diagnose_infra_error response:
{ "family": "...", "fix": "...",
"confidence": 0.86, # >= the per-class threshold (config 0.80 / refetch 0.82 / retry 0.85)?
"source": "library", # == "library" (a verified fix, not an LLM guess) ?
"auto_safe": true, # action_class in {retry, refetch, config} — reversible ?
"action_class": "config",
"gate": { "auto_apply_ok": true } } # <- the ready-made verdict: true = safe to auto-apply + retry once
# your check (or just read gate.auto_apply_ok):
if verdict.gate.auto_apply_ok: # source==library AND reversible AND confidence>=per-class threshold
apply(verdict.fix); retry_once()
else:
escalate_to_human(verdict) # low confidence, an LLM inference, or a mutate/destructive fixWhat auto-heals vs escalates: the gate auto-applies the reversible, high-confidence subset — retry / refetch / config fixes at their per-class threshold (config ≥0.80, refetch ≥0.82, retry ≥0.85) — e.g. ImagePullBackOff, cert-chain, Redis OOM, Elasticsearch breaker, GraphQL throttle…). It escalates everything mutate/destructive (payments, transactions, state changes) even at high confidence, and anything low-confidence. That's deliberate: it's safe to run auto_apply=True unattended because the dangerous class is structurally gated out — you get autonomous healing on the safe errors and human review on the risky ones.
OpenClaw or any Python agent? Install the interceptor and it does this on every error automatically:
pip install snapback-selfheal
from snapback_interceptor import SnapbackInterceptor
heal = SnapbackInterceptor(auto_apply=True)
result = heal.run(my_tool_call, *args, **kwargs) # auto-diagnose + safe-retry on errorStdlib-only, zero dependencies, 100% client-side. Full walkthrough: how to use the skill.
Framework plugins that wrap this automatically: OpenClaw (interceptor + ClawHub skill) and Hermes (a plugin that hooks post_tool_call / api_request_error). Both reuse the same snapback-selfheal package. Any other MCP client (Copilot, Cursor, Claude Code, Windsurf) calls the tools directly — no adapter needed.
Versions are aligned: the MCP server, the PyPI plugin snapback-selfheal, and the ClawHub skill all track the same release number (currently v1.7) — one Snapback version across every channel.
Installing the ClawHub skill: run clawhub install snapback-selfheal from your OpenClaw workspace (or import it in the Gateway) so it lands in your agent's skills directory — clawhub install installs relative to the current folder, so running it from a scratch dir puts the skill where your agent can't see it.
First time? If you call a metered tool without a token, you get an HTTP 402 Payment Required — that's not an error, it's the payment handshake. The 402 body tells you exactly how to pay:
POST https://api.snapback.sh/mcp/x402 (no token)
→ HTTP 402 {
accepts: [ # one entry per chain you can pay on
{ network, payTo, asset (USDC), ...EVM: eip712 domain },
{ network: "solana", payTo, asset, feePayer } ],
facilitator, amount: ~$0.0032 USDC }
# 1. pick a chain from accepts you hold USDC on
# 2. sign the payment (EVM: EIP-3009 transferWithAuthorization; Solana: partial tx)
# 3. retry the SAME request with the signed payment in the
# PAYMENT-SIGNATURE header → 200 + your verdict + a receipt
# An empty/unreadable trace is NEVER charged, so you can probe safely.Prefer no wallet yet? Self-register for 2,000 free diagnoses: POST /v1/agents/register {"name":"my-agent","framework":"openclaw","accepted_terms":true} → a token. Light use → x402 per call (invisible). A team of many agents → flat $99/mo (100k diagnoses, a human sets it up in Stripe). Full x402 walkthrough: the x402 deep-dive.