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
49
50
//! # pforge-config
//!
//! Configuration parsing and validation for pforge MCP servers.
//!
//! This crate provides YAML-based configuration with compile-time type safety
//! and comprehensive validation.
//!
//! ## Quick Start
//!
//! ```rust
//! use pforge_config::{parse_config_from_str, validate_config};
//!
//! let yaml = r#"
//! forge:
//! name: my-server
//! version: 0.1.0
//! transport: stdio
//!
//! tools:
//! - type: native
//! name: greet
//! description: "Greet a person"
//! handler:
//! path: "handlers::greet"
//! params: {}
//! "#;
//!
//! let config = parse_config_from_str(yaml).expect("valid config");
//! validate_config(&config).expect("validation passes");
//!
//! assert_eq!(config.forge.name, "my-server");
//! assert_eq!(config.tools.len(), 1);
//! ```
//!
//! ## Validation Rules
//!
//! - Tool names must be unique
//! - Native handlers must have valid handler paths (format: `module::function`)
//! - All required fields must be present
//! - Transport type must be valid (stdio, sse, websocket)
pub use ;
pub use ;
pub use *;
pub use validate_config;