First Version

This commit is contained in:
2026-07-10 15:02:09 +01:00
commit 38494a85a9
562 changed files with 196313 additions and 0 deletions
+29
View File
@@ -0,0 +1,29 @@
use std::collections::HashMap;
use serde::Deserialize;
#[derive(Debug, Deserialize, Clone)]
pub struct McpServerConfig {
pub name: String,
pub transport: McpTransport,
/// stdio only: the executable to spawn.
pub command: Option<String>,
/// stdio only: arguments passed to the command.
pub args: Option<Vec<String>>,
/// stdio only: extra environment variables (values support `${VAR}` interpolation).
pub env: Option<HashMap<String, String>>,
/// http only: base URL of the MCP server.
pub url: Option<String>,
/// http only: API key sent as `Authorization: Bearer <key>` (supports `${VAR}` interpolation).
pub api_key: Option<String>,
}
#[derive(Debug, Deserialize, Clone)]
#[serde(rename_all = "snake_case")]
pub enum McpTransport {
Stdio,
/// Streamable HTTP (remote MCP servers — previously called SSE).
Http,
/// Alias kept for backwards compatibility.
Sse,
}