github.com/machinefi/w3bstream@v1.6.5-rc9.0.20240426031326-b8c7c4876e72/cmd/srv-applet-mgr/apis/account/root.go (about) 1 package account 2 3 import ( 4 "github.com/machinefi/w3bstream/pkg/depends/kit/httptransport" 5 "github.com/machinefi/w3bstream/pkg/depends/kit/kit" 6 "github.com/machinefi/w3bstream/pkg/enums" 7 "github.com/machinefi/w3bstream/pkg/modules/access_key" 8 ) 9 10 var ( 11 Root = kit.NewRouter(httptransport.Group("/account")) 12 RegisterRoot = kit.NewRouter(httptransport.Group("/register")) 13 ) 14 15 func init() { 16 Root.Register(kit.NewRouter(&UpdatePasswordByAccountID{})) 17 Root.Register(kit.NewRouter(&GetOperatorAddr{})) 18 19 RegisterRoot.Register(kit.NewRouter(&CreateAccountByUsernameAndPassword{})) 20 21 access_key.RouterRegister(Root, enums.ApiGroupAccount, enums.ApiGroupAccountDesc) 22 access_key.RouterRegister(RegisterRoot, enums.ApiGroupAccountRegister, enums.ApiGroupAccountRegisterDesc) 23 }