1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
//! MCP (Model Context Protocol) server configuration (beta).
//!
//! This module provides types for configuring MCP servers that Claude
//! can use during conversations:
//!
//! - [`McpServer`] - MCP server connection configuration
//! - [`ToolConfiguration`] - Tool access configuration for servers
//!
//! # Note
//!
//! MCP support is currently in beta. See the Anthropic documentation
//! for the latest information on MCP capabilities and configuration.
//!
//! # Example
//!
//! ```rust
//! use anthropic_tools::messages::request::mcp::{McpServer, ToolConfiguration};
//!
//! let server = McpServer {
//! name: "my-server".to_string(),
//! type_name: "url".to_string(),
//! url: "https://mcp.example.com".to_string(),
//! authorization_token: Some("token".to_string()),
//! tool_configuration: Some(ToolConfiguration {
//! allowed_tools: vec!["tool1".to_string(), "tool2".to_string()],
//! enabled: true,
//! }),
//! };
//! ```
use ;
/// Tool configuration for MCP servers