Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
new-api
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
ae74423c
authored
Nov 11, 2025
by
Calcium-Ion
Committed by
GitHub
Nov 11, 2025
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2208 from seefs001/fix/get-channel-key
fix GetChannelKey AdminAuth -> RootAuth
parents
ae8b09d4
31d0e697
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
1 deletions
+1
-1
router/api-router.go
+1
-1
No files found.
router/api-router.go
View file @
ae74423c
...
@@ -126,6 +126,7 @@ func SetApiRouter(router *gin.Engine) {
...
@@ -126,6 +126,7 @@ func SetApiRouter(router *gin.Engine) {
{
{
ratioSyncRoute
.
GET
(
"/channels"
,
controller
.
GetSyncableChannels
)
ratioSyncRoute
.
GET
(
"/channels"
,
controller
.
GetSyncableChannels
)
ratioSyncRoute
.
POST
(
"/fetch"
,
controller
.
FetchUpstreamRatios
)
ratioSyncRoute
.
POST
(
"/fetch"
,
controller
.
FetchUpstreamRatios
)
ratioSyncRoute
.
POST
(
"/:id/key"
,
middleware
.
CriticalRateLimit
(),
middleware
.
DisableCache
(),
middleware
.
SecureVerificationRequired
(),
controller
.
GetChannelKey
)
}
}
channelRoute
:=
apiRouter
.
Group
(
"/channel"
)
channelRoute
:=
apiRouter
.
Group
(
"/channel"
)
channelRoute
.
Use
(
middleware
.
AdminAuth
())
channelRoute
.
Use
(
middleware
.
AdminAuth
())
...
@@ -135,7 +136,6 @@ func SetApiRouter(router *gin.Engine) {
...
@@ -135,7 +136,6 @@ func SetApiRouter(router *gin.Engine) {
channelRoute
.
GET
(
"/models"
,
controller
.
ChannelListModels
)
channelRoute
.
GET
(
"/models"
,
controller
.
ChannelListModels
)
channelRoute
.
GET
(
"/models_enabled"
,
controller
.
EnabledListModels
)
channelRoute
.
GET
(
"/models_enabled"
,
controller
.
EnabledListModels
)
channelRoute
.
GET
(
"/:id"
,
controller
.
GetChannel
)
channelRoute
.
GET
(
"/:id"
,
controller
.
GetChannel
)
channelRoute
.
POST
(
"/:id/key"
,
middleware
.
CriticalRateLimit
(),
middleware
.
DisableCache
(),
middleware
.
SecureVerificationRequired
(),
controller
.
GetChannelKey
)
channelRoute
.
GET
(
"/test"
,
controller
.
TestAllChannels
)
channelRoute
.
GET
(
"/test"
,
controller
.
TestAllChannels
)
channelRoute
.
GET
(
"/test/:id"
,
controller
.
TestChannel
)
channelRoute
.
GET
(
"/test/:id"
,
controller
.
TestChannel
)
channelRoute
.
GET
(
"/update_balance"
,
controller
.
UpdateAllChannelsBalance
)
channelRoute
.
GET
(
"/update_balance"
,
controller
.
UpdateAllChannelsBalance
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment