mirror of
https://github.com/grafana/grafana.git
synced 2025-08-02 09:42:13 +08:00
Added binding to tokens api and role validation
This commit is contained in:
@ -46,7 +46,10 @@ func Register(r *macaron.Macaron) {
|
||||
})
|
||||
// Token
|
||||
r.Group("/tokens", func() {
|
||||
r.Combo("/").Get(GetTokens).Put(AddToken).Post(UpdateToken)
|
||||
r.Combo("/").
|
||||
Get(GetTokens).
|
||||
Put(bind(m.AddTokenCommand{}), AddToken).
|
||||
Post(bind(m.UpdateTokenCommand{}), UpdateToken)
|
||||
r.Delete("/:id", DeleteToken)
|
||||
})
|
||||
// Data sources
|
||||
|
Reference in New Issue
Block a user