.NET API
ToolDescriptor
Tracon.Abstractions.dllThe UI-facing definition of a tool registered in code. The agent editor shows a selection from this list; it does not accept free-text input.
public sealed record ToolDescriptor : IEquatable<ToolDescriptor>- Inheritance
- object ← ToolDescriptor
- Implements
- IEquatable<ToolDescriptor>
- Inherited Members
- object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Constructors
Section titled “Constructors”ToolDescriptor()
Section titled “ ToolDescriptor()”public ToolDescriptor()Properties
Section titled “Properties”Description
Section titled “ Description”The description that lets the model understand when to call the tool.
public string? Description { get; init; }Property Value
Section titled “Property Value”Effect
Section titled “ Effect”The tool’s effect class. Defaults to ToolEffect.Read.
public ToolEffect Effect { get; init; }Property Value
Section titled “Property Value”Remarks
Section titled “Remarks”Information, not a gate — see ToolEffect. An MCP-sourced tool defaults to ToolEffect.External instead: its definition lives on a remote server and can change, so the most cautious class is the honest default.
HostedKind
Section titled “ HostedKind”The kind of a hosted tool, or null for a tool Tracon calls.
public HostedToolKind? HostedKind { get; init; }Property Value
Section titled “Property Value”Remarks
Section titled “Remarks”A hosted tool (AddHostedTool) runs on the model provider’s side inside the model
call. Tracon puts no timeout, approval or permission in front of it, so
ToolDescriptor.RequiresApproval, ToolDescriptor.RequiredPermission and ToolDescriptor.Timeout
stay empty. The UI shows this field as a separate badge, and the provider’s
API surface decides whether the kind runs (the agent validation names a surface that
does not).
JsonSchema
Section titled “ JsonSchema”The arguments’ JSON schema.
public string? JsonSchema { get; init; }Property Value
Section titled “Property Value”MaxOutputBytes
Section titled “ MaxOutputBytes”The most bytes (UTF-8) this tool’s result may carry, or
null to use the installation default
(TraconOptions.Tools.DefaultMaxOutputBytes).
public int? MaxOutputBytes { get; init; }Property Value
Section titled “Property Value”int?
The tool name. Used in agent definitions.
public required string Name { get; init; }Property Value
Section titled “Property Value”RequiredPermission
Section titled “ RequiredPermission”The permission name a caller must hold to call this tool, or null when the tool declares none.
public string? RequiredPermission { get; init; }Property Value
Section titled “Property Value”Remarks
Section titled “Remarks”Passed to IToolAuthorizationHandler as-is; Tracon does not resolve or validate its meaning.
RequiresApproval
Section titled “ RequiresApproval”Whether explicit approval is required before the call.
public bool RequiresApproval { get; init; }Property Value
Section titled “Property Value”Remarks
Section titled “Remarks”If true, the compiler wraps the tool with
ApprovalRequiredAIFunction; Microsoft Agent Framework produces a
ToolApprovalRequestContent instead of running the tool, and the
call waits for the user’s approval. A code tool also reports
true when its function is already wrapped in
ApprovalRequiredAIFunction, whatever its registration says: the
framework asks for approval either way.
RunsOnClient
Section titled “ RunsOnClient”Whether the tool’s body runs on the caller (typically a browser) instead of on the server.
public bool RunsOnClient { get; init; }Property Value
Section titled “Property Value”Remarks
Section titled “Remarks”A client-side tool (AddClientTool) is registered as a
declaration only: the model can call it, but the server never runs
it. The caller must send the result back via
AgentRunRequest.ToolResults for the run to continue.
SafeToRepeat
Section titled “ SafeToRepeat”Whether this tool’s call may run again when an interrupted run is
continued. See TraconToolRegistration.SafeToRepeat.
public bool SafeToRepeat { get; init; }Property Value
Section titled “Property Value”Source
Section titled “ Source”The tool’s source. null for tools defined in code; the server name for tools coming from a remote MCP server.
public string? Source { get; init; }Property Value
Section titled “Property Value”Remarks
Section titled “Remarks”The UI shows this field as a separate badge: the tool definition lives not in code but on a remote server, and that server may change the definition.
Timeout
Section titled “ Timeout”The longest duration this tool’s call may run, or null
to use the installation default (TraconOptions.Tools.DefaultTimeout).
public TimeSpan? Timeout { get; init; }Property Value
Section titled “Property Value”Methods
Section titled “Methods”Equals(object?)
Section titled “ Equals(object?)”public override bool Equals(object? obj)Parameters
Section titled “Parameters”obj object?
Returns
Section titled “Returns”Equals(ToolDescriptor?)
Section titled “ Equals(ToolDescriptor?)”public bool Equals(ToolDescriptor? other)Parameters
Section titled “Parameters”other ToolDescriptor?
Returns
Section titled “Returns”GetHashCode()
Section titled “ GetHashCode()”public override int GetHashCode()Returns
Section titled “Returns”ToString()
Section titled “ ToString()”public override string ToString()Returns
Section titled “Returns”Operators
Section titled “Operators”operator ==(ToolDescriptor?, ToolDescriptor?)
Section titled “ operator ==(ToolDescriptor?, ToolDescriptor?)”public static bool operator ==(ToolDescriptor? left, ToolDescriptor? right)Parameters
Section titled “Parameters”left ToolDescriptor?
right ToolDescriptor?
Returns
Section titled “Returns”operator !=(ToolDescriptor?, ToolDescriptor?)
Section titled “ operator !=(ToolDescriptor?, ToolDescriptor?)”public static bool operator !=(ToolDescriptor? left, ToolDescriptor? right)Parameters
Section titled “Parameters”left ToolDescriptor?
right ToolDescriptor?