Package-level declarations

Types

Link copied to clipboard
fun interface CancellationCallback
Link copied to clipboard
interface Cancellations

Handles Cancellation requests

Link copied to clipboard
sealed interface ClientRequestContext

How a client is identified for sending a request to.

Link copied to clipboard
sealed interface ClientRequestTarget

How a client is identified for sending a request to.

Link copied to clipboard
Link copied to clipboard
interface Completions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
interface Logger

Logs messages for a session back to the client.

Link copied to clipboard
class McpProtocol<Transport>(metaData: ServerMetaData, sessions: Sessions<Transport>, tools: Tools = ServerTools(), resources: Resources = ServerResources(), prompts: Prompts = ServerPrompts(), completions: Completions = ServerCompletions(), logger: Logger = ServerLogger(), roots: Roots = ServerRoots(), cancellations: Cancellations = ServerCancellations(), random: Random = Random, onError: (Throwable) -> Unit = { it.printStackTrace(System.err) })

Models the MCP protocol in terms of message handling and session management.

Link copied to clipboard

Provides notification telling the client of changes to underlying capabilities lists.

Link copied to clipboard

Provides notification telling the client of changes to a particular resource

Link copied to clipboard
interface Prompts

Handles protocol traffic for prompts features.

Link copied to clipboard
interface Resources

Handles protocol traffic for resources features and subscriptions.

Link copied to clipboard
interface Roots

Handles protocol traffic for client provided roots.

Link copied to clipboard
Link copied to clipboard
data class Session(val id: SessionId) : SessionState
Link copied to clipboard
class SessionBasedClient<Transport>(progressToken: ProgressToken, context: ClientRequestContext, sessions: Sessions<Transport>, random: Random, clientTracking: () -> ClientTracking?) : Client
Link copied to clipboard
interface Sessions<Transport>

Responsible for managing the lifecycle of client sessions, including the assignment of transport to session, and the sending of messages to the client.

Link copied to clipboard
sealed interface SessionState

Represents a session for a connection.

Link copied to clipboard
interface Tools

Handles protocol traffic for server provided tools.