using ColaFlow.Modules.Mcp.Contracts.JsonRpc;

namespace ColaFlow.Modules.Mcp.Domain.Exceptions;

/// <summary>
/// Exception thrown when authorization fails (authenticated but not allowed)
/// Maps to JSON-RPC error code -32002 (Forbidden)
/// HTTP 403 status code
/// </summary>
public class McpForbiddenException : McpException
{
    /// <summary>
    /// Initializes a new instance of the <see cref="McpForbiddenException"/> class
    /// </summary>
    /// <param name="message">Error message</param>
    /// <param name="errorData">Additional error data (optional)</param>
    public McpForbiddenException(string message = "Forbidden", object? errorData = null)
        : base(JsonRpcErrorCode.Forbidden, message, errorData)
    {
    }
}
