1
0
mirror of https://github.com/prometheus/alertmanager.git synced 2026-02-05 15:45:34 +01:00

Regenerated OpenAPI client code

Signed-off-by: Danny Kopping <danny.kopping@grafana.com>
This commit is contained in:
Danny Kopping
2021-09-10 12:46:56 +02:00
committed by Julien Pivotto
parent 7c5f105506
commit 97e5779c3f
34 changed files with 69 additions and 69 deletions

View File

@@ -60,7 +60,7 @@ func (a *Client) GetAlerts(params *GetAlertsParams) (*GetAlertsOK, error) {
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "getAlerts",
Method: "GET",
PathPattern: "/alerts",
PathPattern: "/api/v2/alerts",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},
@@ -94,7 +94,7 @@ func (a *Client) PostAlerts(params *PostAlertsParams) (*PostAlertsOK, error) {
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "postAlerts",
Method: "POST",
PathPattern: "/alerts",
PathPattern: "/api/v2/alerts",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},

View File

@@ -75,7 +75,7 @@ type GetAlertsOK struct {
}
func (o *GetAlertsOK) Error() string {
return fmt.Sprintf("[GET /alerts][%d] getAlertsOK %+v", 200, o.Payload)
return fmt.Sprintf("[GET /api/v2/alerts][%d] getAlertsOK %+v", 200, o.Payload)
}
func (o *GetAlertsOK) GetPayload() models.GettableAlerts {
@@ -106,7 +106,7 @@ type GetAlertsBadRequest struct {
}
func (o *GetAlertsBadRequest) Error() string {
return fmt.Sprintf("[GET /alerts][%d] getAlertsBadRequest %+v", 400, o.Payload)
return fmt.Sprintf("[GET /api/v2/alerts][%d] getAlertsBadRequest %+v", 400, o.Payload)
}
func (o *GetAlertsBadRequest) GetPayload() string {
@@ -137,7 +137,7 @@ type GetAlertsInternalServerError struct {
}
func (o *GetAlertsInternalServerError) Error() string {
return fmt.Sprintf("[GET /alerts][%d] getAlertsInternalServerError %+v", 500, o.Payload)
return fmt.Sprintf("[GET /api/v2/alerts][%d] getAlertsInternalServerError %+v", 500, o.Payload)
}
func (o *GetAlertsInternalServerError) GetPayload() string {

View File

@@ -72,7 +72,7 @@ type PostAlertsOK struct {
}
func (o *PostAlertsOK) Error() string {
return fmt.Sprintf("[POST /alerts][%d] postAlertsOK ", 200)
return fmt.Sprintf("[POST /api/v2/alerts][%d] postAlertsOK ", 200)
}
func (o *PostAlertsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
@@ -94,7 +94,7 @@ type PostAlertsBadRequest struct {
}
func (o *PostAlertsBadRequest) Error() string {
return fmt.Sprintf("[POST /alerts][%d] postAlertsBadRequest %+v", 400, o.Payload)
return fmt.Sprintf("[POST /api/v2/alerts][%d] postAlertsBadRequest %+v", 400, o.Payload)
}
func (o *PostAlertsBadRequest) GetPayload() string {
@@ -125,7 +125,7 @@ type PostAlertsInternalServerError struct {
}
func (o *PostAlertsInternalServerError) Error() string {
return fmt.Sprintf("[POST /alerts][%d] postAlertsInternalServerError %+v", 500, o.Payload)
return fmt.Sprintf("[POST /api/v2/alerts][%d] postAlertsInternalServerError %+v", 500, o.Payload)
}
func (o *PostAlertsInternalServerError) GetPayload() string {

View File

@@ -58,7 +58,7 @@ func (a *Client) GetAlertGroups(params *GetAlertGroupsParams) (*GetAlertGroupsOK
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "getAlertGroups",
Method: "GET",
PathPattern: "/alerts/groups",
PathPattern: "/api/v2/alerts/groups",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},

View File

@@ -75,7 +75,7 @@ type GetAlertGroupsOK struct {
}
func (o *GetAlertGroupsOK) Error() string {
return fmt.Sprintf("[GET /alerts/groups][%d] getAlertGroupsOK %+v", 200, o.Payload)
return fmt.Sprintf("[GET /api/v2/alerts/groups][%d] getAlertGroupsOK %+v", 200, o.Payload)
}
func (o *GetAlertGroupsOK) GetPayload() models.AlertGroups {
@@ -106,7 +106,7 @@ type GetAlertGroupsBadRequest struct {
}
func (o *GetAlertGroupsBadRequest) Error() string {
return fmt.Sprintf("[GET /alerts/groups][%d] getAlertGroupsBadRequest %+v", 400, o.Payload)
return fmt.Sprintf("[GET /api/v2/alerts/groups][%d] getAlertGroupsBadRequest %+v", 400, o.Payload)
}
func (o *GetAlertGroupsBadRequest) GetPayload() string {
@@ -137,7 +137,7 @@ type GetAlertGroupsInternalServerError struct {
}
func (o *GetAlertGroupsInternalServerError) Error() string {
return fmt.Sprintf("[GET /alerts/groups][%d] getAlertGroupsInternalServerError %+v", 500, o.Payload)
return fmt.Sprintf("[GET /api/v2/alerts/groups][%d] getAlertGroupsInternalServerError %+v", 500, o.Payload)
}
func (o *GetAlertGroupsInternalServerError) GetPayload() string {

View File

@@ -58,7 +58,7 @@ func (a *Client) GetStatus(params *GetStatusParams) (*GetStatusOK, error) {
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "getStatus",
Method: "GET",
PathPattern: "/status",
PathPattern: "/api/v2/status",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},

View File

@@ -63,7 +63,7 @@ type GetStatusOK struct {
}
func (o *GetStatusOK) Error() string {
return fmt.Sprintf("[GET /status][%d] getStatusOK %+v", 200, o.Payload)
return fmt.Sprintf("[GET /api/v2/status][%d] getStatusOK %+v", 200, o.Payload)
}
func (o *GetStatusOK) GetPayload() *models.AlertmanagerStatus {

View File

@@ -63,7 +63,7 @@ type GetReceiversOK struct {
}
func (o *GetReceiversOK) Error() string {
return fmt.Sprintf("[GET /receivers][%d] getReceiversOK %+v", 200, o.Payload)
return fmt.Sprintf("[GET /api/v2/receivers][%d] getReceiversOK %+v", 200, o.Payload)
}
func (o *GetReceiversOK) GetPayload() []*models.Receiver {

View File

@@ -58,7 +58,7 @@ func (a *Client) GetReceivers(params *GetReceiversParams) (*GetReceiversOK, erro
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "getReceivers",
Method: "GET",
PathPattern: "/receivers",
PathPattern: "/api/v2/receivers",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},

View File

@@ -66,7 +66,7 @@ type DeleteSilenceOK struct {
}
func (o *DeleteSilenceOK) Error() string {
return fmt.Sprintf("[DELETE /silence/{silenceID}][%d] deleteSilenceOK ", 200)
return fmt.Sprintf("[DELETE /api/v2/silence/{silenceID}][%d] deleteSilenceOK ", 200)
}
func (o *DeleteSilenceOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
@@ -88,7 +88,7 @@ type DeleteSilenceInternalServerError struct {
}
func (o *DeleteSilenceInternalServerError) Error() string {
return fmt.Sprintf("[DELETE /silence/{silenceID}][%d] deleteSilenceInternalServerError %+v", 500, o.Payload)
return fmt.Sprintf("[DELETE /api/v2/silence/{silenceID}][%d] deleteSilenceInternalServerError %+v", 500, o.Payload)
}
func (o *DeleteSilenceInternalServerError) GetPayload() string {

View File

@@ -75,7 +75,7 @@ type GetSilenceOK struct {
}
func (o *GetSilenceOK) Error() string {
return fmt.Sprintf("[GET /silence/{silenceID}][%d] getSilenceOK %+v", 200, o.Payload)
return fmt.Sprintf("[GET /api/v2/silence/{silenceID}][%d] getSilenceOK %+v", 200, o.Payload)
}
func (o *GetSilenceOK) GetPayload() *models.GettableSilence {
@@ -107,7 +107,7 @@ type GetSilenceNotFound struct {
}
func (o *GetSilenceNotFound) Error() string {
return fmt.Sprintf("[GET /silence/{silenceID}][%d] getSilenceNotFound ", 404)
return fmt.Sprintf("[GET /api/v2/silence/{silenceID}][%d] getSilenceNotFound ", 404)
}
func (o *GetSilenceNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
@@ -129,7 +129,7 @@ type GetSilenceInternalServerError struct {
}
func (o *GetSilenceInternalServerError) Error() string {
return fmt.Sprintf("[GET /silence/{silenceID}][%d] getSilenceInternalServerError %+v", 500, o.Payload)
return fmt.Sprintf("[GET /api/v2/silence/{silenceID}][%d] getSilenceInternalServerError %+v", 500, o.Payload)
}
func (o *GetSilenceInternalServerError) GetPayload() string {

View File

@@ -69,7 +69,7 @@ type GetSilencesOK struct {
}
func (o *GetSilencesOK) Error() string {
return fmt.Sprintf("[GET /silences][%d] getSilencesOK %+v", 200, o.Payload)
return fmt.Sprintf("[GET /api/v2/silences][%d] getSilencesOK %+v", 200, o.Payload)
}
func (o *GetSilencesOK) GetPayload() models.GettableSilences {
@@ -100,7 +100,7 @@ type GetSilencesInternalServerError struct {
}
func (o *GetSilencesInternalServerError) Error() string {
return fmt.Sprintf("[GET /silences][%d] getSilencesInternalServerError %+v", 500, o.Payload)
return fmt.Sprintf("[GET /api/v2/silences][%d] getSilencesInternalServerError %+v", 500, o.Payload)
}
func (o *GetSilencesInternalServerError) GetPayload() string {

View File

@@ -74,7 +74,7 @@ type PostSilencesOK struct {
}
func (o *PostSilencesOK) Error() string {
return fmt.Sprintf("[POST /silences][%d] postSilencesOK %+v", 200, o.Payload)
return fmt.Sprintf("[POST /api/v2/silences][%d] postSilencesOK %+v", 200, o.Payload)
}
func (o *PostSilencesOK) GetPayload() *PostSilencesOKBody {
@@ -107,7 +107,7 @@ type PostSilencesBadRequest struct {
}
func (o *PostSilencesBadRequest) Error() string {
return fmt.Sprintf("[POST /silences][%d] postSilencesBadRequest %+v", 400, o.Payload)
return fmt.Sprintf("[POST /api/v2/silences][%d] postSilencesBadRequest %+v", 400, o.Payload)
}
func (o *PostSilencesBadRequest) GetPayload() string {
@@ -138,7 +138,7 @@ type PostSilencesNotFound struct {
}
func (o *PostSilencesNotFound) Error() string {
return fmt.Sprintf("[POST /silences][%d] postSilencesNotFound %+v", 404, o.Payload)
return fmt.Sprintf("[POST /api/v2/silences][%d] postSilencesNotFound %+v", 404, o.Payload)
}
func (o *PostSilencesNotFound) GetPayload() string {

View File

@@ -64,7 +64,7 @@ func (a *Client) DeleteSilence(params *DeleteSilenceParams) (*DeleteSilenceOK, e
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "deleteSilence",
Method: "DELETE",
PathPattern: "/silence/{silenceID}",
PathPattern: "/api/v2/silence/{silenceID}",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},
@@ -98,7 +98,7 @@ func (a *Client) GetSilence(params *GetSilenceParams) (*GetSilenceOK, error) {
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "getSilence",
Method: "GET",
PathPattern: "/silence/{silenceID}",
PathPattern: "/api/v2/silence/{silenceID}",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},
@@ -132,7 +132,7 @@ func (a *Client) GetSilences(params *GetSilencesParams) (*GetSilencesOK, error)
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "getSilences",
Method: "GET",
PathPattern: "/silences",
PathPattern: "/api/v2/silences",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},
@@ -166,7 +166,7 @@ func (a *Client) PostSilences(params *PostSilencesParams) (*PostSilencesOK, erro
result, err := a.transport.Submit(&runtime.ClientOperation{
ID: "postSilences",
Method: "POST",
PathPattern: "/silences",
PathPattern: "/api/v2/silences",
ProducesMediaTypes: []string{"application/json"},
ConsumesMediaTypes: []string{"application/json"},
Schemes: []string{"http"},

View File

@@ -49,7 +49,7 @@ func init() {
"version": "0.0.1"
},
"paths": {
"/alerts": {
"/api/v2/alerts": {
"get": {
"description": "Get a list of alerts",
"tags": [
@@ -147,7 +147,7 @@ func init() {
}
}
},
"/alerts/groups": {
"/api/v2/alerts/groups": {
"get": {
"description": "Get a list of alert groups",
"tags": [
@@ -209,7 +209,7 @@ func init() {
}
}
},
"/receivers": {
"/api/v2/receivers": {
"get": {
"description": "Get list of all receivers (name of notification integrations)",
"tags": [
@@ -229,7 +229,7 @@ func init() {
}
}
},
"/silence/{silenceID}": {
"/api/v2/silence/{silenceID}": {
"get": {
"description": "Get a silence by its ID",
"tags": [
@@ -287,7 +287,7 @@ func init() {
}
]
},
"/silences": {
"/api/v2/silences": {
"get": {
"description": "Get a list of silences",
"tags": [
@@ -359,7 +359,7 @@ func init() {
}
}
},
"/status": {
"/api/v2/status": {
"get": {
"description": "Get current status of an Alertmanager instance and its cluster",
"tags": [
@@ -832,7 +832,7 @@ func init() {
"version": "0.0.1"
},
"paths": {
"/alerts": {
"/api/v2/alerts": {
"get": {
"description": "Get a list of alerts",
"tags": [
@@ -942,7 +942,7 @@ func init() {
}
}
},
"/alerts/groups": {
"/api/v2/alerts/groups": {
"get": {
"description": "Get a list of alert groups",
"tags": [
@@ -1010,7 +1010,7 @@ func init() {
}
}
},
"/receivers": {
"/api/v2/receivers": {
"get": {
"description": "Get list of all receivers (name of notification integrations)",
"tags": [
@@ -1030,7 +1030,7 @@ func init() {
}
}
},
"/silence/{silenceID}": {
"/api/v2/silence/{silenceID}": {
"get": {
"description": "Get a silence by its ID",
"tags": [
@@ -1094,7 +1094,7 @@ func init() {
}
]
},
"/silences": {
"/api/v2/silences": {
"get": {
"description": "Get a list of silences",
"tags": [
@@ -1172,7 +1172,7 @@ func init() {
}
}
},
"/status": {
"/api/v2/status": {
"get": {
"description": "Get current status of an Alertmanager instance and its cluster",
"tags": [

View File

@@ -43,7 +43,7 @@ func NewGetAlerts(ctx *middleware.Context, handler GetAlertsHandler) *GetAlerts
return &GetAlerts{Context: ctx, Handler: handler}
}
/*GetAlerts swagger:route GET /alerts alert getAlerts
/*GetAlerts swagger:route GET /api/v2/alerts alert getAlerts
Get a list of alerts

View File

@@ -60,7 +60,7 @@ func (o *GetAlertsURL) SetBasePath(bp string) {
func (o *GetAlertsURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/alerts"
var _path = "/api/v2/alerts"
_basePath := o._basePath
_result.Path = golangswaggerpaths.Join(_basePath, _path)

View File

@@ -43,7 +43,7 @@ func NewPostAlerts(ctx *middleware.Context, handler PostAlertsHandler) *PostAler
return &PostAlerts{Context: ctx, Handler: handler}
}
/*PostAlerts swagger:route POST /alerts alert postAlerts
/*PostAlerts swagger:route POST /api/v2/alerts alert postAlerts
Create new Alerts

View File

@@ -49,7 +49,7 @@ func (o *PostAlertsURL) SetBasePath(bp string) {
func (o *PostAlertsURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/alerts"
var _path = "/api/v2/alerts"
_basePath := o._basePath
_result.Path = golangswaggerpaths.Join(_basePath, _path)

View File

@@ -43,7 +43,7 @@ func NewGetAlertGroups(ctx *middleware.Context, handler GetAlertGroupsHandler) *
return &GetAlertGroups{Context: ctx, Handler: handler}
}
/*GetAlertGroups swagger:route GET /alerts/groups alertgroup getAlertGroups
/*GetAlertGroups swagger:route GET /api/v2/alerts/groups alertgroup getAlertGroups
Get a list of alert groups

View File

@@ -59,7 +59,7 @@ func (o *GetAlertGroupsURL) SetBasePath(bp string) {
func (o *GetAlertGroupsURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/alerts/groups"
var _path = "/api/v2/alerts/groups"
_basePath := o._basePath
_result.Path = golangswaggerpaths.Join(_basePath, _path)

View File

@@ -323,39 +323,39 @@ func (o *AlertmanagerAPI) initHandlerCache() {
if o.handlers["DELETE"] == nil {
o.handlers["DELETE"] = make(map[string]http.Handler)
}
o.handlers["DELETE"]["/silence/{silenceID}"] = silence.NewDeleteSilence(o.context, o.SilenceDeleteSilenceHandler)
o.handlers["DELETE"]["/api/v2/silence/{silenceID}"] = silence.NewDeleteSilence(o.context, o.SilenceDeleteSilenceHandler)
if o.handlers["GET"] == nil {
o.handlers["GET"] = make(map[string]http.Handler)
}
o.handlers["GET"]["/alerts/groups"] = alertgroup.NewGetAlertGroups(o.context, o.AlertgroupGetAlertGroupsHandler)
o.handlers["GET"]["/api/v2/alerts/groups"] = alertgroup.NewGetAlertGroups(o.context, o.AlertgroupGetAlertGroupsHandler)
if o.handlers["GET"] == nil {
o.handlers["GET"] = make(map[string]http.Handler)
}
o.handlers["GET"]["/alerts"] = alert.NewGetAlerts(o.context, o.AlertGetAlertsHandler)
o.handlers["GET"]["/api/v2/alerts"] = alert.NewGetAlerts(o.context, o.AlertGetAlertsHandler)
if o.handlers["GET"] == nil {
o.handlers["GET"] = make(map[string]http.Handler)
}
o.handlers["GET"]["/receivers"] = receiver.NewGetReceivers(o.context, o.ReceiverGetReceiversHandler)
o.handlers["GET"]["/api/v2/receivers"] = receiver.NewGetReceivers(o.context, o.ReceiverGetReceiversHandler)
if o.handlers["GET"] == nil {
o.handlers["GET"] = make(map[string]http.Handler)
}
o.handlers["GET"]["/silence/{silenceID}"] = silence.NewGetSilence(o.context, o.SilenceGetSilenceHandler)
o.handlers["GET"]["/api/v2/silence/{silenceID}"] = silence.NewGetSilence(o.context, o.SilenceGetSilenceHandler)
if o.handlers["GET"] == nil {
o.handlers["GET"] = make(map[string]http.Handler)
}
o.handlers["GET"]["/silences"] = silence.NewGetSilences(o.context, o.SilenceGetSilencesHandler)
o.handlers["GET"]["/api/v2/silences"] = silence.NewGetSilences(o.context, o.SilenceGetSilencesHandler)
if o.handlers["GET"] == nil {
o.handlers["GET"] = make(map[string]http.Handler)
}
o.handlers["GET"]["/status"] = general.NewGetStatus(o.context, o.GeneralGetStatusHandler)
o.handlers["GET"]["/api/v2/status"] = general.NewGetStatus(o.context, o.GeneralGetStatusHandler)
if o.handlers["POST"] == nil {
o.handlers["POST"] = make(map[string]http.Handler)
}
o.handlers["POST"]["/alerts"] = alert.NewPostAlerts(o.context, o.AlertPostAlertsHandler)
o.handlers["POST"]["/api/v2/alerts"] = alert.NewPostAlerts(o.context, o.AlertPostAlertsHandler)
if o.handlers["POST"] == nil {
o.handlers["POST"] = make(map[string]http.Handler)
}
o.handlers["POST"]["/silences"] = silence.NewPostSilences(o.context, o.SilencePostSilencesHandler)
o.handlers["POST"]["/api/v2/silences"] = silence.NewPostSilences(o.context, o.SilencePostSilencesHandler)
}
// Serve creates a http handler to serve the API over HTTP

View File

@@ -43,7 +43,7 @@ func NewGetStatus(ctx *middleware.Context, handler GetStatusHandler) *GetStatus
return &GetStatus{Context: ctx, Handler: handler}
}
/*GetStatus swagger:route GET /status general getStatus
/*GetStatus swagger:route GET /api/v2/status general getStatus
Get current status of an Alertmanager instance and its cluster

View File

@@ -49,7 +49,7 @@ func (o *GetStatusURL) SetBasePath(bp string) {
func (o *GetStatusURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/status"
var _path = "/api/v2/status"
_basePath := o._basePath
_result.Path = golangswaggerpaths.Join(_basePath, _path)

View File

@@ -43,7 +43,7 @@ func NewGetReceivers(ctx *middleware.Context, handler GetReceiversHandler) *GetR
return &GetReceivers{Context: ctx, Handler: handler}
}
/*GetReceivers swagger:route GET /receivers receiver getReceivers
/*GetReceivers swagger:route GET /api/v2/receivers receiver getReceivers
Get list of all receivers (name of notification integrations)

View File

@@ -49,7 +49,7 @@ func (o *GetReceiversURL) SetBasePath(bp string) {
func (o *GetReceiversURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/receivers"
var _path = "/api/v2/receivers"
_basePath := o._basePath
_result.Path = golangswaggerpaths.Join(_basePath, _path)

View File

@@ -43,7 +43,7 @@ func NewDeleteSilence(ctx *middleware.Context, handler DeleteSilenceHandler) *De
return &DeleteSilence{Context: ctx, Handler: handler}
}
/*DeleteSilence swagger:route DELETE /silence/{silenceID} silence deleteSilence
/*DeleteSilence swagger:route DELETE /api/v2/silence/{silenceID} silence deleteSilence
Delete a silence by its ID

View File

@@ -56,7 +56,7 @@ func (o *DeleteSilenceURL) SetBasePath(bp string) {
func (o *DeleteSilenceURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/silence/{silenceID}"
var _path = "/api/v2/silence/{silenceID}"
silenceID := o.SilenceID.String()
if silenceID != "" {

View File

@@ -43,7 +43,7 @@ func NewGetSilence(ctx *middleware.Context, handler GetSilenceHandler) *GetSilen
return &GetSilence{Context: ctx, Handler: handler}
}
/*GetSilence swagger:route GET /silence/{silenceID} silence getSilence
/*GetSilence swagger:route GET /api/v2/silence/{silenceID} silence getSilence
Get a silence by its ID

View File

@@ -56,7 +56,7 @@ func (o *GetSilenceURL) SetBasePath(bp string) {
func (o *GetSilenceURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/silence/{silenceID}"
var _path = "/api/v2/silence/{silenceID}"
silenceID := o.SilenceID.String()
if silenceID != "" {

View File

@@ -43,7 +43,7 @@ func NewGetSilences(ctx *middleware.Context, handler GetSilencesHandler) *GetSil
return &GetSilences{Context: ctx, Handler: handler}
}
/*GetSilences swagger:route GET /silences silence getSilences
/*GetSilences swagger:route GET /api/v2/silences silence getSilences
Get a list of silences

View File

@@ -55,7 +55,7 @@ func (o *GetSilencesURL) SetBasePath(bp string) {
func (o *GetSilencesURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/silences"
var _path = "/api/v2/silences"
_basePath := o._basePath
_result.Path = golangswaggerpaths.Join(_basePath, _path)

View File

@@ -45,7 +45,7 @@ func NewPostSilences(ctx *middleware.Context, handler PostSilencesHandler) *Post
return &PostSilences{Context: ctx, Handler: handler}
}
/*PostSilences swagger:route POST /silences silence postSilences
/*PostSilences swagger:route POST /api/v2/silences silence postSilences
Post a new silence or update an existing one

View File

@@ -49,7 +49,7 @@ func (o *PostSilencesURL) SetBasePath(bp string) {
func (o *PostSilencesURL) Build() (*url.URL, error) {
var _result url.URL
var _path = "/silences"
var _path = "/api/v2/silences"
_basePath := o._basePath
_result.Path = golangswaggerpaths.Join(_basePath, _path)