> ## Documentation Index
> Fetch the complete documentation index at: https://ai.easyaf.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# ODataToolInvocationResult

> The result of invoking a catalog tool.

## Definition

**Assembly:** Microsoft.OData.Mcp.Core.dll

**Namespace:** Microsoft.OData.Mcp.Core.Catalog

**Inheritance:** System.Object

## Syntax

```csharp theme={null}
Microsoft.OData.Mcp.Core.Catalog.ODataToolInvocationResult
```

## Summary

The result of invoking a catalog tool.

## Constructors

### &#x20;.ctor

#### Syntax

```csharp theme={null}
public ODataToolInvocationResult()
```

### &#x20;.ctor Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={null}
public Object()
```

## Properties

### &#x20;IsError

Gets or sets a value indicating whether the tool failed.

#### Syntax

```csharp theme={null}
public bool IsError { get; set; }
```

#### Property Value

Type: `bool`

### &#x20;StructuredContent

Gets or sets structured JSON. Catalog tools set this as text. OData success keeps
[ODataToolInvocationResult.StructuredStream](https://ai.easyaf.dev/odata-mcp/api-reference/Microsoft/OData/Mcp/Core/Catalog/ODataToolInvocationResult.md#structuredstream) and materializes this string on first read.

#### Syntax

```csharp theme={null}
public string StructuredContent { get; set; }
```

#### Property Value

Type: `string?`

### &#x20;StructuredStream

Gets or sets the OData JSON stream as written, when the executor kept it.

#### Syntax

```csharp theme={null}
public System.IO.Stream StructuredStream { get; set; }
```

#### Property Value

Type: `System.IO.Stream?`

### &#x20;Text

Gets or sets the text content returned to the client.

#### Syntax

```csharp theme={null}
public string Text { get; set; }
```

#### Property Value

Type: `string`

## Methods

### &#x20;Equals Inherited Virtual

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={null}
public virtual bool Equals(object obj)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `obj` | `object?` | - |

#### Returns

Type: `bool`

### &#x20;Equals Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={null}
public static bool Equals(object objA, object objB)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `objA` | `object?` | - |
| `objB` | `object?` | - |

#### Returns

Type: `bool`

### &#x20;GetHashCode Inherited Virtual

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={null}
public virtual int GetHashCode()
```

#### Returns

Type: `int`

### &#x20;GetType Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={null}
public System.Type GetType()
```

#### Returns

Type: `System.Type`

### &#x20;MemberwiseClone Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={null}
protected internal object MemberwiseClone()
```

#### Returns

Type: `object`

### &#x20;ReferenceEquals Inherited

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={null}
public static bool ReferenceEquals(object objA, object objB)
```

#### Parameters

| Name | Type | Description |
| - | - | - |
| `objA` | `object?` | - |
| `objB` | `object?` | - |

#### Returns

Type: `bool`

### &#x20;ToString Inherited Virtual

> [!NOTE]
>
> Inherited from `object`

#### Syntax

```csharp theme={null}
public virtual string ToString()
```

#### Returns

Type: `string?`

### &#x20;ToStructuredContent

Returns structured JSON for `CallToolResult.StructuredContent`. Prefers the OData stream
(UTF-8 parse, no string copy). Falls back to [ODataToolInvocationResult.StructuredContent](https://ai.easyaf.dev/odata-mcp/api-reference/Microsoft/OData/Mcp/Core/Catalog/ODataToolInvocationResult.md#structuredcontent).

#### Syntax

```csharp theme={null}
public System.Nullable<System.Text.Json.JsonElement> ToStructuredContent()
```

#### Returns

Type: `System.Nullable<System.Text.Json.JsonElement?>?`
The JSON element, or [`null`](https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null) when there is no structured payload.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.