home / mcp / rubygems mcp server

Rubygems MCP Server

Provides access to RubyGems data, Ruby versions, and related information via MCP tools and resources.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "amkisko-rubygems_mcp.rb": {
      "command": "gem",
      "args": [
        "exec",
        "rubygems_mcp"
      ],
      "env": {
        "RUBY_VERSION": "3.4.7"
      }
    }
  }
}

You run rubygems_mcp as an MCP server that exposes RubyGems and Ruby version information to MCP-enabled clients. It connects with tools like Cursor IDE and Claude Desktop, letting you query gem data, Ruby versions, changelogs, and related details through MCP endpoints.

How to use

Install the MCP server gem and start the server to begin answering MCP tool requests. Your MCP-enabled clients will discover and interact with the server to fetch gem data, Ruby version info, and related resources.

From an MCP client, configure the rubygems_mcp server as a local stdio connection. The server starts and communicates via STDIN/STDOUT using the MCP protocol. You will access 19 tools and 4 resources that cover gems, versions, searches, downloads, changelogs, and Ruby maintenance data.

How to install

# Prerequisites
- Ruby 3.1 or higher
- Bundler (usually via `gem install bundler`)

# Install the MCP server gem
gem install rubygems_mcp

# Start the MCP server (stdio config is shown in the example configuration)
bundle exec rubygems_mcp

Configuration examples

Use an MCP client configuration that runs the server via a local command. The following configuration uses the RubyGems MCP server as a stdio backend. It runs the server through the gem command to ensure the correct Ruby version is used.

{
  "mcpServers": {
    "rubygems": {
      "command": "gem",
      "args": ["exec", "rubygems_mcp"],
      "env": {
        "RUBY_VERSION": "3.4.7"
      }
    }
  }
}

Testing the MCP server with an inspector

Validate that the server starts correctly and is reachable by MCP clients. Use the MCP Inspector to verify that the server exposes the expected tools and can handle requests.

# Run the inspector to connect to your rubygems_mcp server
npx @modelcontextprotocol/inspector bundle exec rubygems_mcp

Running the MCP server manually

You can run the server directly after installation. The server communicates over STDIN/STDOUT using the MCP protocol.

# With bundler
gem install rubygems_mcp
bundle exec rubygems_mcp

# Or if installed globally
rubygems_mcp

Security and access

All endpoints exposed by rubygems_mcp are public and do not require authentication. Treat this as you would any public API access: monitor usage and ensure that your development environment is secure, especially when exposing local MCP endpoints to teammates.

Notes on MCP tools and resources

The server provides a comprehensive set of tools to query gem data, Ruby versions, and related information. You can explore latest versions, specific gem versions, reverse dependencies, download statistics, changelogs, searches, and more. There are also resources that expose curated data like popular gems and Ruby maintenance details.

Additional configuration and tooling details

If you use a Ruby version manager, ensure the RUBY_VERSION environment variable matches the Ruby you intend to query. The stdio server configuration shown above uses gem exec rubygems_mcp to guarantee the correct Ruby context is applied for every request.

Available tools

get_latest_versions

Fetch the latest versions for a list of gems, including release dates and licenses, with optional field selection.

get_gem_versions

Retrieve all versions for a single gem, with pagination, sorting, and field selection.

get_latest_ruby_version

Return the latest Ruby version along with its release date.

get_ruby_versions

List all Ruby versions with release dates, download URLs, and release notes URLs; supports pagination and sorting.

get_ruby_version_changelog

Obtain a changelog summary for a specific Ruby version by parsing release notes.

get_gem_info

Get detailed information about a gem, including summary, homepage, source code, documentation, licenses, authors, and dependencies.

get_gem_version_info

Get details for a specific gem version from RubyGems API v2, including downloads, dependencies, and built date.

get_gem_reverse_dependencies

List gems that depend on the specified gem.

get_gem_version_downloads

Fetch download statistics for a specific gem version.

get_latest_gems

List the most recently added gems on RubyGems.org.

get_recently_updated_gems

List gems with recently updated versions.

get_gem_changelog

Provide a changelog summary for a gem by parsing its changelog URI.

search_gems

Search for gems by name on RubyGems.org.

get_ruby_roadmap

Show Ruby roadmap information with planned versions and associated issues.

get_ruby_version_roadmap_details

Get detailed roadmap information for a specific Ruby version, including issues and planned features.

get_ruby_version_github_changelog

Fetch GitHub changelog for a Ruby version from the ruby/ruby repository.

get_news_releases

Retrieve all new gem releases from RubyGems.org with pagination.

get_popular_releases

Retrieve popular new gem releases from RubyGems.org with pagination.