bitcoin-mcp AGENTS.md

bitcoin-mcp AGENTS.md is an instructions file for Codex, OpenCode from Bortlesboat/bitcoin-mcp. It costs 647 tokens per session, scanned A, original, MIT.

A project guide for bitcoin-mcp, an MCP server that exposes tools for querying and analyzing a Bitcoin node. Bitcoin Core and Bitcoin Knots are programs that run and provide access to a Bitcoin network node.

In plain words
What is it for?
Use it when working on tools for blocks, transactions, addresses, fees, the mempool, or Bitcoin invoices, and when running or testing the server.
Why use it?
It shows agents where the server's tools and payment client live and makes clear which local or remote Bitcoin service is actually available.

Instructions file for CodexOpenCode

Install

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.

agentmods
npx agentmods add instructions/bortlesboat/bitcoin-mcp/agents-md
Clone the repo
git clone --depth 1 https://github.com/Bortlesboat/bitcoin-mcp

Made for: Codex, OpenCode.

Wrote 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.

agentmods badge for bitcoin-mcp AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/bortlesboat/bitcoin-mcp/agents-md.svg)](https://agentmods.dev/instructions/bortlesboat/bitcoin-mcp/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/bortlesboat/bitcoin-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/bortlesboat/bitcoin-mcp/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 647 This file is loaded in full into every session.
When invoked 647 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00647 $0.00647
Opus 5 $0.00324 $0.00324
Sonnet 5 $0.00129 $0.00129
Haiku 4.5 $0.00065 $0.00065

Measured 5d ago against content hash 5582b7eb8822, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

bitcoin-mcp AGENTS.md 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 5d 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.

AGENTS.md · 37 lines

How it starts

The opening of the file, as written. The whole thing — 37 lines — stays where its author put it; the contents beside it link to each section on GitHub.

bitcoin-mcp — MCP Server for Bitcoin

What this is

MCP server wrapping Bitcoin Core/Knots RPC. It auto-detects a local node and can use a compatible remote API when SATOSHI_API_URL is configured. The former public service at bitcoinsapi.com is paused and is not a working default. Published to PyPI and Smithery.

Key files

  • src/bitcoin_mcp/server.py — 50 standard tools plus one conditional remote-API tool, defined as @mcp.tool() decorators
  • src/bitcoin_mcp/l402_client.py — L402 payment channel client
  • tests/ — test suite, must pass before any release
  • .github/copilot-instructions.md — GitHub Copilot/Coding Agent guidance

Tool categories (all in server.py)

  • Mempool: analyze_mempool, get_mempool_info, get_mempool_entry, get_mempool_ancestors
  • Fees: get_fee_estimates, estimate_smart_fee, get_fee_recommendation, estimate_transaction_cost, compare_fee_estimates
  • Blocks: analyze_block, get_block_stats, compare_blocks, search_blocks, get_block_count
  • Transactions: analyze_transaction, decode_raw_transaction, get_indexed_transaction, search_blockchain, decode_bolt11_invoice
  • Address: get_address_balance, get_address_history, get_address_utxos, check_utxo, validate_address, get_indexer_status
  • Mining: get_mining_info, get_difficulty_adjustment, get_halving_countdown, get_mining_pool_rankings
  • Network: get_network_info, get_blockchain_info, get_chain_tips, get_peer_info, get_node_status
  • Supply: get_supply_info, get_utxo_set_info, get_chain_tx_stats
  • Security: analyze_psbt_security, explain_inscription_listing_security
  • Utility: generate_keypair, explain_script, describe_rpc_command, list_rpc_commands, query_remote_api
  • Market: get_btc_price, get_market_sentiment, get_situation_summary, get_next_block_eta

Development rules

  • Bump version in pyproject.toml for any release (semver)
  • Run pytest tests/ before any commit
  • Tools must work against both local Bitcoin Core/Knots and explicitly configured Satoshi API-compatible backends
  • No breaking changes to tool signatures without a major version bump
  • Tool docstrings appear in MCP client UIs — keep them accurate and useful
  • Discoverability matters: Glama/Smithery rank by stars + docs. Keep README and per-tool examples current.
  • Keep optional Satoshi API integration docs aligned with https://github.com/Bortlesboat/bitcoin-api/blob/main/docs/AGENT_INTEGRATION.md

Read the full file on GitHub · 37 lines

Changes

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.

  1. 5d ago First seen · 37 lines · 647 tokens per session scan A 5582b7eb8822

Subscribe to this mod's changes

bitcoin-mcp AGENTS.md is an instructions file published in the GitHub repository Bortlesboat/bitcoin-mcp (3 stars, last pushed 29d ago), licensed MIT. It adds 647 tokens to every session, about $0.0032 per session on Opus 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-31.