mirror of
https://github.com/bestnite/sub2clash.git
synced 2025-12-15 18:40:16 +00:00
feat: 解析短链
This commit is contained in:
14
api/route.go
14
api/route.go
@@ -53,14 +53,18 @@ func SetRoute(r *gin.Engine) {
|
||||
handler.SubHandler(c)
|
||||
},
|
||||
)
|
||||
r.POST(
|
||||
"/short", func(c *gin.Context) {
|
||||
handler.ShortLinkGenHandler(c)
|
||||
r.GET(
|
||||
"/s/:hash", func(c *gin.Context) {
|
||||
handler.ShortLinkGetConfigHandler(c)
|
||||
},
|
||||
)
|
||||
r.GET(
|
||||
"/s/:hash", func(c *gin.Context) {
|
||||
handler.ShortLinkGetHandler(c)
|
||||
"/short", func(c *gin.Context) {
|
||||
handler.ShortLinkGetUrlHandler(c)
|
||||
})
|
||||
r.POST(
|
||||
"/short", func(c *gin.Context) {
|
||||
handler.ShortLinkGenHandler(c)
|
||||
},
|
||||
)
|
||||
r.PUT(
|
||||
|
||||
Reference in New Issue
Block a user