Skip to content

TxWhy

by SUNDRAM07 · remote · no sign-in to list tools · v0.2.0 · published by GitHub user SUNDRAM07

Failed Solana transaction in, working transaction out. Exact cause, rebuilt tx, verifiable repair.

Changes · 2

3 tools: 2 change things and 1 only read.

Scanned Oct 21, 2026

No check matched anything in the tool definitions. No finding is not a safety guarantee. How the checks work.

claude mcp add --transport http txwhy https://txwhy.vercel.app/api/mcp

Tools

Open a tool for its reasons and full description. Descriptions are the publisher's own words, shown as they are.

3 tools

Changes things 2Claude Code: ask
  • explain_errorLooks up what a custom program error code means for a given program, using 1,800+ named errors from major Solana programs plus the runtime's own errors.No findings

    Why it is in this group

    • The name "explain_error" says "explain": a word for reading.
    • The input takes a statement or command to run (input.code), which can change anything it can reach.
    Description, as the server wrote it
    Looks up what a custom program error code means for a given program, using 1,800+ named errors from major Solana programs plus the runtime's own errors. Use it when you only have a code such as 6001 or 0x1771 from a simulation or an RPC response.
  • repair_transactionGive it a Solana transaction that failed, or one you are about to send.No findings

    Why it is in this group

    • Nothing in its name or description says what it does, so it is counted as a write.
    Description, as the server wrote it
    Give it a Solana transaction that failed, or one you are about to send. It finds the cause and returns a rebuilt UNSIGNED transaction that has been simulated against live mainnet state to prove it passes. Fixes expired blockhashes, compute-unit limits, priority fees, loaded-data limits, slippage on plain Jupiter swaps (fresh quote, same tolerance), and slippage on direct Pump.fun, PumpSwap, Raydium AMM v4, Meteora DBC and Meteora DAMM v2 swaps (only the limit moves, never more than 25% against the user). Handles legacy, v0 and version 1 (SIMD-0385) transactions and durable nonces. When the failure cannot be fixed by rebuilding (not enough funds, a private program's own error), it says so and explains why instead of returning something that would fail again. Pass exactly one of `transaction` or `signature`. Sign the returned transaction with your own key and send it within about 60 seconds.
Only reads 1Claude Code: allow
  • diagnose_transactionExplains why a transaction that landed on mainnet failed: the exact failing instruction in the call tree, the named error, its cause, and how to fix it.No findings

    Why it is in this group

    • The description's first verb is "explain": a word for reading.
    Description, as the server wrote it
    Explains why a transaction that landed on mainnet failed: the exact failing instruction in the call tree, the named error, its cause, and how to fix it. Read-only and fast. Use repair_transaction when you want a working transaction back.

This is not a safety rating, and no finding is not a safety guarantee. The groups and findings come from fixed checks of the tool definitions the server returned on the date shown, not from its code or what it does when called. How the checks work.

Install

Pinned to version 0.2.0. Values in angle brackets are yours to fill in.

claude mcp add --transport http txwhy https://txwhy.vercel.app/api/mcp

Run in a terminal.

Claude Code permissions

Allow the reads, ask before a change, deny the deletes. Paste into .claude/settings.json.

.claude/settings.json
{
  "permissions": {
    "allow": [
      "mcp__txwhy__diagnose_transaction"
    ],
    "ask": [
      "mcp__txwhy__repair_transaction",
      "mcp__txwhy__explain_error"
    ],
    "deny": []
  }
}

Tools that only read are allowed, tools that change things ask first, tools that delete or cancel are denied. It assumes the server is installed as txwhy. Review it before you use it.