Documentation
¶
Index ¶
- func DecodeToolContent(content mcp.ToolContent) object.Object
- func DecodeToolResponse(response *mcp.ToolResponse) object.Object
- func DictToMap(dict *object.Dict) map[string]interface{}
- func ParseToolSearchResults(response *mcp.ToolResponse) (*object.List, error)
- func ParseToolSearchResultsFromText(text string) (*object.List, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecodeToolContent ¶
func DecodeToolContent(content mcp.ToolContent) object.Object
DecodeToolContent converts a single ToolContent block to a scriptling Object.
func DecodeToolResponse ¶
func DecodeToolResponse(response *mcp.ToolResponse) object.Object
DecodeToolResponse converts an MCP ToolResponse to a scriptling Object. Handles: - Single text content: returns parsed JSON or string - Multiple content blocks: returns list of decoded blocks - Structured content: returns decoded object
func DictToMap ¶
DictToMap converts a scriptling Dict to a Go map[string]interface{}. This is a convenience wrapper around scriptlib.ToGo for the common case of converting Dict arguments for tool calls.
func ParseToolSearchResults ¶
func ParseToolSearchResults(response *mcp.ToolResponse) (*object.List, error)
ParseToolSearchResults extracts tool list from tool_search response. Returns a scriptling List containing tool dicts with name, description, input_schema. The tool_search response is expected to be a ToolResponse with JSON text content containing an array of tool definitions.
Types ¶
This section is empty.