class ActionController::MCPServer::Description
inherits Reference
#
the toolboxes available to MCP clients, typically saved as mcp.yml
Included modules
JSON::Serializable
YAML::Serializable
Extended modules
JSON::Schema
Constructors#
.new(toolboxes : Array(ActionController::MCPServer::Toolbox) = [] of Toolbox, endpoints : Array(ActionController::MCPServer::Endpoint) = [] of Endpoint)#
.new(*, __context_for_yaml_serializable ctx : YAML::ParseContext, __node_for_yaml_serializable node : YAML::Nodes::Node)#
Methods#
#composition_id : String | ::Nil#
Detects descriptions generated for a different application composition.
#composition_id=(composition_id : String | Nil)#
Detects descriptions generated for a different application composition.
#endpoint?(path : String) : Endpoint | Nil#
the endpoint served at the path template, i.e. /accounts/:account_id/mcp
#endpoints : Array(Endpoint)#
controllers served as their own MCP server, see ActionController::MCP
#prompt?(name : String) : Tuple(Toolbox, Prompt) | Nil#
returns the prompt and the toolbox it belongs to
#resource?(uri : String) : Tuple(Tool, Hash(String, String)) | Nil#
the resource tool whose template matches the URI, and the template variables
#resource_tools : Array(Tool)#
the tools that are readable as resource templates, the most specific templates first
#tool?(name : String) : Tuple(Toolbox, Tool) | Nil#
returns the tool and the toolbox it belongs to