Files
gongzhiyong 1f21309597 refactor: rename manager codebase dir new-api → heicode, module github.com/heicode/manager
Remove user-facing new-api naming; Docker/network/container names use heicode.
Go imports updated; Dockerfiles and workflows ldflags fixed.

Made-with: Cursor
2026-05-01 01:47:23 +08:00

22 lines
601 B
Go

package router
import (
"github.com/heicode/manager/controller"
"github.com/gin-gonic/gin"
)
// SetHeicodeOAuthRouter wires up HeiCode-specific browser-login bridge endpoints.
// These endpoints are mounted at /heicode/* (no /api prefix) so the redirect_uri
// from HeiCode desktop matches: http(s)://<heicode-host>/heicode/oauth/authorize.
func SetHeicodeOAuthRouter(router *gin.Engine) {
heicode := router.Group("/heicode")
{
oauth := heicode.Group("/oauth")
{
oauth.GET("/authorize", controller.HeicodeOAuthAuthorize)
oauth.GET("/session", controller.HeicodeOAuthSession)
}
}
}