25 lines
450 B
C#
25 lines
450 B
C#
using Progress.Tools;
|
|
|
|
var builder = WebApplication.CreateBuilder(args);
|
|
|
|
// Add services to the container.
|
|
|
|
builder.Services.AddMcpServer()
|
|
.WithHttpTransport(options =>
|
|
{
|
|
options.Stateless = true;
|
|
})
|
|
.WithTools<LongRunningTools>();
|
|
|
|
builder.Logging.AddConsole(options =>
|
|
{
|
|
options.LogToStandardErrorThreshold = LogLevel.Information;
|
|
});
|
|
|
|
var app = builder.Build();
|
|
|
|
app.UseHttpsRedirection();
|
|
|
|
app.MapMcp();
|
|
|
|
app.Run();
|