All Classes and Interfaces
Class
Description
Utility class providing assertion methods for parameter validation.
Represents a closed MCP session, which may not be reused.
A default implementation of
McpStreamableServerSession.Factory.Default implementation of
McpTransportSession which manages the open
connections using tye Disposable type and allows to perform clean up using the
Disposable.dispose() method.An implementation of
McpTransportStream using Project Reactor types.Default implementation of the UriTemplateUtils interface.
Default implementation of
ServerTransportSecurityValidator that validates the
Origin and Host headers against lists of allowed values.Builder for creating instances of
DefaultServerTransportSecurityValidator.Deprecated.
This validator is part of the deprecated SSE transport.
Composable
McpAsyncHttpClientRequestCustomizer that applies multiple
customizers, in order.Composable
McpSyncHttpClientRequestCustomizer that applies multiple
customizers, in order.Deprecated.
This SSE transport is deprecated.
Builder for
HttpClientSseClientTransport.An implementation of the Streamable HTTP protocol as defined by the
2025-03-26 version of the MCP specification.Builder for
HttpClientStreamableHttpTransport.Names of HTTP headers in use by MCP HTTP transports.
Captures information about an HTTP request.
Deprecated.
This SSE transport is deprecated.
Builder for creating instances of HttpServletSseServerTransportProvider.
Implementation of an HttpServlet based
McpStatelessServerTransport.Builder for creating instances of
HttpServletStatelessServerTransport.Server-side implementation of the Model Context Protocol (MCP) streamable transport
layer using HTTP with Server-Sent Events (SSE) through HttpServlet.
Builder for creating instances of
HttpServletStreamableServerTransportProvider.Deprecated.
This exception is part of the deprecated SSE transport.
Interface for validating structured content against a JSON schema.
Deprecated.
Represents the result of a validation operation.
Represents the result of a validation operation.
A supplier interface that provides a
JsonSchemaValidator instance.A utility class for scheduling regular keep-alive calls to maintain connections.
Builder class for creating KeepAliveScheduler instances with fluent API.
The Model Context Protocol (MCP) client implementation that provides asynchronous
communication with MCP servers using Project Reactor's Mono and Flux types.
Customize
HttpRequest.Builder before executing the request, in either SSE or
Streamable HTTP transport.The Model Context Protocol (MCP) server implementation that provides asynchronous
communication using Project Reactor's Mono and Flux types.
Represents an asynchronous exchange with a Model Context Protocol (MCP) client.
Factory class for creating Model Context Protocol (MCP) clients.
Asynchronous client specification.
Synchronous client specification.
Default implementation of the MCP (Model Context Protocol) session that manages
bidirectional JSON-RPC communication between clients and servers.
Functional interface for handling incoming JSON-RPC notifications.
Functional interface for handling incoming JSON-RPC requests.
Interface for the client side of the
McpTransport.Deprecated, for removal: This API element is subject to removal in a future version.
in favor of
McpHttpClientTransportAuthorizationErrorHandlerSynchronous authorization error handler.
Handle security-related errors in HTTP-client based transports.
Synchronous authorization error handler.
Thrown when the MCP server responds with an authorization error (HTTP 401 or HTTP 403).
Request handler for the initialization request.
This class is to be used to provide access to the default
McpJsonMapper and to
the default JsonSchemaValidator instances via the static methods:
McpJsonDefaults.getMapper() and McpJsonDefaults.getSchemaValidator().Abstraction for JSON serialization/deserialization to decouple the SDK from any
specific JSON library.
Strategy interface for resolving a
McpJsonMapper.An
McpSession which is capable of processing logging notifications and keeping
track of a min logging level.A handler for client-initiated notifications.
A handler for client-initiated requests.
Based on the JSON-RPC 2.0
specification and the Model
Context Protocol Schema.
Base for objects that include optional annotations for the client.
Optional annotations for the client.
Audio provided to or from an LLM.
Binary contents of a resource.
Schema for a boolean field in a form-based elicitation request.
Used by the client to call a tool provided by the server.
The server's response to a tools/call request from the client.
Builder for
McpSchema.CallToolResult.Capabilities a client may support.
Provides a standardized way for servers to request additional information from
users through the client during interactions.
Marker record indicating support for form-based elicitation mode.
Marker record indicating support for URL-based elicitation mode.
Present if the client supports listing roots.
Provides a standardized way for servers to request LLM sampling ("completions"
or "generations") from language models via clients.
A reference to a prompt or resource that can be used as input for completion
requests.
A request from the client to the server, to ask for completion options.
The argument's information for completion requests.
Additional, optional context for completions.
The server's response to a completion/complete request.
The server's response to a completion/complete request
A polymorphic content value that can appear in messages and tool results.
A request from the server to sample an LLM via the client.
The client's response to a sampling/create_message request from the server.
A notification from the server to the client indicating that an out-of-band URL
elicitation interaction has completed.
A request from the server to elicit additional information from the user via the
client, using
form mode.A request from the server to elicit additional information from the user, either
through the client or out-of-band.
The client's response to an elicitation request.
A request from the server to elicit additional information from the user out of
band, using
url mode.The contents of a resource, embedded into a prompt or tool call result.
An option in a titled enum schema, with a machine-readable value and a
human-readable display label.
Standard error codes used in MCP JSON-RPC responses.
Used by the client to get a prompt provided by the server.
The server's response to a prompts/get request from the client.
Represents an icon that can be displayed in a user interface.
Base interface with name (identifier) and title (display name) properties.
An image provided to or from an LLM.
Describes the name and version of an MCP implementation, with an optional title for
UI representation.
This request is sent from the client to the server when it first connects, asking
it to begin initialization.
After receiving an initialize request from the client, the server sends this
response.
A notification which does not expect a response.
A request that expects a response.
A response to a request (successful, or error).
A response to a request that indicates an error occurred.
Deprecated.
use
Map instead.Deprecated.
Use
McpSchema.TitledSingleSelectEnumSchema insteadThe server's response to a prompts/list request from the client.
The server's response to a resources/list request from the client.
The server's response to a resources/templates/list request from the client.
The client's response to a roots/list request from the server.
The server's response to a tools/list request from the client.
Severity levels for MCP log messages, ordered from least to most severe.
The Model Context Protocol (MCP) provides a standardized way for servers to send
structured log messages to clients.
Base interface for MCP objects that include optional metadata in the `_meta` field.
Hints to use for model selection.
The server's preferences for model selection, requested of the client during
sampling.
Schema for a numeric field in a form-based elicitation request, supporting both
"number" (floating-point) and "integer" types.A request that supports pagination using cursors.
An opaque token representing the pagination position after the last returned
result.
The Model Context Protocol (MCP) supports optional progress tracking for
long-running operations through notification messages.
A prompt or prompt template that the server offers.
Describes an argument that a prompt can accept.
Describes a message returned as part of a prompt.
Identifies a prompt for completion requests.
Sent from the client to the server, to read a specific resource URI.
The server's response to a resources/read request from the client.
A known resource that the server is capable of reading.
A common interface for resource content, which includes metadata about the resource
such as its URI, name, description, MIME type, size, and annotations.
The contents of a specific resource or sub-resource.
A known resource that the server is capable of reading.
A reference to a resource or resource template definition for completion requests.
The Model Context Protocol (MCP) provides a standardized way for servers to send
resources update message to clients.
Resource templates allow servers to expose parameterized resources using URI
Represents a root directory or file that the server can operate on.
Describes a message issued to or received from an LLM API.
Capabilities that a server may support.
Present if the server supports argument autocompletion suggestions.
Present if the server supports sending log messages to the client.
Present if the server offers any prompt templates.
Present if the server offers any resources to read.
Present if the server offers any tools to call.
A request from the client to the server, to enable or adjust logging.
Schema for a text input field in a form-based elicitation request.
Sent from the client to request resources/updated notifications from the server
whenever a particular resource changes.
Text provided to or from an LLM.
Text contents of a resource.
Schema for multiple-selection enumeration with display titles for each option.
The items schema for
McpSchema.TitledMultiSelectEnumSchema, describing the allowed
enum options with display labels.Schema for single-selection enumeration with display titles for each option.
Represents a tool that the server provides.
Additional properties describing a Tool to clients.
Sent from the client to request cancellation of resources/updated notifications
from the server.
Schema for multiple-selection enumeration without display titles for options.
The items schema for
McpSchema.UntitledMultiSelectEnumSchema, describing the allowed
enum values.Schema for single-selection enumeration without display titles for options.
Factory class for creating Model Context Protocol (MCP) servers.
Asynchronous server specification.
Synchronous server specification.
MCP server features specification that a particular server can choose to support.
Specification of a completion handler function with asynchronous execution support.
Specification of a prompt template with its asynchronous handler function.
Specification of a resource with its asynchronous handler function.
Specification of a resource template with its synchronous handler function.
Specification of a tool with its asynchronous handler function.
Builder for creating AsyncToolSpecification instances.
Specification of a completion handler function with synchronous execution support.
Specification of a prompt template with its synchronous handler function.
Specification of a resource with its synchronous handler function.
Specification of a resource template with its synchronous handler function.
Specification of a tool with its synchronous handler function.
Builder for creating SyncToolSpecification instances.
Represents a Model Context Protocol (MCP) session on the server side.
Factory for creating server sessions which delegate to a provided 1:1 transport
with a connected client.
Notification handler for the initialization notification from the client.
Marker interface for the server-side MCP transport.
Classic implementation of
McpServerTransportProviderBase for a single outgoing
stream in bidirectional communication (STDIO and the legacy HTTP SSE).The core building block providing the server-side MCP transport.
Instance of this class are intended to be used differently in OSGi and non-OSGi
environments.
Represents a Model Context Protocol (MCP) session that handles communication between
clients and the server.
A stateless MCP server implementation for use with Streamable HTTP transport types.
Handler for MCP notifications in a stateless server.
Handler for MCP requests in a stateless server.
MCP stateless server features specification that a particular server can choose to
support.
Specification of a completion handler function with asynchronous execution support.
Specification of a prompt template with its asynchronous handler function.
Specification of a resource with its asynchronous handler function.
Specification of a resource template with its synchronous handler function.
Specification of a tool with its asynchronous handler function.
Builder for creating AsyncToolSpecification instances.
Specification of a completion handler function with synchronous execution support.
Specification of a prompt template with its synchronous handler function.
Specification of a resource with its synchronous handler function.
Specification of a resource template with its synchronous handler function.
Specification of a tool with its synchronous handler function.
Builder for creating SyncToolSpecification instances.
Handler for MCP requests and notifications in a Stateless Streamable HTTP Server
context.
A stateless MCP server implementation for use with Streamable HTTP transport types.
Representation of a Streamable HTTP server session that keeps track of mapping
server-initiated requests to the client and mapping arriving responses.
Factory for new Streamable HTTP MCP sessions.
Request handler for the initialization request.
Composite holding the
McpStreamableServerSession and the initialization
resultStreamable HTTP server transport representing an individual SSE stream.
The core building block providing the server-side MCP transport for Streamable HTTP
servers.
A synchronous client implementation for the Model Context Protocol (MCP) that wraps an
McpAsyncClient to provide blocking operations.Customize
HttpRequest.Builder before executing the request, either in SSE or
Streamable HTTP transport.A synchronous implementation of the Model Context Protocol (MCP) server that wraps
McpAsyncServer to provide blocking operations.Represents a synchronous exchange with a Model Context Protocol (MCP) client.
Defines the asynchronous transport layer for the Model Context Protocol (MCP).
Context associated with the transport layer.
The contract for extracting metadata from a generic transport request of type
McpTransportContextExtractor.Exception thrown when there is an issue with the transport layer of the Model Context
Protocol (MCP).
An abstraction of the session as perceived from the MCP transport layer.
Exception thrown when trying to use an
McpTransportSession that has been
closed.Exception that signifies that the server does not recognize the connecting client via
the presented transport session identifier.
A representation of a stream at the transport layer of the MCP protocol.
Interface for working with URI templates.
Factory interface for creating instances of
McpUriTemplateManager.A
McpLoggableSession which represents a missing stream that would allow the
server to communicate with the client.Server parameters for stdio client.
Exception thrown when security validation fails for an HTTP request.
Interface for validating HTTP requests in server transports.
Deprecated.
This validator is part of the deprecated SSE transport.
Implementation of the MCP Stdio transport that communicates with a server process using
standard input/output streams.
Implementation of the MCP Stdio transport provider for servers that communicates using
standard input/output streams.
Validates tool input arguments against JSON schema.
Validates tool names according to the MCP specification.
Captures generic type information at runtime for parameterized JSON (de)serialization.
Miscellaneous utility methods.