Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/solanabr/solana-ai-kitWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/solanabr/solana-ai-kit/debug-user-tx)<a href="https://agentmods.dev/commands/solanabr/solana-ai-kit/debug-user-tx"><img src="https://agentmods.dev/badge/commands/solanabr/solana-ai-kit/debug-user-tx/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/solanabr/solana-ai-kit/debug-user-tx"><img src="https://agentmods.dev/badge/commands/solanabr/solana-ai-kit/debug-user-tx.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00015 | $0.02424 |
| Opus 5.5 | $0.00006 | $0.00970 |
| Sonnet 5.5 | $0.00003 | $0.00485 |
| Haiku 4.5 | $0.00002 | $0.00242 |
Grade A, and why
debug-user-tx scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 102 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Debug the failing transaction described in $ARGUMENTS. The answer the developer needs is where in this repo it failed: the handler, constraint or require! with file:line, why it failed, and a fix. References: testing.md (LiteSVM, Surfpool), surfpool/cheatcodes.md, transactions-v1.md.
Inputs
| Input | Notes |
|---|---|
signature |
Preferred: fetch and diagnose in seconds. If the user only pasted an error message, ask for it first. |
instruction + wallet |
When the tx never landed: the serialized tx, or accounts plus data. |
cluster, rpc |
Default from Anchor.toml [provider] or .env. Public RPCs rate-limit, so prefer the project's provider (e.g. Helius). |
program |
Default: IDs from declare_id! / Anchor.toml. |
Modes
- A, signature given: steps 1-4 and 6. Replay (5) only when the on-chain evidence is inconclusive.
- B, never landed: build the tx from the instruction, replay it (5), then map the error from the replay logs (3-4) and check state (6).
- C, failing program is not in this repo (Jupiter, Token program...): skip source mapping, diagnose from logs and account state, and say the root cause is outside this codebase.
Steps
- Fetch with
getTransactionand{"encoding":"json","maxSupportedTransactionVersion":1,"commitment":"confirmed"}. The version must be the integer1: with0or omitted, v1 transactions fail with-32015. Cache the response as.claude/debug/tx-<first 8 chars of sig>.jsonand re-read it from there. Usemeta.err,meta.logMessages, pre/post balances and token balances,meta.innerInstructions,slot,message.accountKeys,message.instructions, andmessage.transactionConfig(v1 transactions carry the CU limit and priority fee there instead of ComputeBudget instructions). - Failing instruction: the index is
meta.err.InstructionError[0]; don't go by position (legacy and v0 txs usually start with ComputeBudget instructions). For v0 txs with lookup tables, index intoaccountKeys ++ meta.loadedAddresses.writable ++ meta.loadedAddresses.readonly, or CPI-heavy txs resolve the wrong program. A program ID that is not ours means mode C. - Handler: instruction
datais base58 injsonencoding; decode it first. Anchor: match the first 8 bytes againstinstructions[].discriminatorintarget/idl/<program>.json(this also covers custom discriminators). Pinocchio/native: usually the first byte, matched against theprocess_instructiondispatch. - Error to source, logs first:
AnchorError thrown in <file>:<line>is the exact location; quote it.AnchorError caused by account: <name>points at a constraint on that#[derive(Accounts)]field; theLeft:/Right:lines show the compared values.- The program's own
Program log:lines andProgram <id> failed: <reason>.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2mo ago Changed · -279 lines · -8 tokens per session c93fd591a2a4
- 2mo ago Changed 7ef1e19a8ef4
- 3mo ago First seen · 381 lines · 23 tokens per session scan A 7ce7d0431893
debug-user-tx is a command published in the GitHub repository solanabr/solana-ai-kit (104 stars, last pushed 2mo ago), licensed MIT. It adds 15 tokens to every session and 2,424 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
debug-user-tx compared with commands from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| debug-user-txsolanabr/solana-ai-kit | Command | 104 | 2mo ago | MIT | A | 15 | Claude Code |
| deep-code-analysisfusengine/agents | Command | 34 | 1mo ago | MIT | A | 28 | Claude Code |
| watchfusengine/agents | Command | 34 | 1mo ago | MIT | A | 23 | Claude Code |
| fixfusengine/agents | Command | 34 | 1mo ago | MIT | A | 21 | Claude Code |
| fixmantacron/manta | Command | 9 | 2mo ago | none | A | 0 | Claude Code |
| jira-fix-bugnmoinvaz/speedy-gonzales | Command | 4 | 1mo ago | none | A | 16 | Claude Code |
| healthhoangsonww/Claude-Code-Agent-Monitor | Command | 1.2k | today | MIT | A | 18 | Claude Code |