Skip to main content
Glama

Diamond Bitcoin Intelligence

Decode a Bitcoin transaction

bitcoin_decode_transaction
Read-onlyIdempotent

Decode a raw Bitcoin transaction (hex): txid, wtxid, size, vsize, weight, inputs, outputs with addresses and values, SegWit and RBF flags. Nothing is broadcast. Paid per call. Price: 3 sats or US$0.003 (USDC) per call.

Input Schema

NameRequiredDescriptionDefault
hexYesRaw transaction as hex
l402NoOptional. After paying the Lightning invoice: '<token>:<preimage>'.
pay_withNoOptional. 'lightning' returns a BOLT11 invoice and a token instead of the x402 payment request.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover readOnly/idempotent/closed-world, so the bar is lower, and the description adds real value beyond them: the explicit 'Nothing is broadcast' confirmation, the decoded-field inventory, and the crucially non-obvious payment model ('Paid per call. Price: 3 sats or US$0.003 (USDC)'). It still does not mention failure behavior on malformed hex or response shape beyond the field list.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three compact, front-loaded sentences: what it does and returns first, the safety/orientation note second, pricing last. No filler or repetition of the title.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, listing the decoded fields is exactly the right compensation, and the payment requirement (rare and critical for callers) is disclosed. Minor gaps remain on error handling for invalid hex and on how the payment retry flow works in practice, but the definition is sufficient to call correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3. The description only gestures at the main parameter with '(hex)' and adds nothing about l402 or pay_with semantics (e.g. that l402 is the token:preimage after paying the Lightning invoice) beyond what the schema already documents.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb ('Decode') plus the exact resource ('raw Bitcoin transaction (hex)') and enumerates the decoded fields returned (txid, wtxid, size, vsize, weight, inputs, outputs, SegWit/RBF). This clearly separates it from siblings such as bitcoin_transaction_status (status lookup by id), bitcoin_decode_psbt, and bitcoin_decode_script, which operate on different artifacts.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage context is implied rather than stated: the tool applies when you already hold raw transaction hex, and 'Nothing is broadcast' hints at a safe inspection step. There is no explicit when-to-use/when-not or named alternative (e.g. use bitcoin_transaction_status if you only have a txid), leaving routing to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources