- Namespace
- ModelContextProtocol
- Assembly
- ModelContextProtocol.Core.dll
Represents an exception that is thrown when a Model Context Protocol (MCP) error occurs.
public class McpException : Exception, ISerializable
- Inheritance
-
McpException
- Implements
- Derived
- Inherited Members
Constructors
McpException()
Initializes a new instance of the McpException class.
McpException(string)
Initializes a new instance of the McpException class with a specified error message.
public McpException(string message)
Parameters
messagestringThe message that describes the error.
McpException(string, Exception?)
Initializes a new instance of the McpException class with a specified error message and a reference to the inner exception that is the cause of this exception.
public McpException(string message, Exception? innerException)