class

ActionController::MCPServer::Prompt

Inherits YAML::Serializable < JSON::Serializable < Reference < Object

a controller method exposed as a prompt, see ActionController::MCP

Constructors

new(name : String, description : Nil | String, path : String, arguments : Array(ActionController::MCPServer::PromptArgument), root : Bool = false, title : Nil | String = nil, icons : Nil | Array(JSON::Any) = nil)
Source
new(ctx : YAML::ParseContext, node : YAML::Nodes::Node)
Source
new(pull : JSON::PullParser)
Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source
new(*, __context_for_yaml_serializable ctx : YAML::ParseContext, __node_for_yaml_serializable node : YAML::Nodes::Node)
Source

Instance methods

arguments
Source
description
Source
icons

icons, src as written, see Icons

Source
name
Source
path

the internal route that renders the prompt

Source
root?

always available, without opening the toolbox

Source
title

the display name

Source
to_mcp_json(json : JSON::Builder, host : String | Nil = nil, bound : Hash(String, String) | Nil = nil) : Nil

the prompt definition as returned by prompts/list, host resolves icon paths

Source