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

# ODataMcpOptions

> Configuration options for OData MCP integration.

export function DocsBadge({text, variant = 'neutral'}) {
  const variantClasses = {
    success: 'mint-bg-green-500/10 mint-text-green-600 dark:mint-text-green-400 mint-border-green-500/20',
    neutral: 'mint-bg-slate-500/10 mint-text-slate-600 dark:mint-text-slate-400 mint-border-slate-500/20',
    info: 'mint-bg-blue-500/10 mint-text-blue-600 dark:mint-text-blue-400 mint-border-blue-500/20',
    warning: 'mint-bg-amber-500/10 mint-text-amber-600 dark:mint-text-amber-400 mint-border-amber-500/20',
    danger: 'mint-bg-red-500/10 mint-text-red-600 dark:mint-text-red-400 mint-border-red-500/20'
  };
  const classes = variantClasses[variant] || variantClasses.neutral;
  return <span className={`mint-inline-flex mint-items-center mint-px-2 mint-py-0.5 mint-rounded-full mint-text-xs mint-font-medium mint-tracking-wide mint-border mint-ml-1.5 mint-align-middle mint-whitespace-nowrap ${classes}`}>
      {text}
    </span>;
}

## Definition

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

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

**Inheritance:** System.Object

## Syntax

```csharp theme={"dark"}
Microsoft.OData.Mcp.Core.ODataMcpOptions
```

## Summary

Configuration options for OData MCP integration.

## Constructors

### <Icon icon="hammer" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  .ctor

#### Syntax

```csharp theme={"dark"}
public ODataMcpOptions()
```

### <Icon icon="hammer" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  .ctor <DocsBadge text="Inherited" variant="neutral" />

<Note>Inherited from `object`</Note>

#### Syntax

```csharp theme={"dark"}
public Object()
```

## Properties

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  AllowedOrigins

Gets or sets the allowed CORS origins.

#### Syntax

```csharp theme={"dark"}
public string[] AllowedOrigins { get; set; }
```

#### Property Value

Type: `string[]`
An array of allowed origins. Default allows all origins ("\*").

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  AutoDiscoverMetadata

Gets or sets whether to auto-discover metadata.

#### Syntax

```csharp theme={"dark"}
public bool AutoDiscoverMetadata { get; set; }
```

#### Property Value

Type: `bool`
`true` to auto-discover metadata; otherwise, `false`.
Default is `true`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  AutoRegisterRoutes

Gets or sets a value indicating whether to automatically register MCP endpoints
for all OData routes.

#### Syntax

```csharp theme={"dark"}
public bool AutoRegisterRoutes { get; set; }
```

#### Property Value

Type: `bool`
`true` to automatically register MCP endpoints; otherwise, `false`.
Default is `true`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  BasePath

Gets or sets the base path for MCP endpoints.

#### Syntax

```csharp theme={"dark"}
public string BasePath { get; set; }
```

#### Property Value

Type: `string`
The base path for MCP endpoints. Default is "/mcp".

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  CacheDuration

Gets or sets the cache duration for dynamic content.

#### Syntax

```csharp theme={"dark"}
public System.TimeSpan CacheDuration { get; set; }
```

#### Property Value

Type: `System.TimeSpan`
The duration to cache dynamic content. Default is 5 minutes.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  DefaultPageSize

Gets or sets the default page size for query operations.

#### Syntax

```csharp theme={"dark"}
public int DefaultPageSize { get; set; }
```

#### Property Value

Type: `int`
The default page size. Default is 100.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  EnableCaching

Gets or sets whether to enable caching.

#### Syntax

```csharp theme={"dark"}
public bool EnableCaching { get; set; }
```

#### Property Value

Type: `bool`
`true` to enable caching; otherwise, `false`.
Default is `true`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  EnableCors

Gets or sets a value indicating whether to enable CORS for MCP endpoints.

#### Syntax

```csharp theme={"dark"}
public bool EnableCors { get; set; }
```

#### Property Value

Type: `bool`
`true` to enable CORS; otherwise, `false`.
Default is `true`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  Enabled

Gets or sets whether to enable MCP endpoints.

#### Syntax

```csharp theme={"dark"}
public bool Enabled { get; set; }
```

#### Property Value

Type: `bool`
`true` to enable MCP endpoints; otherwise, `false`.
Default is `true`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  EnableDetailedErrors

Gets or sets whether to enable detailed error messages.

#### Syntax

```csharp theme={"dark"}
public bool EnableDetailedErrors { get; set; }
```

#### Property Value

Type: `bool`
`true` to enable detailed error messages; otherwise, `false`.
Default is `false`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  EnableDynamicModels

Gets or sets a value indicating whether to enable dynamic model updates.

#### Syntax

```csharp theme={"dark"}
public bool EnableDynamicModels { get; set; }
```

#### Property Value

