# ClientToolResult

> Tracon documentation. Tracon is a .NET package family that adds a control
> plane on Microsoft Agent Framework, published as NuGet packages that run
> inside your own ASP.NET Core application.
>
> Page: https://tracon.dev/api/tracon.clienttoolresult/
> Summary: ClientToolResult: The result of a single client-side tool call, sent back so the run can continue.

<div class="api-provenance">Namespace Tracon · Assembly <code>Tracon.AspNetCore.dll</code></div>

The result of a single client-side tool call, sent back so the run can
continue.

```csharp
public sealed record ClientToolResult : IEquatable<ClientToolResult>
```

<dl class="api-relations"><dt>Inheritance</dt><dd><a href="https://learn.microsoft.com/dotnet/api/system.object">object</a> ← <a href="/api/tracon.clienttoolresult/">ClientToolResult</a></dd><dt>Implements</dt><dd><a href="https://learn.microsoft.com/dotnet/api/system.iequatable-1">IEquatable&lt;ClientToolResult&gt;</a></dd><dt>Inherited Members</dt><dd><a href="https://learn.microsoft.com/dotnet/api/system.object.gettype">object.GetType()</a>, <a href="https://learn.microsoft.com/dotnet/api/system.object.tostring">object.ToString()</a>, <a href="https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals(system-object)">object.Equals(object?)</a>, <a href="https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals(system-object-system-object)">object.Equals(object?, object?)</a>, <a href="https://learn.microsoft.com/dotnet/api/system.object.referenceequals">object.ReferenceEquals(object?, object?)</a>, <a href="https://learn.microsoft.com/dotnet/api/system.object.gethashcode">object.GetHashCode()</a></dd></dl>

## Remarks

[TraconClientToolExtensions.AddClientTool](/api/tracon.traconclienttoolextensions/#Tracon_TraconClientToolExtensions_AddClientTool_Tracon_ITraconBuilder_System_String_System_String_System_Text_Json_JsonElement_)'s sibling on
the run request: the model calls a client-side tool, the server returns
the pending call to the caller instead of running it, and the caller
sends the outcome back through this contract.

## Constructors

### <a id="Tracon_ClientToolResult__ctor"></a> ClientToolResult\(\)

```csharp
public ClientToolResult()
```

## Properties

### <a id="Tracon_ClientToolResult_CallId"></a> CallId

Identifier of the pending call this result answers. Matches the
`FunctionCallContent.CallId` the run response carried.

```csharp
public required string CallId { get; init; }
```

#### Property Value

 [string](https://learn.microsoft.com/dotnet/api/system.string)

### <a id="Tracon_ClientToolResult_ErrorMessage"></a> ErrorMessage

A message describing why the client-side call failed, given to the
model instead of `Result`.

```csharp
public string? ErrorMessage { get; init; }
```

#### Property Value

 [string](https://learn.microsoft.com/dotnet/api/system.string)?

#### Remarks

A client-side tool can fail for reasons the server never sees — the
user denied a browser permission, a DOM element was not found. The
failure is reported to the model as ordinary tool output, not as an
HTTP error: the run continues and the model can recover (retry,
explain, ask a follow-up).

### <a id="Tracon_ClientToolResult_Result"></a> Result

The tool's result, given to the model as plain text. Required unless
`ErrorMessage` is given.

```csharp
public string? Result { get; init; }
```

#### Property Value

 [string](https://learn.microsoft.com/dotnet/api/system.string)?

## Methods

### <a id="Tracon_ClientToolResult_Equals_System_Object_"></a> Equals\(object?\)

```csharp
public override bool Equals(object? obj)
```

#### Parameters

`obj` [object](https://learn.microsoft.com/dotnet/api/system.object)?

#### Returns

 [bool](https://learn.microsoft.com/dotnet/api/system.boolean)

### <a id="Tracon_ClientToolResult_Equals_Tracon_ClientToolResult_"></a> Equals\(ClientToolResult?\)

```csharp
public bool Equals(ClientToolResult? other)
```

#### Parameters

`other` [ClientToolResult](/api/tracon.clienttoolresult/)?

#### Returns

 [bool](https://learn.microsoft.com/dotnet/api/system.boolean)

### <a id="Tracon_ClientToolResult_GetHashCode"></a> GetHashCode\(\)

```csharp
public override int GetHashCode()
```

#### Returns

 [int](https://learn.microsoft.com/dotnet/api/system.int32)

### <a id="Tracon_ClientToolResult_ToString"></a> ToString\(\)

```csharp
public override string ToString()
```

#### Returns

 [string](https://learn.microsoft.com/dotnet/api/system.string)

## Operators

### <a id="Tracon_ClientToolResult_op_Equality_Tracon_ClientToolResult_Tracon_ClientToolResult_"></a> operator ==\(ClientToolResult?, ClientToolResult?\)

```csharp
public static bool operator ==(ClientToolResult? left, ClientToolResult? right)
```

#### Parameters

`left` [ClientToolResult](/api/tracon.clienttoolresult/)?

`right` [ClientToolResult](/api/tracon.clienttoolresult/)?

#### Returns

 [bool](https://learn.microsoft.com/dotnet/api/system.boolean)

### <a id="Tracon_ClientToolResult_op_Inequality_Tracon_ClientToolResult_Tracon_ClientToolResult_"></a> operator \!=\(ClientToolResult?, ClientToolResult?\)

```csharp
public static bool operator !=(ClientToolResult? left, ClientToolResult? right)
```

#### Parameters

`left` [ClientToolResult](/api/tracon.clienttoolresult/)?

`right` [ClientToolResult](/api/tracon.clienttoolresult/)?

#### Returns

 [bool](https://learn.microsoft.com/dotnet/api/system.boolean)
