feat: Add MCP inventory management tools

Add comprehensive MCP tools for inventory management:
- list_suppliers, add_supplier
- list_materials, add_material, search_materials
- list_stock_items, add_stock_item
- list_supplier_offerings, add_supplier_offering
- add_stock_with_offering (convenience method)

Features:
- Dimension-based material search with tolerance
- Auto-generate size strings from dimensions
- Parse size strings to typed dimensions
- Type/Grade support for material categorization

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-02-04 23:38:27 -05:00
parent 0e5b63c557
commit c9a2583f26
3 changed files with 1106 additions and 0 deletions

View File

@@ -2,6 +2,7 @@
<ItemGroup>
<ProjectReference Include="..\CutList.Core\CutList.Core.csproj" />
<ProjectReference Include="..\CutList.Web\CutList.Web.csproj" />
</ItemGroup>
<ItemGroup>

File diff suppressed because it is too large Load Diff

View File

@@ -1,9 +1,15 @@
using CutList.Web.Data;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using ModelContextProtocol.Server;
var builder = Host.CreateApplicationBuilder(args);
// Add DbContext for inventory tools
builder.Services.AddDbContext<ApplicationDbContext>(options =>
options.UseSqlServer("Server=(localdb)\\mssqllocaldb;Database=CutListDb;Trusted_Connection=True;MultipleActiveResultSets=true"));
builder.Services
.AddMcpServer()
.WithStdioServerTransport()