Skip to content

Get up and running with Kimi, GLM, MiniMax, DeepSeek, gpt-oss, Qwen, Gemma and other models.

server: add version handler

Michael Yang1ebdbd9694de
diff --git a/server/routes.go b/server/routes.go
index bc8ea8043..42203cb61 100644
--- a/server/routes.go
+++ b/server/routes.go
@@ -782,6 +782,9 @@ func Serve(ln net.Listener, allowOrigins []string) error {
})
r.Handle(method, "/api/tags", ListModelsHandler)
+ r.Handle(method, "/api/version", func(c *gin.Context) {
+ c.JSON(http.StatusOK, gin.H{"version": version.Version})
+ })
}
log.Printf("Listening on %s (version %s)", ln.Addr(), version.Version)