pub struct McpServerSpec {
pub name: String,
pub endpoint: String,
pub headers: Vec<(String, String)>,
pub tags: Vec<TrifectaTag>,
pub aauth: Option<bool>,
pub oauth: Option<McpOauthSpec>,
pub auth: Option<AuthSpec>,
}Expand description
A declared MCP server. Serializable because it travels in the subagent spawn payload as the child’s scoped server subset (RFC 0005, RFC 0009).
As of v2.0.0 the sole transport is a remote endpoint
reached over Streamable HTTP (RFC 0004; RFC 0012 — no local process spawn).
Fields§
§name: String§endpoint: StringRemote MCP endpoint — https://host[:port][/path] (loopback http://
for dev), reached over RFC 0004 Streamable HTTP.
headers: Vec<(String, String)>Secret-FREE auth/framing header templates (e.g. ("Authorization", "Bearer {{secret:MCP_TOKEN}}")), resolved at connect time (RFC 0012 §3.7 — no
credential in the spec/manifest/payload/logs).
Operator-declared capability tags (--mcp-tags) for the Rule-of-Two
trifecta check (RFC 0012 §3.1). Travels in the spawn payload so a child’s
narrowed grant carries the same tags. Empty = untagged (the check treats
an untagged server conservatively as untrusted_input).
aauth: Option<bool>Sign requests to THIS server with the AAuth agent identity (RFC 0023).
Per-server opt-in: None inherits the global default (sign all when an
--aauth-provider is configured); Some(false) opts out; Some(true)
opts in even if the global default were off. Travels in the spawn payload.
oauth: Option<McpOauthSpec>OAuth 2.1 client-credentials for an endpoint behind an OAuth gateway
(RFC 0031 §7): a refreshing Authorization: Bearer … fetched from the
token endpoint. Secret-free (client_secret is a {{secret:…}}
template). Travels in the spawn payload; takes the request-signer seam
when set (mutually exclusive with per-server AAuth signing).
auth: Option<AuthSpec>The unified credential provider (RFC 0031 §5). Takes precedence over the
legacy oauth/aauth when set. Travels in the spawn payload.
Trait Implementations§
Source§impl Clone for McpServerSpec
impl Clone for McpServerSpec
Source§fn clone(&self) -> McpServerSpec
fn clone(&self) -> McpServerSpec
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more