Swagger: annotate RoleType as enumeration (#47902)

This commit is contained in:
Sofia Papagiannaki
2022-04-20 10:27:25 +03:00
committed by GitHub
parent 70802447a5
commit e58a015baf
4 changed files with 114 additions and 66 deletions
+1
View File
@@ -26,6 +26,7 @@ type ApiKey struct {
// ---------------------
// COMMANDS
// swagger:model
type AddApiKeyCommand struct {
Name string `json:"name" binding:"Required"`
Role RoleType `json:"role" binding:"Required"`
+1
View File
@@ -14,6 +14,7 @@ var (
ErrOrgUserAlreadyAdded = errors.New("user is already added to organization")
)
// swagger:enum RoleType
type RoleType string
const (