using ColaFlow.Modules.Mcp.Contracts.Tools;

namespace ColaFlow.Modules.Mcp.Application.Services;

/// <summary>
/// Registry interface for MCP Tools
/// Manages tool discovery and dispatching
/// </summary>
public interface IMcpToolRegistry
{
    /// <summary>
    /// Get all registered tools
    /// </summary>
    IEnumerable<IMcpTool> GetAllTools();

    /// <summary>
    /// Get tool by name
    /// </summary>
    IMcpTool? GetTool(string toolName);

    /// <summary>
    /// Check if tool exists
    /// </summary>
    bool HasTool(string toolName);

    /// <summary>
    /// Execute a tool by name
    /// </summary>
    Task<McpToolResult> ExecuteToolAsync(
        McpToolCall toolCall,
        CancellationToken cancellationToken = default);
}