Type: `bool`
`true` to enable dynamic models; otherwise, `false`.
Default is `false` for performance.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  EnableRequestLogging

Gets or sets a value indicating whether to enable request logging.

#### Syntax

```csharp theme={"dark"}
public bool EnableRequestLogging { get; set; }
```

#### Property Value

Type: `bool`
`true` to enable detailed request logging; otherwise, `false`.
Default is `false`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  ExcludeRoutes

Gets or sets the routes to exclude from automatic MCP registration.

#### Syntax

```csharp theme={"dark"}
public string[] ExcludeRoutes { get; set; }
```

#### Property Value

Type: `string[]`
An array of route names to exclude. Default is an empty array.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  IncludeMetadata

Gets or sets a value indicating whether to include metadata in tool descriptions.

#### Syntax

```csharp theme={"dark"}
public bool IncludeMetadata { get; set; }
```

#### Property Value

Type: `bool`
`true` to include detailed metadata; otherwise, `false`.
Default is `true`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  MaxPageSize

Gets or sets the maximum page size for query operations.

#### Syntax

```csharp theme={"dark"}
public int MaxPageSize { get; set; }
```

#### Property Value

Type: `int`
The maximum page size. Default is 1000.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  MaxRequestSize

Gets or sets the maximum request size for tool execution.

#### Syntax

```csharp theme={"dark"}
public long MaxRequestSize { get; set; }
```

#### Property Value

Type: `long`
The maximum request size in bytes. Default is 1MB (1,048,576 bytes).

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  MaxToolsPerEntity

Gets or sets the maximum number of tools to generate per entity.

#### Syntax

```csharp theme={"dark"}
public System.Nullable<int> MaxToolsPerEntity { get; set; }
```

#### Property Value

Type: `System.Nullable<int>`
The maximum number of tools per entity, or `null` for unlimited.
Default is `null`.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  ModelRefreshInterval

Gets or sets the interval for refreshing dynamic models.

#### Syntax

```csharp theme={"dark"}
public System.TimeSpan ModelRefreshInterval { get; set; }
```

#### Property Value

Type: `System.TimeSpan`
The interval for refreshing dynamic models. Default is 1 hour.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  RequestTimeout

Gets or sets the request timeout.

#### Syntax

```csharp theme={"dark"}
public System.TimeSpan RequestTimeout { get; set; }
```

#### Property Value

Type: `System.TimeSpan`
The request timeout. Default is 2 minutes.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  ToolNamingPattern

Gets or sets the tool naming pattern.

#### Syntax

```csharp theme={"dark"}
public string ToolNamingPattern { get; set; }
```

#### Property Value

Type: `string`
The pattern for generating tool names. Default is "{route}.{entity}.{operation}".
Available placeholders: {route}, {entity}, {operation}.

### <Icon icon="tag" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  UseAggressiveCaching

Gets or sets a value indicating whether to use aggressive caching.

#### Syntax

```csharp theme={"dark"}
public bool UseAggressiveCaching { get; set; }
```

#### Property Value

Type: `bool`
`true` to use aggressive caching with ETags and long expiration;
otherwise, `false`. Default is `true`.

## Methods

### <Icon icon="code-fork" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  Equals <DocsBadge text="Inherited" variant="neutral" /> <DocsBadge text="Virtual" variant="warning" />

<Note>Inherited from `object`</Note>

#### Syntax

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

#### Parameters

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

#### Returns

Type: `bool`

### <Icon icon="thumbtack" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  Equals <DocsBadge text="Inherited" variant="neutral" />

<Note>Inherited from `object`</Note>

#### Syntax

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

#### Parameters

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

#### Returns

Type: `bool`

### <Icon icon="code-fork" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  GetHashCode <DocsBadge text="Inherited" variant="neutral" /> <DocsBadge text="Virtual" variant="warning" />

<Note>Inherited from `object`</Note>

#### Syntax

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

#### Returns

Type: `int`

### <Icon icon="function" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  GetType <DocsBadge text="Inherited" variant="neutral" />

<Note>Inherited from `object`</Note>

#### Syntax

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

#### Returns

Type: `System.Type`

### <Icon icon="function" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  MemberwiseClone <DocsBadge text="Inherited" variant="neutral" />

<Note>Inherited from `object`</Note>

#### Syntax

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

#### Returns

Type: `object`

### <Icon icon="thumbtack" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  ReferenceEquals <DocsBadge text="Inherited" variant="neutral" />

<Note>Inherited from `object`</Note>

#### Syntax

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

#### Parameters

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

#### Returns

Type: `bool`

### <Icon icon="code-fork" iconType="duotone" color="#419AC5" size={24} style={{ paddingRight: '8px' }} />  ToString <DocsBadge text="Inherited" variant="neutral" /> <DocsBadge text="Virtual" variant="warning" />

<Note>Inherited from `object`</Note>

#### Syntax

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

#### Returns

Type: `string?`
