LANCommander/LANCommander.Server/Startup/Endpoints.cs
Pat Hartl 819cb28d17 Packager app improvements, metadata endpoints
- Add ability to connect to server
- Add uploading of finished package to server
- Add metadata lookup when connected to server
- Fix layout when specifying action
- Hide finish button at generate step
2026-06-03 19:43:45 -05:00

50 lines
No EOL
1.7 KiB
C#

using LANCommander.Server.Endpoints;
namespace LANCommander.Server.Startup;
public static class Endpoints
{
public static void AddControllers(this WebApplicationBuilder builder)
{
builder.Services.AddControllers().AddJsonOptions(static x =>
{
x.JsonSerializerOptions.ReferenceHandler = System.Text.Json.Serialization.ReferenceHandler.IgnoreCycles;
});
}
public static WebApplication MapEndpoints(this WebApplication app)
{
app.UseEndpoints(endpoints =>
{
endpoints.MapAuthenticationEndpoints();
endpoints.MapAuthApiEndpoints();
endpoints.MapChatEndpoints();
endpoints.MapDownloadEndpoints();
endpoints.MapExportEndpoints();
endpoints.MapGameEndpoints();
endpoints.MapDepotEndpoints();
endpoints.MapArchivesEndpoints();
endpoints.MapUploadEndpoints();
endpoints.MapProfileEndpoints();
endpoints.MapPlaySessionsEndpoints();
endpoints.MapMediaEndpoints();
endpoints.MapKeysEndpoints();
endpoints.MapLauncherEndpoints();
endpoints.MapLibraryEndpoints();
endpoints.MapRedistributablesEndpoints();
endpoints.MapToolsEndpoints();
endpoints.MapIssueEndpoints();
endpoints.MapSaveEndpoints();
endpoints.MapServerEndpoints();
endpoints.MapSettingsEndpoints();
endpoints.MapLogEndpoints();
endpoints.MapHqEndpoints();
endpoints.MapMetadataEndpoints();
endpoints.MapTagEndpoints();
endpoints.MapControllers();
endpoints.MapFallbackToPage("/_Host");
});
return app;
}
}