WutheringWaves/SDKServer/Program.cs

28 lines
1,001 B
C#
Raw Normal View History

2024-02-18 16:50:34 +00:00
using Microsoft.AspNetCore.Builder;
2024-02-07 21:41:39 +00:00
using SDKServer.Handlers;
using SDKServer.Middleware;
namespace SDKServer;
internal static class Program
{
private static async Task Main(string[] args)
{
var builder = WebApplication.CreateBuilder(args);
builder.WebHost.UseUrls("http://*:5500");
builder.Logging.AddSimpleConsole();
var app = builder.Build();
app.UseMiddleware<NotFoundMiddleware>();
app.MapGet("/api/login", LoginHandler.Login);
2024-02-18 16:50:34 +00:00
app.MapGet("/index.json", ConfigHandler.GetBaseConfig);
2024-02-07 21:41:39 +00:00
2024-02-18 16:50:34 +00:00
app.MapGet("/dev/client/mtZyW6ZYIu1pE0TCHUbXcM1oU8vx4hnb/Windows/KeyList_0.9.0.json", HotPatchHandler.OnKeyListRequest);
app.MapGet("/dev/client/mtZyW6ZYIu1pE0TCHUbXcM1oU8vx4hnb/Windows/config.json", HotPatchHandler.OnConfigRequest);
app.MapGet("/dev/client/mtZyW6ZYIu1pE0TCHUbXcM1oU8vx4hnb/Windows/client_key/0.9.0/CtBIsHPiwhwOqqBYxj/PakData", HotPatchHandler.OnPakDataRequest);
2024-02-07 21:41:39 +00:00
await app.RunAsync();
}
}