Skip to content
Tracon

TraconMcpOptions

Namespace Tracon · Assembly Tracon.Mcp.dll

Options for connecting to remote MCP servers.

public sealed class TraconMcpOptions
Inheritance
object ← TraconMcpOptions
Inherited Members
object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
public TraconMcpOptions()

The default name of the configuration section.

public const string SectionName = "Tracon:Mcp"

string

The upper time bound for connecting to a server and listing its tools.

public TimeSpan ConnectionTimeout { get; set; }

TimeSpan

Must be from one millisecond to about 49.7 days; any other value fails at startup.

Whether MCP tool discovery is on. When turned off, no server is connected to and only the tools registered in code are visible.

public bool Enabled { get; set; }

bool

In Mode A (AgentDefinition.McpResourceUris), the maximum number of bytes added to the context from a single resource. Content beyond this limit is trimmed.

public int MaxResourceBytesPerResource { get; set; }

int

In Mode A, the total byte limit across all resources of an agent definition. Resources beyond this limit are trimmed; resources beyond the total limit are skipped entirely.

public int MaxResourceBytesTotal { get; set; }

int

The maximum number of tools accepted from a single server. Tools beyond this limit are dropped and a warning is logged.

public int MaxToolsPerServer { get; set; }

int

The remote server is treated as untrusted. An unbounded tool list would produce uncontrolled growth both in the model context and in the UI.

The base URI of the OAuth Mode 1 (authorization code) callback addresses. Example: https://myapp.example.com/. Must already be registered with the provider. When null, no connection is made to a server with OAuth enabled, and /oauth/start answers that OAuth is not configured.

public Uri? OAuthCallbackBaseUri { get; set; }

Uri?

The refresh interval of the tool list. A remote server may change its tool definitions; discovery repeats at this interval.

public TimeSpan RefreshInterval { get; set; }

TimeSpan

How long a server’s last good tool list is kept when a refresh cannot list its tools. The default is 15 minutes, three refreshes at the default interval.

public TimeSpan StaleToolRetention { get; set; }

TimeSpan

A network blip on one tools/list call no longer takes a server’s tools away: while the server stays registered with the same definition, its connection keeps serving the tools it last listed for this long after that listing, and agents that use them keep running. A call that reaches a server that is really down fails as a tool error, as it would during the next refresh interval. Once the time has passed, the next failed refresh drops the tools, and an agent that names one is refused because the tool is not registered.

A server whose definition changes, or that is deleted or disabled, drops its tools at once; this setting only covers a failed listing of an unchanged server. TimeSpan.Zero drops them at the first failed listing. Must not be negative; a negative value fails at startup.