Documentation Index
Fetch the complete documentation index at: https://easyaf.dev/llms.txt
Use this file to discover all available pages before exploring further.
Definition
Assembly: Microsoft.AspNetCore.Routing.dll Namespace: Microsoft.AspNetCore.RoutingSyntax
Summary
This type is defined in Microsoft.AspNetCore.Routing.Remarks
See Microsoft documentation for more information about the rest of the API.Methods
AddMcp Extension
Extension method from
Microsoft.AspNetCore.Routing.ODataMcp_AspNetCore_RouteBuilderExtensionsSyntax
Parameters
| Name | Type | Description |
|---|---|---|
routeBuilder | Microsoft.AspNetCore.Routing.IRouteBuilder | The route builder. |
Returns
Type:Microsoft.AspNetCore.Routing.IRouteBuilder
The route builder for chaining.
Examples
Remarks
This method adds MCP endpoints as siblings to the OData $metadata endpoint. For example, if the OData route is “api/v1”, the MCP endpoints will be at “api/v1/mcp”.AddMcp Extension
Extension method from
Microsoft.AspNetCore.Routing.ODataMcp_AspNetCore_RouteBuilderExtensionsSyntax
Parameters
| Name | Type | Description |
|---|---|---|
routeBuilder | Microsoft.AspNetCore.Routing.IRouteBuilder | The route builder. |
customPath | string? | The custom MCP path, or null to use the default. |
Returns
Type:Microsoft.AspNetCore.Routing.IRouteBuilder
The route builder for chaining.
Exceptions
| Exception | Description |
|---|---|
ArgumentNullException | Thrown when routeBuilder is null. |