Expand description
Complete MCP Protocol Types for 2025-03-26 Specification
This module contains all the core types defined by the Model Context Protocol specification version 2025-03-26, including all new features and capabilities.
Modules§
- error_
codes - Standard JSON-RPC error codes
Structs§
- Annotations
- Tool behavior annotations (2025-03-26)
- Audio
Content - Audio content (2025-03-26 NEW)
- Call
Tool Result - Result of a tool execution (2025-03-26 with metadata)
- Client
Capabilities - Client capabilities for 2025-03-26
- Completions
Capability - Autocompletion capabilities (2025-03-26)
- Create
Message Result - Result of sampling/createMessage (2025-03-26)
- Embedded
Resource - Embedded resource content (2025-03-26)
- Error
Object - Error object
- GetPrompt
Result - Result of prompt execution (2025-03-26 with metadata)
- Image
Content - Image content
- Implementation
- Information about an MCP implementation
- Json
RpcError - JSON-RPC error message
- Json
RpcNotification - JSON-RPC notification message
- Json
RpcRequest - JSON-RPC request message
- Json
RpcResponse - JSON-RPC response message
- Logging
Capability - Logging capabilities (2025-03-26)
- Model
Preferences - Model preferences for sampling
- Notification
- Base notification with metadata support
- Notification
Params - Notification parameters with metadata
- Paginated
Request - Base for paginated requests
- Paginated
Result - Base for paginated results
- Prompt
- Prompt definition
- Prompt
Argument - Argument for a prompt
- Prompt
Message - Message in a prompt result (2025-03-26 with audio support)
- Prompts
Capability - Prompt-related server capabilities
- Request
- Base request with metadata support
- Request
Meta - Request metadata
- Request
Params - Request parameters with metadata
- Resource
- Resource definition
- Resource
Reference - Resource reference for embedded resources
- Resource
Template - Resource template for URI patterns
- Resources
Capability - Resource-related server capabilities
- Roots
Capability - Roots capability for clients (2025-03-26)
- Sampling
Capability - Sampling-related capabilities
- Sampling
Message - A message in a sampling conversation (2025-03-26 with audio)
- Server
Capabilities - Server capabilities for 2025-03-26
- Text
Content - Text content
- Tool
- Tool definition with annotations (2025-03-26)
- Tool
Input Schema - Tool input schema
- Tools
Capability - Tool-related server capabilities
Enums§
- Annotation
Audience - Target audience for tool usage
- Content
- Unified content type (2025-03-26 complete)
- Danger
Level - Danger level classification for tools
- Json
RpcId - JSON-RPC ID type for better type safety
- Json
RpcMessage - Complete JSON-RPC message types (2025-03-26)
- Json
RpcRequest OrNotification - Items in a batch request
- Json
RpcResponse OrError - Items in a batch response
- Logging
Level - Logging level enumeration (2025-03-26)
- Resource
Contents - Content of a resource
- Role
- Message role
- Stop
Reason - Reasons why sampling stopped
Constants§
- JSONRPC_
VERSION - LATEST_
PROTOCOL_ VERSION - MCP Protocol version (2025-03-26)
- PROTOCOL_
VERSION
Type Aliases§
- Client
Info - Cursor
- Cursor for pagination
- Json
RpcBatch Request - JSON-RPC batch request (2025-03-26 NEW)
- Json
RpcBatch Response - JSON-RPC batch response (2025-03-26 NEW)
- Progress
Token - Progress token for associating notifications with requests
- Prompt
Info - Prompt
Result - Request
Id - Request ID for JSON-RPC correlation
- Resource
Info - Server
Info - Tool
Info - Tool
Result