OpenAPI: Fix alerting DeleteMuteTiming errors (#91109)

The `GenericPublicError` is not what is actually returned by the API. Using `PublicError` describes the API correctly
This commit is contained in:
Julien Duchesne
2024-08-26 10:04:36 -04:00
committed by GitHub
parent 0075abe383
commit 087df1d8e5
8 changed files with 66 additions and 116 deletions
@@ -70,7 +70,7 @@ import (
// Responses:
// 202: MuteTimeInterval
// 400: ValidationError
// 409: GenericPublicError
// 409: PublicError
// swagger:route DELETE /v1/provisioning/mute-timings/{name} provisioning stable RouteDeleteMuteTiming
//
@@ -78,7 +78,7 @@ import (
//
// Responses:
// 204: description: The mute timing was deleted successfully.
// 409: GenericPublicError
// 409: PublicError
// swagger:route
@@ -13,7 +13,7 @@ package definitions
//
// Responses:
// 200: NotificationTemplate
// 404: GenericPublicError
// 404: PublicError
// swagger:route PUT /v1/provisioning/templates/{name} provisioning stable RoutePutTemplate
//
@@ -24,8 +24,8 @@ package definitions
//
// Responses:
// 202: NotificationTemplate
// 400: GenericPublicError
// 409: GenericPublicError
// 400: PublicError
// 409: PublicError
// swagger:route DELETE /v1/provisioning/templates/{name} provisioning stable RouteDeleteTemplate
//
@@ -33,7 +33,7 @@ package definitions
//
// Responses:
// 204: description: The template was deleted successfully.
// 409: GenericPublicError
// 409: PublicError
// swagger:parameters RouteGetTemplate RoutePutTemplate RouteDeleteTemplate
type RouteGetTemplateParam struct {
@@ -20,10 +20,3 @@ type ForbiddenError struct {
// in: body
Body errutil.PublicError `json:"body"`
}
// swagger:model
type GenericPublicError struct {
// The response message
// in: body
Body errutil.PublicError `json:"body"`
}