AI Skill Hub 推荐使用:MCP工具 是一款优质的MCP工具。AI 综合评分 7.5 分,在同类工具中表现稳健。如果你正在寻找可靠的MCP工具解决方案,这是一个值得深入了解的选择。
MCP工具 是一款遵循 MCP(Model Context Protocol)标准协议的 AI 工具扩展。通过 MCP 协议,它可以让 Claude、Cursor 等主流 AI 客户端直接访问和操作外部工具、数据源和服务,实现 AI 能力的无缝扩展。无论是文件操作、数据库查询还是 API 调用,都可以通过自然语言在 AI 对话中直接触发,极大提升生产效率。
MCP工具 是一款遵循 MCP(Model Context Protocol)标准协议的 AI 工具扩展。通过 MCP 协议,它可以让 Claude、Cursor 等主流 AI 客户端直接访问和操作外部工具、数据源和服务,实现 AI 能力的无缝扩展。无论是文件操作、数据库查询还是 API 调用,都可以通过自然语言在 AI 对话中直接触发,极大提升生产效率。
# 方式一:通过 Claude Code CLI 一键安装
claude skill install https://github.com/seuros/action_mcp
# 方式二:手动配置 claude_desktop_config.json
{
"mcpServers": {
"mcp--": {
"command": "npx",
"args": ["-y", "action_mcp"]
}
}
}
# 配置文件位置
# macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
# Windows: %APPDATA%/Claude/claude_desktop_config.json
# 安装后在 Claude 对话中直接使用 # 示例: 用户: 请帮我用 MCP工具 执行以下任务... Claude: [自动调用 MCP工具 MCP 工具处理请求] # 查看可用工具列表 # 在 Claude 中输入:"列出所有可用的 MCP 工具"
// claude_desktop_config.json 配置示例
{
"mcpServers": {
"mcp__": {
"command": "npx",
"args": ["-y", "action_mcp"],
"env": {
// "API_KEY": "your-api-key-here"
}
}
}
}
// 保存后重启 Claude Desktop 生效
ActionMCP is a Ruby gem focused on providing Model Context Protocol (MCP) capability to Ruby on Rails applications, specifically as a server.
ActionMCP is designed for production Rails environments and does not support STDIO transport. STDIO is not included because it is not production-ready and is only suitable for desktop or script-based use cases. Instead, ActionMCP is built for robust, network-based deployments.
The client functionality in ActionMCP is intended to connect to remote MCP servers, not to local processes via STDIO.
It offers base classes and helpers for creating MCP applications, making it easier to integrate your Ruby/Rails application with the MCP standard.
With ActionMCP, you can focus on your app's logic while it handles the boilerplate for MCP compliance.
Model Context Protocol (MCP) is an open protocol that standardizes how applications provide context to large language models (LLMs).
Think of it as a universal interface for connecting AI assistants to external data sources and tools.
MCP allows AI systems to plug into various resources in a consistent, secure way, enabling two-way integration between your data and AI-powered applications.
This means an AI (like an LLM) can request information or actions from your application through a well-defined protocol, and your app can provide context or perform tasks for the AI in return.
ActionMCP is targeted at developers building MCP-enabled Rails applications. It simplifies the process of integrating Ruby and Rails apps with the MCP standard by providing a set of base classes and an easy-to-use server interface.
bin/rails action_mcp:show_profile[admin]
ActionMCP is tested against Ruby 3.4.8 and 4.0.0 with Rails 8.1.1+.
bundle install
To start using ActionMCP, add it to your project:
```bash
ActionMCP includes generators to help you set up your project quickly. The install generator creates all necessary base classes and configuration files:
```bash
bin/rails generate action_mcp:install ```
This will create: - app/mcp/prompts/application_mcp_prompt.rb - Base prompt class - app/mcp/tools/application_mcp_tool.rb - Base tool class - app/mcp/resource_templates/application_mcp_res_template.rb - Base resource template class - app/mcp/application_gateway.rb - Gateway for authentication - config/mcp.yml - Configuration file with example settings for all environments - mcp/config.ru - Standalone Rack server configuration - bin/mcp - Server binstub (prefers Falcon, falls back to Puma)
Note: Authentication and authorization are not included. You are responsible for securing the endpoint.
In production, MCPS0 (the MCP server) is a standard Rack application. You can run it using any Rack-compatible server (such as Puma, Unicorn, or Passenger).
For best performance and concurrency, it is highly recommended to use a modern, synchronous server like Falcon. Falcon is optimized for streaming and concurrent workloads, making it ideal for MCP servers. You can still use Puma, Unicorn, or Passenger, but Falcon will generally provide superior throughput and responsiveness for real-time and streaming use cases.
You have several main options for exposing the server:
mcp_vanilla.ru to avoid middleware conflictsProfiles are particularly useful for:
By leveraging profiles, you can maintain a single ActionMCP codebase while providing tailored MCP capabilities for different contexts.
ActionMCP includes a client for connecting to remote MCP servers. The client handles session management, protocol negotiation, and provides a simple API for interacting with MCP servers.
For comprehensive client documentation, including examples, session management, transport configuration, and API usage, see CLIENTUSAGE.md.
bin/rails generate action_mcp:install
ActionMCP is configured via config.action_mcp in your Rails application.
By default, the name is set to your application's name and the version defaults to "0.0.1" unless your app has a version file.
You can override these settings in your configuration (e.g., in config/application.rb):
module Tron
class Application < Rails::Application
config.action_mcp.name = "Friendly MCP (Master Control Program)" # defaults to Rails.application.name
config.action_mcp.version = "1.2.3" # defaults to "0.0.1"
config.action_mcp.logging_enabled = true # defaults to true
config.action_mcp.logging_level = :info # defaults to :info, can be :debug, :info, :warn, :error, :fatal
# Server instructions - helps LLMs understand the server's purpose
config.action_mcp.server_instructions = [
"Use this server to access and control Tron system programs",
"Helpful for managing system processes and user data"
]
end
end
For dynamic versioning, consider adding the rails_app_version gem.
You can configure the session store type in your Rails configuration or config/mcp.yml:
```ruby
Rails.application.configure do config.action_mcp.session_store_type = :active_record # or :volatile end
Or in `config/mcp.yml`:
yaml
You can configure the thread pool in your config/mcp.yml:
production:
# Thread pool configuration
min_threads: 10 # Minimum number of threads to keep in the pool
max_threads: 20 # Maximum number of threads the pool can grow to
max_queue: 500 # Maximum number of tasks that can be queued
The thread pool will automatically: - Start with min_threads threads - Scale up to max_threads as needed - Queue tasks up to max_queue limit - Use caller's thread if queue is full (fallback policy)
The install generator (rails generate action_mcp:install) creates this automatically. If you need to create it manually:
```ruby
require_relative "../config/environment"
$stdout.sync = true
bundle exec rails action_mcp:info bundle exec rails action_mcp:stats
bundle exec rails action_mcp:show_profile[profile_name] ```
Profiles are configured via a config/mcp.yml file in your Rails application. If this file doesn't exist, ActionMCP will use default settings from the gem.
Example configuration:
default:
tools:
- all # Include all tools
prompts:
- all # Include all prompts
resources:
- all # Include all resources
options:
list_changed: false
logging_enabled: true
logging_level: info
resources_subscribe: false
api_only:
tools:
- calculator
- weather
prompts: [] # No prompts for API
resources:
- user_profile
options:
list_changed: false
logging_level: warn
admin:
tools:
- all
options:
logging_level: debug
list_changed: true
resources_subscribe: true
Each profile can specify: - tools: Array of tool names to include (use all to include all tools) - prompts: Array of prompt names to include (use all to include all prompts) - resources: Array of resource names to include (use all to include all resources) - options: Additional configuration options: - list_changed: Whether to send change notifications - logging_enabled: Whether to enable logging - logging_level: The logging level to use - resources_subscribe: Whether to enable resource subscriptions
bin/rails action_mcp:list_profiles
ActionMCP provides three core abstractions to streamline MCP server development:
ApplicationGatewayActionMCP::CurrentOnce authenticated, the current user (and other identifiers) are available in your tools, prompts, and resource templates:
class MyTool < ApplicationMCPTool
def perform
# Access the authenticated user
if current_user
render text: "Hello, #{current_user.name}!"
else
render text: "Hi Stranger! It's been a while "
end
end
end
bundle exec rails action_mcp:list
bundle exec rails action_mcp:list_tools bundle exec rails action_mcp:list_prompts bundle exec rails action_mcp:list_resources bundle exec rails action_mcp:list_profiles
mcp_vanilla.ru for production💡 Pro Tip: Start with the component-specific guides (TOOLS.MD, PROMPTS.MD, RESOURCE_TEMPLATES.md) for hands-on development, then reference the Hitchhiker's Guide for protocol details and CLIENTUSAGE.MD for integration patterns.
ActionMCP provides comprehensive error handling following the JSON-RPC 2.0 specification:
高质量的MCP工具,支持多种功能
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
✅ MIT 协议 — 最宽松的开源协议之一,可自由商用、修改、分发,仅需保留版权声明。
总体来看,MCP工具 是一款质量良好的MCP工具,在同类工具中具备一定竞争力。AI Skill Hub 将持续追踪其更新动态,建议收藏备用,结合自身场景选择合适时机引入使用。
| 原始名称 | action_mcp |
| 原始描述 | 开源MCP工具:Rails Engine with MCP compliant Spec.。⭐115 · Ruby |
| Topics | mcpaiauthenticationclaudegatewaygemruby |
| GitHub | https://github.com/seuros/action_mcp |
| License | MIT |
| 语言 | Ruby |
收录时间:2026-05-28 · 更新时间:2026-05-28 · License:MIT · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端