mirror of
https://github.com/Rain-kl/OpenFlare.git
synced 2026-10-12 18:26:36 +08:00
refactor(api): unify routes under /api/v1/d, agent, relay, tunnel
Remove the /openflare prefix from management APIs (/api/v1/d/*) and move Agent, Relay, and Tunnel protocol endpoints under /api/v1. Update Wavelet frontend services and node client binaries to match.
This commit is contained in:
@@ -2,15 +2,15 @@
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
// Package openflare registers OpenFlare HTTP routes.
|
||||
// Management console APIs are mounted via RegisterV1Routes under /api/v1/openflare.
|
||||
// Agent/Relay/Flared protocol routes are mounted via RegisterRoutes under /api.
|
||||
// Management console APIs are mounted via RegisterV1Routes under /api/v1/d.
|
||||
// Agent/Relay/Tunnel protocol routes are mounted via RegisterRoutes under /api/v1.
|
||||
package openflare
|
||||
|
||||
import "github.com/gin-gonic/gin"
|
||||
|
||||
// RegisterRoutes mounts Agent/Relay/Flared protocol routes under the /api group.
|
||||
func RegisterRoutes(apiGroup *gin.RouterGroup) {
|
||||
registerAgentRoutes(apiGroup)
|
||||
registerRelayRoutes(apiGroup)
|
||||
registerFlaredRoutes(apiGroup)
|
||||
// RegisterRoutes mounts Agent/Relay/Tunnel protocol routes under the /api/v1 group.
|
||||
func RegisterRoutes(apiV1Router *gin.RouterGroup) {
|
||||
registerAgentRoutes(apiV1Router)
|
||||
registerRelayRoutes(apiV1Router)
|
||||
registerTunnelRoutes(apiV1Router)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user