MCP Catalogs
Home

mcp_on_ruby

by nagstler·98·Score 44

A production-ready Ruby implementation of MCP for Rails applications with authentication and tool/resource exposure.

developer-toolsai-llmother
7
Forks
0
Open issues
10 mo ago
Last commit
2d ago
Indexed

Overview

MCP on Ruby provides a robust implementation of the Model Context Protocol specifically designed for Rails applications. It offers a clean DSL for defining tools and resources, with full integration into the Rails ecosystem including generators, middleware, and Railtie. The server includes comprehensive security features like authentication, rate limiting, DNS rebinding protection, and CORS support. It supports both tools (callable functions) and resources (data exposure with URI templating) systems, with JSON Schema validation for input parameters.

Try asking AI

After installing, here are 6 things you can ask your AI assistant:

you:Expose Rails application functionality to AI systems via MCP protocol
you:Create secure APIs for AI agents to manage application data
you:Integrate Ruby on Rails applications with AI clients like Claude Desktop
you:What Ruby versions are supported?
you:How do I create a new tool?
you:Is authentication supported?

When to choose this

Choose this MCP server if you're building on Rails and want to expose your application's functionality and data to AI agents with proper security and authentication.

When NOT to choose this

Don't choose this if you're not using Ruby/Rails or need more advanced real-time features like Server-Sent Events (SSE) which are still in development.

Tools this server exposes

2 tools extracted from the README
  • user_manager

    Manage application users (create, update, delete)

  • User_Statistics

    Get detailed user statistics by user ID

Comparable tools

mcp-jsmcp-pythonlangchain-railsrails-llm

Installation

Installation steps:

  1. Add to Gemfile:
gem 'mcp_on_ruby'
  1. Run bundle install:
bundle install
  1. Generate MCP server files:
rails generate mcp_on_ruby:install
  1. Configure MCP server in config/initializers/mcp_on_ruby.rb
  1. Start Rails server:
rails server

MCP server will be available at http://localhost:3000/mcp

For Claude Desktop integration, add to Claude config:

{
  "mcpServers": {
    "rails-mcp": {
      "command": "rails",
      "args": ["server"]
    }
  }
}

FAQ

What Ruby versions are supported?
Ruby 2.7.0 or higher is required for MCP on Ruby.
How do I create a new tool?
Use the Rails generator: `rails generate mcp_on_ruby:tool <ToolName> --description "Description"`
Is authentication supported?
Yes, MCP on Ruby includes authentication via tokens and can be configured in the initializer.

On Hacker News

Recent discussion from the developer community.

Compare mcp_on_ruby with

GitHub →

Last updated · Auto-generated from public README + GitHub signals.