# TxWhy

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

- name: io.github.SUNDRAM07/txwhy
- version: 0.2.0
- connection class: R0 (autonomous)
- trust: 80/100 flags: no-repository
- quality: 83/100 (good)
- owner: not claimed
- descriptor: https://api.protogrid.dev/v1/servers/io.github.SUNDRAM07%2Ftxwhy
- tools: https://api.protogrid.dev/v1/servers/io.github.SUNDRAM07%2Ftxwhy/tools

**An agent can connect right now, no human step.** Remote endpoint, no authentication, reachable on the last probe.

## Connection (mcpServers)

```json
{
  "mcpServers": {
    "txwhy": {
      "type": "http",
      "url": "https://txwhy.vercel.app/api/mcp"
    }
  }
}
```


## Trust

- hygiene: 80
- liveness: 100
- freshness: 100
- provenance: 45
- drivers: +website +reachable +uptime-100% +updated-11d-ago -no-repository
- Derived from observable signals (official registry feed and our own credential-free probes); no code audit performed.

## Quality 83/100 (good)

### protocol: 88 (weight 25)

- pass `protocol.modern`: supports 2026-07-28 (server/discover)
- pass `protocol.stateless`: answers without a session
- pass `protocol.transport`: streamable HTTP
- warn `protocol.list_ttl`: tools/list declares ttlMs 0, so clients re-fetch it on every use

### authorization: n/a (weight 15)

- n/a `auth.prm`, `auth.as_metadata`, `auth.cimd`: no remote uses OAuth
- n/a `auth.secret_in_url`: no templated URL

### tool hygiene: 71 (weight 30)

- pass `tools.descriptions`: every tool has a description
- pass `tools.description_length`: descriptions are concise
- pass `tools.schemas`: every tool has an object input schema
- fail `tools.annotations`: no tool declares readOnlyHint or destructiveHint, so clients cannot tell safe calls from risky ones
- fail `tools.directory_hints`: no tool declares all four of readOnlyHint, destructiveHint, idempotentHint and openWorldHint; missing: explain_error (readOnlyHint, destructiveHint, idempotentHint, openWorldHint); diagnose_transaction (readOnlyHint, destructiveHint, idempotentHint, openWorldHint); repair_transaction (readOnlyHint, destructiveHint, idempotentHint, openWorldHint)
- pass `tools.token_cost`: about 605 tokens to load every tool
- pass `tools.api_dump`: tools are not a one-to-one API dump

### stability: 100 (weight 15)

- pass `stability.changes`: no tool changes in 30 days
- pass `stability.rug_pull`: no tool changed its meaning under the same name

### dependencies: n/a (weight 15)

- n/a `deps.known_vulns`, `deps.mcp_sdk_version`, `deps.resolvable`: no npm or PyPI package

- tools: 3, about 605 tokens to load them all
- tool set hash: 95d54d9445991d89b1972a26f93bc861
- badge: [![protogrid quality](https://protogrid.dev/badge/io.github.SUNDRAM07/txwhy.svg)](https://protogrid.dev/servers/io.github.SUNDRAM07/txwhy)
- Checks run on what our credential-free, read-only probes observe; tools are never called and no code audit is performed.

### Tool changes

_No tool definition changes recorded._

## Remotes

- https://txwhy.vercel.app/api/mcp (streamable-http, auth none, reachable true, uptime30d 1)

## Packages

_none_

## Tools (3)

- `diagnose_transaction`: 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.
- `explain_error`: 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_transaction`: 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.
