feat: add groups support to the CLI (#4755)

This commit is contained in:
Jon Ayers
2022-10-27 16:49:35 -05:00
committed by GitHub
parent ce2a7d49b1
commit 90f77a3415
28 changed files with 766 additions and 18 deletions

View File

@ -77,10 +77,18 @@ func New(ctx context.Context, options *Options) (*API, error) {
r.Route("/organizations/{organization}/groups", func(r chi.Router) {
r.Use(
apiKeyMiddleware,
api.templateRBACEnabledMW,
httpmw.ExtractOrganizationParam(api.Database),
)
r.Post("/", api.postGroupByOrganization)
r.Get("/", api.groups)
r.Route("/{groupName}", func(r chi.Router) {
r.Use(
httpmw.ExtractGroupByNameParam(api.Database),
)
r.Get("/", api.group)
})
})
r.Route("/templates/{template}/acl", func(r chi.Router) {