MCP.so
登录

Blockchain CLI in Rust MCP Server

@FaustoS88

基本信息

分类

开发工具

传输方式

stdio

作者

FaustoS88

关于 Blockchain CLI in Rust MCP Server

A simple blockchain implementation in Rust featuring SHA-256 hashing, CLI interface, and MCP server integration. Demonstrates core blockchain concepts through block creation and chain validation while exposing blockchain functionalities over a network.

Blockchain CLI in Rust MCP Server 配置

暂无标准配置

该服务器的 README 中没有可解析的 MCP 配置块,请前往代码仓库查看安装说明。

代码仓库

Blockchain CLI in Rust MCP Server 工具

工具列表暂未提供

当前收录暂时没有可展示的工具列表,不代表服务没有工具。请查阅项目文档了解支持的能力。

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is Blockchain CLI in Rust?

A minimal command-line blockchain demonstration implemented in Rust. It combines a menu-driven CLI for adding, printing, and validating blocks with an MCP server that exposes JSON-based blockchain commands over a network. This project is for developers learning Rust, blockchain fundamentals, or networked tool integration.

How to use Blockchain CLI in Rust?

Run cargo run in the project directory to start the application. The CLI presents a menu with options to add a block, print the blockchain, validate integrity, or exit. The MCP server starts automatically on 127.0.0.1:7878 and can be queried from a separate terminal using netcat (e.g., echo '{"command": "latest_block"}' | nc 127.0.0.1 7878).

Key features of Blockchain CLI in Rust

  • Implements a basic blockchain with SHA-256 hashing.
  • Provides a CLI menu for adding, printing, and validating blocks.
  • Integrates an MCP server on port 7878 for external access.
  • Supports JSON commands: latest_block and add_block.
  • Built with Rust, sha2, chrono, serde, and serde_json.

Use cases of Blockchain CLI in Rust

  • Learning Rust by building a blockchain from scratch.
  • Experimenting with MCP for networked tool communication.
  • Testing blockchain validation logic interactively.
  • Demonstrating how to run a CLI and a network server concurrently.

常见问题

1

What are the system requirements?

Rust (latest stable version) and Cargo are required to build and run the project.

2

How do I test the MCP server?

Run the application, then open a separate terminal and use netcat to send JSON commands, e.g., `echo '{"command": "add_block", "data": "test"}' | nc 127.0.0.1 7878`.

3

What MCP commands are available?

Two commands: `latest_block` (returns the latest block) and `add_block` (adds a new block with provided data).

4

Does the MCP server run on the main thread?

No, it runs in a separate thread alongside the CLI, so you must use a different terminal window for testing.

5

How can I validate the blockchain?

Select option 3 ("Validate Blockchain") from the CLI menu. The app checks that each block is properly linked via hashes.

评论

开发工具 分类下的更多 MCP 服务器