f54c5ed54d
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
23 lines
684 B
C#
23 lines
684 B
C#
using Microsoft.Extensions.DependencyInjection;
|
|
using Microsoft.Extensions.Hosting;
|
|
using Microsoft.Extensions.Logging;
|
|
using MoneyMap.Core;
|
|
using MoneyMap.Mcp;
|
|
using MoneyMap.Services;
|
|
|
|
var builder = Host.CreateApplicationBuilder(args);
|
|
|
|
builder.Logging.ClearProviders();
|
|
builder.Logging.AddConsole(options => options.LogToStandardErrorThreshold = LogLevel.Trace);
|
|
|
|
builder.Services.AddMoneyMapCore(builder.Configuration);
|
|
builder.Services.AddSingleton<IReceiptStorageOptions, ConfigReceiptStorageOptions>();
|
|
|
|
builder.Services
|
|
.AddMcpServer()
|
|
.WithStdioServerTransport()
|
|
.WithToolsFromAssembly(typeof(Program).Assembly);
|
|
|
|
var app = builder.Build();
|
|
await app.RunAsync();
|