.NET API
TraconClientToolExtensions
Tracon.Core.dllRegisters a client-side tool: its declaration (name, description, JSON schema) lives in code, like every other tool (the code-only tools rule), but its body runs on the caller instead of on the server.
public static class TraconClientToolExtensionsInheritance
Section titled “Inheritance”object ← TraconClientToolExtensions
Inherited Members
Section titled “Inherited Members”object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Methods
Section titled “Methods”AddClientTool(ITraconBuilder, string, string, JsonElement)
Section titled “ AddClientTool(ITraconBuilder, string, string, JsonElement)”Registers a tool whose body the server never runs.
public static ITraconBuilder AddClientTool(this ITraconBuilder builder, string name, string description, JsonElement jsonSchema)Parameters
Section titled “Parameters”builder ITraconBuilder
The Tracon configuration chain.
name string
The tool name. Must be unique among all registered tools.
description string
The description that lets the model understand when to call the tool.
jsonSchema JsonElement
The arguments’ JSON schema.
Returns
Section titled “Returns”The chain, for further configuration.
Remarks
Section titled “Remarks”The model can call the tool, but the server produces a
FunctionCallContent and returns it to the caller instead of
running anything — Microsoft Agent Framework’s
FunctionInvokingChatClient only invokes an AIFunction;
a declaration-only AIFunctionDeclaration is not one. The
caller (typically a browser) runs the tool itself and sends the
result back via AgentRunRequest.ToolResults
(Tracon.AspNetCore) to let the turn continue.
A client-side tool cannot require approval — there is no server-side body to defer. Tracon.ToolRegistry rejects that combination at startup if attempted through a direct TraconToolRegistration registration.
var schema = JsonSerializer.Deserialize<JsonElement>( """{"type":"object","properties":{"path":{"type":"string"}}}""");
builder.AddTracon() .AddClientTool("open_page", "Opens a page in the user's browser.", schema);Exceptions
Section titled “Exceptions”builder is null.
name or description is empty.