component-shape-mcp 0.3.1

Shared MCP protocol and schema helpers for component-shape integrations.
Documentation

component-shape-mcp

Codecov: component-shape-mcp crates.io: component-shape-mcp

component-shape-mcp provides typed JSON Schema, strict argument decoding, shared tool registries, structured results, composed servers, and stdio support for Rust applications that expose component contracts through MCP. It is the protocol-facing crate in the component-shape project; applications own authorization, domain validation, and handler policy.

Overview

  • Derive McpToolInput for named tool arguments with strict field decoding.
  • Use McpJsonSchema for nested schemas and McpToolValue for values that pair a schema with a decoder.
  • Register typed handlers in McpToolRegistry and return structured results.
  • Install a reusable registry with McpServer::from_tool_registry, or compose tools, resources, and prompts directly in McpServer.