ruby-sdk
ruby-sdk copied to clipboard
The official Ruby SDK for the Model Context Protocol. Maintained in collaboration with Shopify.
I am still in the process of exploring the gem, and here are the initial challenges I've encountered that have slowed my progress. - Remove the example controller from the...
## Motivation and Context The MCP specification dated 2025-11-25 has been released: - https://modelcontextprotocol.io/specification/2025-11-25 - https://blog.modelcontextprotocol.io/posts/2025-11-25-first-mcp-anniversary This PR allows `'2025-11-25'` to be specified for the `:protocol_version` keyword argument in `MCP::Configuration.new`....
## Motivation and Context This PR updates the specification URL to `latest`. This change avoids the need to update the URL whenever a new protocol version is released. The `latest`...
## Motivation and Context This PR adds support for the optional `websiteUrl` parameter in `serverInfo`. This parameter has been supported since the 2025-11-25 MCP specification. This PR also implements part...
**Describe the bug** ```rb class ApplicationController < ActionController::API def mcp2 server = MCP::Server.new( name: "rails-mcp", version: "1.0.0", tools: [SecretNumber] ) render(json: server.handle_json(request.body.read)) end end class SecretNumber < MCP::Tool class (exception,...
## Motivation and Context This PR fixes incorrect examples in README.md. The block variable could be removed if it is unused, but when presenting an example `:server_context` should still be...
**Describe the bug** I'm trying to use protocol version `2025-03-26`, setting up the server as follows: ```rb class ApplicationController < ActionController::API def mcp2 configuration = MCP::Configuration.new(protocol_version: "2025-03-26") server = MCP::Server.new(...
> allow base `StreamableHTTP` transport to be easily dropped into any Rack, Rails, etc. app - build out conventions that make adding to any existing server trivial. _Originally posted by...
An example using ActionController::Live would be really cool. https://api.rubyonrails.org/classes/ActionController/Live.html
## Motivation and Context Running this example with Ruby 3.4.5 the following does not work: ```ruby Rackup::Handler.get("puma").run(rack_app, Port: 9393, Host: "0.0.0.0") ``` It returns the following error message: `uninitialized constant...