1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-03 00:52:49 -05:00

Standardize '/version' endpoint on all services (#1755)

This commit is contained in:
Vince Grassia
2021-12-09 15:45:45 -05:00
committed by GitHub
parent d3673cdc85
commit 2ec10cfd2a
18 changed files with 201 additions and 130 deletions

View File

@ -49,7 +49,12 @@ namespace Bit.EventsProcessor
app.UseEndpoints(endpoints =>
{
endpoints.MapGet("/alive",
async context => await context.Response.WriteAsync(System.DateTime.UtcNow.ToString()));
async context => await context.Response.WriteAsJsonAsync(System.DateTime.UtcNow));
endpoints.MapGet("/now",
async context => await context.Response.WriteAsJsonAsync(System.DateTime.UtcNow));
endpoints.MapGet("/version",
async context => await context.Response.WriteAsJsonAsync(CoreHelpers.GetVersion()));
});
}
}