@@ -50,6 +50,8 @@ func ListTeams(ctx *context.APIContext) {
5050 // responses:
5151 // "200":
5252 // "$ref": "#/responses/TeamList"
53+ // "404":
54+ // "$ref": "#/responses/notFound"
5355
5456 teams , count , err := organization .SearchTeam (& organization.SearchTeamOptions {
5557 ListOptions : utils .GetListOptions (ctx ),
@@ -126,6 +128,8 @@ func GetTeam(ctx *context.APIContext) {
126128 // responses:
127129 // "200":
128130 // "$ref": "#/responses/Team"
131+ // "404":
132+ // "$ref": "#/responses/notFound"
129133
130134 apiTeam , err := convert .ToTeam (ctx , ctx .Org .Team , true )
131135 if err != nil {
@@ -204,6 +208,8 @@ func CreateTeam(ctx *context.APIContext) {
204208 // responses:
205209 // "201":
206210 // "$ref": "#/responses/Team"
211+ // "404":
212+ // "$ref": "#/responses/notFound"
207213 // "422":
208214 // "$ref": "#/responses/validationError"
209215 form := web .GetForm (ctx ).(* api.CreateTeamOption )
@@ -272,6 +278,8 @@ func EditTeam(ctx *context.APIContext) {
272278 // responses:
273279 // "200":
274280 // "$ref": "#/responses/Team"
281+ // "404":
282+ // "$ref": "#/responses/notFound"
275283
276284 form := web .GetForm (ctx ).(* api.EditTeamOption )
277285 team := ctx .Org .Team
@@ -350,6 +358,8 @@ func DeleteTeam(ctx *context.APIContext) {
350358 // responses:
351359 // "204":
352360 // description: team deleted
361+ // "404":
362+ // "$ref": "#/responses/notFound"
353363
354364 if err := models .DeleteTeam (ctx .Org .Team ); err != nil {
355365 ctx .Error (http .StatusInternalServerError , "DeleteTeam" , err )
@@ -383,6 +393,8 @@ func GetTeamMembers(ctx *context.APIContext) {
383393 // responses:
384394 // "200":
385395 // "$ref": "#/responses/UserList"
396+ // "404":
397+ // "$ref": "#/responses/notFound"
386398
387399 isMember , err := organization .IsOrganizationMember (ctx , ctx .Org .Team .OrgID , ctx .Doer .ID )
388400 if err != nil {
@@ -550,6 +562,8 @@ func GetTeamRepos(ctx *context.APIContext) {
550562 // responses:
551563 // "200":
552564 // "$ref": "#/responses/RepositoryList"
565+ // "404":
566+ // "$ref": "#/responses/notFound"
553567
554568 team := ctx .Org .Team
555569 teamRepos , err := organization .GetTeamRepositories (ctx , & organization.SearchTeamRepoOptions {
@@ -665,6 +679,8 @@ func AddTeamRepository(ctx *context.APIContext) {
665679 // "$ref": "#/responses/empty"
666680 // "403":
667681 // "$ref": "#/responses/forbidden"
682+ // "404":
683+ // "$ref": "#/responses/notFound"
668684
669685 repo := getRepositoryByParams (ctx )
670686 if ctx .Written () {
@@ -715,6 +731,8 @@ func RemoveTeamRepository(ctx *context.APIContext) {
715731 // "$ref": "#/responses/empty"
716732 // "403":
717733 // "$ref": "#/responses/forbidden"
734+ // "404":
735+ // "$ref": "#/responses/notFound"
718736
719737 repo := getRepositoryByParams (ctx )
720738 if ctx .Written () {
@@ -775,6 +793,8 @@ func SearchTeam(ctx *context.APIContext) {
775793 // type: array
776794 // items:
777795 // "$ref": "#/definitions/Team"
796+ // "404":
797+ // "$ref": "#/responses/notFound"
778798
779799 listOptions := utils .GetListOptions (ctx )
780800
0 commit comments