Class GridWebMcpTools
Represents a collection of GridWebMcpTool components associated with a GridWebMcpSettings instance.
Inheritance
Inherited Members
Namespace: Syncfusion.Blazor.Grids
Assembly: Syncfusion.Blazor.Grids.dll
Syntax
public class GridWebMcpTools : SfDataBoundComponent, IComponent, IHandleEvent, IHandleAfterRender, IDisposable
Remarks
Use this component to declare one or more WebMCP tool definitions for an SfGrid<TValue> instance. Each child GridWebMcpTool can customize a built-in WebMCP tool or define a custom tool that can be invoked by compatible AI agents.
This component is intended to be declared within a GridWebMcpSettings component and serves as a logical container for related tool definitions.
The order in which tools are declared does not affect tool execution behavior.
Examples
<SfGrid DataSource="@Orders" EnableWebMcp="true"> <GridWebMcpSettings Name="SalesGrid"> <GridWebMcpTools> <GridWebMcpTool Command="GridWebMcpToolCommand.FilterByColumn" Name="filterOrders" />
<GridWebMcpTool
Name="getTopCustomers"
Description="Returns the top customers." />
</GridWebMcpTools>
</GridWebMcpSettings>
</SfGrid>
Constructors
GridWebMcpTools()
Declaration
public GridWebMcpTools()
Methods
BuildRenderTree(RenderTreeBuilder)
Declaration
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Parameters
| Type | Name | Description |
|---|---|---|
| RenderTreeBuilder | __builder |
Overrides
OnInitializedAsync()
Initializes the wrapper, captures the main parent reference, forwards the child Syncfusion.Blazor.Grids.GridWebMcpTools.Tools list to the parent GridWebMcpSettings via Syncfusion.Blazor.Grids.GridWebMcpSettings.AddTools(System.Collections.Generic.List{Syncfusion.Blazor.Grids.GridWebMcpTool}), and signals the grid to re-resolve its effective tool list on the next render.
Declaration
protected override Task OnInitializedAsync()
Returns
| Type |
|---|
| Task |