Skip to content

Commit 8183af5

Browse files
committed
Add healthcheck endpoint
1 parent 1846038 commit 8183af5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

main.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ func main() {
102102
app.Post("/api/v1/control-relay", AuthMiddleware, handleControlRelay)
103103
app.Get("/api/v1/spaceapi", handleSpaceAPI)
104104
app.Get("/api/v1/branding", handleBranding)
105+
app.Get("/health", handleHealth)
105106
app.Get("/api/v1/device-history", handleDeviceHistory)
106107
app.Get("/api/v1/stats/usage-heatmap", handleUsageHeatmap)
107108

@@ -217,3 +218,7 @@ func handleBranding(c *fiber.Ctx) error {
217218
cfg := MustLoadConfig()
218219
return c.JSON(cfg.Branding)
219220
}
221+
222+
func handleHealth(c *fiber.Ctx) error {
223+
return c.SendString("OK")
224+
}

0 commit comments

Comments
 (0)