This commit is contained in:
vipg
2026-02-09 16:49:18 +08:00
parent 6640f09639
commit bdb1065217
6 changed files with 261 additions and 141 deletions

View File

@@ -0,0 +1,17 @@
package router
import (
"net/http"
"user/internal/handler"
)
func New(h *handler.Handler) http.Handler {
mux := http.NewServeMux()
mux.HandleFunc("/healthz", h.Healthz)
mux.HandleFunc("/version", h.Version)
mux.HandleFunc("/", h.Root)
mux.HandleFunc("/register", h.Register)
mux.HandleFunc("/login", h.Login)
return mux
}