---
slug: "maestro-maestro-mcp"
source_type: "readme"
source_url: "https://cdn.jsdelivr.net/gh/maestro-org/maestro-mcp@main/README.md"
repo: "https://github.com/maestro-org/maestro-mcp"
source_file: "README.md"
branch: "main"
---
# Maestro MCP Server

[![CI](https://github.com/maestro-org/maestro-mcp-server/actions/workflows/ci.yml/badge.svg)](https://github.com/maestro-org/maestro-mcp-server/actions/workflows/ci.yml)

A Model Context Protocol (MCP) server for interacting with Bitcoin via the Maestro API platform. Provides tools for exploring blocks, transactions, addresses, and more on the Bitcoin blockchain.

---

## Quick Links

- **Hosted Mainnet:** [`https://xbt-mainnet.gomaestro-api.org/v0/mcp`](https://xbt-mainnet.gomaestro-api.org/v0/mcp)
- **Hosted Testnet4:** [`https://xbt-testnet.gomaestro-api.org/v0/mcp`](https://xbt-testnet.gomaestro-api.org/v0/mcp)
- **API Key Required:** [Get your Maestro API key](https://docs.gomaestro.org/getting-started)
- **Client Examples:** [maestro-mcp-client-examples](https://github.com/maestro-org/maestro-mcp-client-examples)

---

## Getting Started

### Requirements

- [Bun](https://bun.sh) v1.0 or higher

### Installation & Setup

```bash
# Install dependencies
bun install

# Build the project
bun run build

# Copy and edit environment variables
cp .env.example .env
# Edit .env to add your Maestro API key and any other config
```

### Running the Server

```bash
bun run start:http
```

- The server will start on the port specified in your `.env` (default: 3000).
- Access the MCP endpoint at `http://localhost:<PORT>/mcp`.

---

## Features

- 🚀 **Streamable HTTP MCP server** ([spec](https://modelcontextprotocol.io/specification/2025-03-26/basic/transports#streamable-http))
- 🔑 **API Key authentication** (see `.env.example`)
- 📦 **Multiple APIs:**
  - Blockchain Indexer
  - Mempool Monitoring
  - Market Price
  - Wallet
  - Node RPC
- 🌐 **Supported Networks:**
  - Mainnet: `API_BASE_URL=https://xbt-mainnet.gomaestro-api.org/v0`
  - Testnet4: `API_BASE_URL=https://xbt-testnet.gomaestro-api.org/v0`

---

## API Reference & Examples

- [Maestro API Documentation](https://docs.gomaestro.org)
- [Client Usage Examples](https://github.com/maestro-org/maestro-mcp-client-examples)
- [MCP: Interact with Bitcoin via an LLM](https://docs.gomaestro.org/bitcoin/tutorials-and-guides/mcp-interact-with-bitcoin-via-an-llm)

---

## Server Generation

This server is generated using [`openapi-mcp-generator`](https://github.com/harsha-iiiv/openapi-mcp-generator):

```bash
npx openapi-mcp-generator --input openapi-merged.json --output ./ --force --transport streamable-http --port 3000
```

---

## Contributing & Development

Contributions and feature requests are welcome! Please:

- Document your changes clearly
- Submit a [pull request](https://github.com/maestro-org/maestro-mcp/compare) or [open an issue](https://github.com/maestro-org/maestro-mcp/issues/new)

### Local Development

- Use `bun run dev` for hot-reloading (if configured)
- Run tests with `bun test`

---

## Support

- [Open an issue](https://github.com/maestro-org/maestro-mcp/issues/new)
- [Join Discord](https://discord.gg/ES2rDhBJt3)

---

## License

[Apache 2.0](https://github.com/maestro-org/maestro-mcp/tree/HEAD/LICENSE)
