// clusters.go — /api/clusters/* handler。 // // **Phase 0 / B5 範圍很窄**(對齊 PM 對「叢集推論」Phase 1 才做深入的裁決): // - GET /api/clusters 回空陣列,讓前端能完成基本渲染 // - 其他 endpoint 保持 501(由 stubs.go 負責) // // 詳細規格見 api-spec.md §5。 package api import ( "net/http" "github.com/gin-gonic/gin" ) // registerClusterRoutes 註冊 /api/clusters 的「雛形可呼叫」endpoint。 // // 目前只有 GET /api/clusters 回空陣列;其他 endpoint 的 stub 由 stubs.go 註冊 // (本 function 只覆寫需要有 body 的那一條,避免衝突)。 func registerClusterRoutes(g *gin.RouterGroup, _ Deps) { g.GET("/clusters", func(c *gin.Context) { WriteSuccess(c, http.StatusOK, []any{}) }) }