...

Package silence

import "github.com/prometheus/alertmanager/api/v2/restapi/operations/silence"
Overview
Index

Overview ▾

Index ▾

Constants
type DeleteSilence
    func NewDeleteSilence(ctx *middleware.Context, handler DeleteSilenceHandler) *DeleteSilence
    func (o *DeleteSilence) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type DeleteSilenceHandler
type DeleteSilenceHandlerFunc
    func (fn DeleteSilenceHandlerFunc) Handle(params DeleteSilenceParams) middleware.Responder
type DeleteSilenceInternalServerError
    func NewDeleteSilenceInternalServerError() *DeleteSilenceInternalServerError
    func (o *DeleteSilenceInternalServerError) SetPayload(payload string)
    func (o *DeleteSilenceInternalServerError) WithPayload(payload string) *DeleteSilenceInternalServerError
    func (o *DeleteSilenceInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type DeleteSilenceOK
    func NewDeleteSilenceOK() *DeleteSilenceOK
    func (o *DeleteSilenceOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type DeleteSilenceParams
    func NewDeleteSilenceParams() DeleteSilenceParams
    func (o *DeleteSilenceParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
type DeleteSilenceURL
    func (o *DeleteSilenceURL) Build() (*url.URL, error)
    func (o *DeleteSilenceURL) BuildFull(scheme, host string) (*url.URL, error)
    func (o *DeleteSilenceURL) Must(u *url.URL, err error) *url.URL
    func (o *DeleteSilenceURL) SetBasePath(bp string)
    func (o *DeleteSilenceURL) String() string
    func (o *DeleteSilenceURL) StringFull(scheme, host string) string
    func (o *DeleteSilenceURL) WithBasePath(bp string) *DeleteSilenceURL
type GetSilence
    func NewGetSilence(ctx *middleware.Context, handler GetSilenceHandler) *GetSilence
    func (o *GetSilence) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type GetSilenceHandler
type GetSilenceHandlerFunc
    func (fn GetSilenceHandlerFunc) Handle(params GetSilenceParams) middleware.Responder
type GetSilenceInternalServerError
    func NewGetSilenceInternalServerError() *GetSilenceInternalServerError
    func (o *GetSilenceInternalServerError) SetPayload(payload string)
    func (o *GetSilenceInternalServerError) WithPayload(payload string) *GetSilenceInternalServerError
    func (o *GetSilenceInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type GetSilenceNotFound
    func NewGetSilenceNotFound() *GetSilenceNotFound
    func (o *GetSilenceNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type GetSilenceOK
    func NewGetSilenceOK() *GetSilenceOK
    func (o *GetSilenceOK) SetPayload(payload *models.GettableSilence)
    func (o *GetSilenceOK) WithPayload(payload *models.GettableSilence) *GetSilenceOK
    func (o *GetSilenceOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type GetSilenceParams
    func NewGetSilenceParams() GetSilenceParams
    func (o *GetSilenceParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
type GetSilenceURL
    func (o *GetSilenceURL) Build() (*url.URL, error)
    func (o *GetSilenceURL) BuildFull(scheme, host string) (*url.URL, error)
    func (o *GetSilenceURL) Must(u *url.URL, err error) *url.URL
    func (o *GetSilenceURL) SetBasePath(bp string)
    func (o *GetSilenceURL) String() string
    func (o *GetSilenceURL) StringFull(scheme, host string) string
    func (o *GetSilenceURL) WithBasePath(bp string) *GetSilenceURL
type GetSilences
    func NewGetSilences(ctx *middleware.Context, handler GetSilencesHandler) *GetSilences
    func (o *GetSilences) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type GetSilencesHandler
type GetSilencesHandlerFunc
    func (fn GetSilencesHandlerFunc) Handle(params GetSilencesParams) middleware.Responder
type GetSilencesInternalServerError
    func NewGetSilencesInternalServerError() *GetSilencesInternalServerError
    func (o *GetSilencesInternalServerError) SetPayload(payload string)
    func (o *GetSilencesInternalServerError) WithPayload(payload string) *GetSilencesInternalServerError
    func (o *GetSilencesInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type GetSilencesOK
    func NewGetSilencesOK() *GetSilencesOK
    func (o *GetSilencesOK) SetPayload(payload models.GettableSilences)
    func (o *GetSilencesOK) WithPayload(payload models.GettableSilences) *GetSilencesOK
    func (o *GetSilencesOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type GetSilencesParams
    func NewGetSilencesParams() GetSilencesParams
    func (o *GetSilencesParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
type GetSilencesURL
    func (o *GetSilencesURL) Build() (*url.URL, error)
    func (o *GetSilencesURL) BuildFull(scheme, host string) (*url.URL, error)
    func (o *GetSilencesURL) Must(u *url.URL, err error) *url.URL
    func (o *GetSilencesURL) SetBasePath(bp string)
    func (o *GetSilencesURL) String() string
    func (o *GetSilencesURL) StringFull(scheme, host string) string
    func (o *GetSilencesURL) WithBasePath(bp string) *GetSilencesURL
type PostSilences
    func NewPostSilences(ctx *middleware.Context, handler PostSilencesHandler) *PostSilences
    func (o *PostSilences) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type PostSilencesBadRequest
    func NewPostSilencesBadRequest() *PostSilencesBadRequest
    func (o *PostSilencesBadRequest) SetPayload(payload string)
    func (o *PostSilencesBadRequest) WithPayload(payload string) *PostSilencesBadRequest
    func (o *PostSilencesBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type PostSilencesHandler
type PostSilencesHandlerFunc
    func (fn PostSilencesHandlerFunc) Handle(params PostSilencesParams) middleware.Responder
type PostSilencesNotFound
    func NewPostSilencesNotFound() *PostSilencesNotFound
    func (o *PostSilencesNotFound) SetPayload(payload string)
    func (o *PostSilencesNotFound) WithPayload(payload string) *PostSilencesNotFound
    func (o *PostSilencesNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type PostSilencesOK
    func NewPostSilencesOK() *PostSilencesOK
    func (o *PostSilencesOK) SetPayload(payload *PostSilencesOKBody)
    func (o *PostSilencesOK) WithPayload(payload *PostSilencesOKBody) *PostSilencesOK
    func (o *PostSilencesOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
type PostSilencesOKBody
    func (o *PostSilencesOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error
    func (o *PostSilencesOKBody) MarshalBinary() ([]byte, error)
    func (o *PostSilencesOKBody) UnmarshalBinary(b []byte) error
    func (o *PostSilencesOKBody) Validate(formats strfmt.Registry) error
type PostSilencesParams
    func NewPostSilencesParams() PostSilencesParams
    func (o *PostSilencesParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
type PostSilencesURL
    func (o *PostSilencesURL) Build() (*url.URL, error)
    func (o *PostSilencesURL) BuildFull(scheme, host string) (*url.URL, error)
    func (o *PostSilencesURL) Must(u *url.URL, err error) *url.URL
    func (o *PostSilencesURL) SetBasePath(bp string)
    func (o *PostSilencesURL) String() string
    func (o *PostSilencesURL) StringFull(scheme, host string) string
    func (o *PostSilencesURL) WithBasePath(bp string) *PostSilencesURL

Package files

delete_silence.go delete_silence_parameters.go delete_silence_responses.go delete_silence_urlbuilder.go get_silence.go get_silence_parameters.go get_silence_responses.go get_silence_urlbuilder.go get_silences.go get_silences_parameters.go get_silences_responses.go get_silences_urlbuilder.go post_silences.go post_silences_parameters.go post_silences_responses.go post_silences_urlbuilder.go

Constants

DeleteSilenceInternalServerErrorCode is the HTTP code returned for type DeleteSilenceInternalServerError

const DeleteSilenceInternalServerErrorCode int = 500

DeleteSilenceOKCode is the HTTP code returned for type DeleteSilenceOK

const DeleteSilenceOKCode int = 200

GetSilenceInternalServerErrorCode is the HTTP code returned for type GetSilenceInternalServerError

const GetSilenceInternalServerErrorCode int = 500

GetSilenceNotFoundCode is the HTTP code returned for type GetSilenceNotFound

const GetSilenceNotFoundCode int = 404

GetSilenceOKCode is the HTTP code returned for type GetSilenceOK

const GetSilenceOKCode int = 200

GetSilencesInternalServerErrorCode is the HTTP code returned for type GetSilencesInternalServerError

const GetSilencesInternalServerErrorCode int = 500

GetSilencesOKCode is the HTTP code returned for type GetSilencesOK

const GetSilencesOKCode int = 200

PostSilencesBadRequestCode is the HTTP code returned for type PostSilencesBadRequest

const PostSilencesBadRequestCode int = 400

PostSilencesNotFoundCode is the HTTP code returned for type PostSilencesNotFound

const PostSilencesNotFoundCode int = 404

PostSilencesOKCode is the HTTP code returned for type PostSilencesOK

const PostSilencesOKCode int = 200

type DeleteSilence

DeleteSilence swagger:route DELETE /silence/{silenceID} silence deleteSilence

Delete a silence by its ID

type DeleteSilence struct {
    Context *middleware.Context
    Handler DeleteSilenceHandler
}

func NewDeleteSilence

func NewDeleteSilence(ctx *middleware.Context, handler DeleteSilenceHandler) *DeleteSilence

NewDeleteSilence creates a new http.Handler for the delete silence operation

func (*DeleteSilence) ServeHTTP

func (o *DeleteSilence) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type DeleteSilenceHandler

DeleteSilenceHandler interface for that can handle valid delete silence params

type DeleteSilenceHandler interface {
    Handle(DeleteSilenceParams) middleware.Responder
}

type DeleteSilenceHandlerFunc

DeleteSilenceHandlerFunc turns a function with the right signature into a delete silence handler

type DeleteSilenceHandlerFunc func(DeleteSilenceParams) middleware.Responder

func (DeleteSilenceHandlerFunc) Handle

func (fn DeleteSilenceHandlerFunc) Handle(params DeleteSilenceParams) middleware.Responder

Handle executing the request and returning a response

type DeleteSilenceInternalServerError

DeleteSilenceInternalServerError Internal server error

swagger:response deleteSilenceInternalServerError

type DeleteSilenceInternalServerError struct {

    /*
      In: Body
    */
    Payload string `json:"body,omitempty"`
}

func NewDeleteSilenceInternalServerError

func NewDeleteSilenceInternalServerError() *DeleteSilenceInternalServerError

NewDeleteSilenceInternalServerError creates DeleteSilenceInternalServerError with default headers values

func (*DeleteSilenceInternalServerError) SetPayload

func (o *DeleteSilenceInternalServerError) SetPayload(payload string)

SetPayload sets the payload to the delete silence internal server error response

func (*DeleteSilenceInternalServerError) WithPayload

func (o *DeleteSilenceInternalServerError) WithPayload(payload string) *DeleteSilenceInternalServerError

WithPayload adds the payload to the delete silence internal server error response

func (*DeleteSilenceInternalServerError) WriteResponse

func (o *DeleteSilenceInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type DeleteSilenceOK

DeleteSilenceOK Delete silence response

swagger:response deleteSilenceOK

type DeleteSilenceOK struct {
}

func NewDeleteSilenceOK

func NewDeleteSilenceOK() *DeleteSilenceOK

NewDeleteSilenceOK creates DeleteSilenceOK with default headers values

func (*DeleteSilenceOK) WriteResponse

func (o *DeleteSilenceOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type DeleteSilenceParams

DeleteSilenceParams contains all the bound params for the delete silence operation typically these are obtained from a http.Request

swagger:parameters deleteSilence

type DeleteSilenceParams struct {

    // HTTP Request Object
    HTTPRequest *http.Request `json:"-"`

    /*ID of the silence to get
      Required: true
      In: path
    */
    SilenceID strfmt.UUID
}

func NewDeleteSilenceParams

func NewDeleteSilenceParams() DeleteSilenceParams

NewDeleteSilenceParams creates a new DeleteSilenceParams object

There are no default values defined in the spec.

func (*DeleteSilenceParams) BindRequest

func (o *DeleteSilenceParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewDeleteSilenceParams() beforehand.

type DeleteSilenceURL

DeleteSilenceURL generates an URL for the delete silence operation

type DeleteSilenceURL struct {
    SilenceID strfmt.UUID
    // contains filtered or unexported fields
}

func (*DeleteSilenceURL) Build

func (o *DeleteSilenceURL) Build() (*url.URL, error)

Build a url path and query string

func (*DeleteSilenceURL) BuildFull

func (o *DeleteSilenceURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*DeleteSilenceURL) Must

func (o *DeleteSilenceURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*DeleteSilenceURL) SetBasePath

func (o *DeleteSilenceURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*DeleteSilenceURL) String

func (o *DeleteSilenceURL) String() string

String returns the string representation of the path with query string

func (*DeleteSilenceURL) StringFull

func (o *DeleteSilenceURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*DeleteSilenceURL) WithBasePath

func (o *DeleteSilenceURL) WithBasePath(bp string) *DeleteSilenceURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type GetSilence

GetSilence swagger:route GET /silence/{silenceID} silence getSilence

Get a silence by its ID

type GetSilence struct {
    Context *middleware.Context
    Handler GetSilenceHandler
}

func NewGetSilence

func NewGetSilence(ctx *middleware.Context, handler GetSilenceHandler) *GetSilence

NewGetSilence creates a new http.Handler for the get silence operation

func (*GetSilence) ServeHTTP

func (o *GetSilence) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type GetSilenceHandler

GetSilenceHandler interface for that can handle valid get silence params

type GetSilenceHandler interface {
    Handle(GetSilenceParams) middleware.Responder
}

type GetSilenceHandlerFunc

GetSilenceHandlerFunc turns a function with the right signature into a get silence handler

type GetSilenceHandlerFunc func(GetSilenceParams) middleware.Responder

func (GetSilenceHandlerFunc) Handle

func (fn GetSilenceHandlerFunc) Handle(params GetSilenceParams) middleware.Responder

Handle executing the request and returning a response

type GetSilenceInternalServerError

GetSilenceInternalServerError Internal server error

swagger:response getSilenceInternalServerError

type GetSilenceInternalServerError struct {

    /*
      In: Body
    */
    Payload string `json:"body,omitempty"`
}

func NewGetSilenceInternalServerError

func NewGetSilenceInternalServerError() *GetSilenceInternalServerError

NewGetSilenceInternalServerError creates GetSilenceInternalServerError with default headers values

func (*GetSilenceInternalServerError) SetPayload

func (o *GetSilenceInternalServerError) SetPayload(payload string)

SetPayload sets the payload to the get silence internal server error response

func (*GetSilenceInternalServerError) WithPayload

func (o *GetSilenceInternalServerError) WithPayload(payload string) *GetSilenceInternalServerError

WithPayload adds the payload to the get silence internal server error response

func (*GetSilenceInternalServerError) WriteResponse

func (o *GetSilenceInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetSilenceNotFound

GetSilenceNotFound A silence with the specified ID was not found

swagger:response getSilenceNotFound

type GetSilenceNotFound struct {
}

func NewGetSilenceNotFound

func NewGetSilenceNotFound() *GetSilenceNotFound

NewGetSilenceNotFound creates GetSilenceNotFound with default headers values

func (*GetSilenceNotFound) WriteResponse

func (o *GetSilenceNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetSilenceOK

GetSilenceOK Get silence response

swagger:response getSilenceOK

type GetSilenceOK struct {

    /*
      In: Body
    */
    Payload *models.GettableSilence `json:"body,omitempty"`
}

func NewGetSilenceOK

func NewGetSilenceOK() *GetSilenceOK

NewGetSilenceOK creates GetSilenceOK with default headers values

func (*GetSilenceOK) SetPayload

func (o *GetSilenceOK) SetPayload(payload *models.GettableSilence)

SetPayload sets the payload to the get silence o k response

func (*GetSilenceOK) WithPayload

func (o *GetSilenceOK) WithPayload(payload *models.GettableSilence) *GetSilenceOK

WithPayload adds the payload to the get silence o k response

func (*GetSilenceOK) WriteResponse

func (o *GetSilenceOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetSilenceParams

GetSilenceParams contains all the bound params for the get silence operation typically these are obtained from a http.Request

swagger:parameters getSilence

type GetSilenceParams struct {

    // HTTP Request Object
    HTTPRequest *http.Request `json:"-"`

    /*ID of the silence to get
      Required: true
      In: path
    */
    SilenceID strfmt.UUID
}

func NewGetSilenceParams

func NewGetSilenceParams() GetSilenceParams

NewGetSilenceParams creates a new GetSilenceParams object

There are no default values defined in the spec.

func (*GetSilenceParams) BindRequest

func (o *GetSilenceParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewGetSilenceParams() beforehand.

type GetSilenceURL

GetSilenceURL generates an URL for the get silence operation

type GetSilenceURL struct {
    SilenceID strfmt.UUID
    // contains filtered or unexported fields
}

func (*GetSilenceURL) Build

func (o *GetSilenceURL) Build() (*url.URL, error)

Build a url path and query string

func (*GetSilenceURL) BuildFull

func (o *GetSilenceURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*GetSilenceURL) Must

func (o *GetSilenceURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*GetSilenceURL) SetBasePath

func (o *GetSilenceURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*GetSilenceURL) String

func (o *GetSilenceURL) String() string

String returns the string representation of the path with query string

func (*GetSilenceURL) StringFull

func (o *GetSilenceURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*GetSilenceURL) WithBasePath

func (o *GetSilenceURL) WithBasePath(bp string) *GetSilenceURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type GetSilences

GetSilences swagger:route GET /silences silence getSilences

Get a list of silences

type GetSilences struct {
    Context *middleware.Context
    Handler GetSilencesHandler
}

func NewGetSilences

func NewGetSilences(ctx *middleware.Context, handler GetSilencesHandler) *GetSilences

NewGetSilences creates a new http.Handler for the get silences operation

func (*GetSilences) ServeHTTP

func (o *GetSilences) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type GetSilencesHandler

GetSilencesHandler interface for that can handle valid get silences params

type GetSilencesHandler interface {
    Handle(GetSilencesParams) middleware.Responder
}

type GetSilencesHandlerFunc

GetSilencesHandlerFunc turns a function with the right signature into a get silences handler

type GetSilencesHandlerFunc func(GetSilencesParams) middleware.Responder

func (GetSilencesHandlerFunc) Handle

func (fn GetSilencesHandlerFunc) Handle(params GetSilencesParams) middleware.Responder

Handle executing the request and returning a response

type GetSilencesInternalServerError

GetSilencesInternalServerError Internal server error

swagger:response getSilencesInternalServerError

type GetSilencesInternalServerError struct {

    /*
      In: Body
    */
    Payload string `json:"body,omitempty"`
}

func NewGetSilencesInternalServerError

func NewGetSilencesInternalServerError() *GetSilencesInternalServerError

NewGetSilencesInternalServerError creates GetSilencesInternalServerError with default headers values

func (*GetSilencesInternalServerError) SetPayload

func (o *GetSilencesInternalServerError) SetPayload(payload string)

SetPayload sets the payload to the get silences internal server error response

func (*GetSilencesInternalServerError) WithPayload

func (o *GetSilencesInternalServerError) WithPayload(payload string) *GetSilencesInternalServerError

WithPayload adds the payload to the get silences internal server error response

func (*GetSilencesInternalServerError) WriteResponse

func (o *GetSilencesInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetSilencesOK

GetSilencesOK Get silences response

swagger:response getSilencesOK

type GetSilencesOK struct {

    /*
      In: Body
    */
    Payload models.GettableSilences `json:"body,omitempty"`
}

func NewGetSilencesOK

func NewGetSilencesOK() *GetSilencesOK

NewGetSilencesOK creates GetSilencesOK with default headers values

func (*GetSilencesOK) SetPayload

func (o *GetSilencesOK) SetPayload(payload models.GettableSilences)

SetPayload sets the payload to the get silences o k response

func (*GetSilencesOK) WithPayload

func (o *GetSilencesOK) WithPayload(payload models.GettableSilences) *GetSilencesOK

WithPayload adds the payload to the get silences o k response

func (*GetSilencesOK) WriteResponse

func (o *GetSilencesOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetSilencesParams

GetSilencesParams contains all the bound params for the get silences operation typically these are obtained from a http.Request

swagger:parameters getSilences

type GetSilencesParams struct {

    // HTTP Request Object
    HTTPRequest *http.Request `json:"-"`

    /*A list of matchers to filter silences by
      In: query
      Collection Format: multi
    */
    Filter []string
}

func NewGetSilencesParams

func NewGetSilencesParams() GetSilencesParams

NewGetSilencesParams creates a new GetSilencesParams object

There are no default values defined in the spec.

func (*GetSilencesParams) BindRequest

func (o *GetSilencesParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewGetSilencesParams() beforehand.

type GetSilencesURL

GetSilencesURL generates an URL for the get silences operation

type GetSilencesURL struct {
    Filter []string
    // contains filtered or unexported fields
}

func (*GetSilencesURL) Build

func (o *GetSilencesURL) Build() (*url.URL, error)

Build a url path and query string

func (*GetSilencesURL) BuildFull

func (o *GetSilencesURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*GetSilencesURL) Must

func (o *GetSilencesURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*GetSilencesURL) SetBasePath

func (o *GetSilencesURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*GetSilencesURL) String

func (o *GetSilencesURL) String() string

String returns the string representation of the path with query string

func (*GetSilencesURL) StringFull

func (o *GetSilencesURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*GetSilencesURL) WithBasePath

func (o *GetSilencesURL) WithBasePath(bp string) *GetSilencesURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type PostSilences

PostSilences swagger:route POST /silences silence postSilences

Post a new silence or update an existing one

type PostSilences struct {
    Context *middleware.Context
    Handler PostSilencesHandler
}

func NewPostSilences

func NewPostSilences(ctx *middleware.Context, handler PostSilencesHandler) *PostSilences

NewPostSilences creates a new http.Handler for the post silences operation

func (*PostSilences) ServeHTTP

func (o *PostSilences) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type PostSilencesBadRequest

PostSilencesBadRequest Bad request

swagger:response postSilencesBadRequest

type PostSilencesBadRequest struct {

    /*
      In: Body
    */
    Payload string `json:"body,omitempty"`
}

func NewPostSilencesBadRequest

func NewPostSilencesBadRequest() *PostSilencesBadRequest

NewPostSilencesBadRequest creates PostSilencesBadRequest with default headers values

func (*PostSilencesBadRequest) SetPayload

func (o *PostSilencesBadRequest) SetPayload(payload string)

SetPayload sets the payload to the post silences bad request response

func (*PostSilencesBadRequest) WithPayload

func (o *PostSilencesBadRequest) WithPayload(payload string) *PostSilencesBadRequest

WithPayload adds the payload to the post silences bad request response

func (*PostSilencesBadRequest) WriteResponse

func (o *PostSilencesBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type PostSilencesHandler

PostSilencesHandler interface for that can handle valid post silences params

type PostSilencesHandler interface {
    Handle(PostSilencesParams) middleware.Responder
}

type PostSilencesHandlerFunc

PostSilencesHandlerFunc turns a function with the right signature into a post silences handler

type PostSilencesHandlerFunc func(PostSilencesParams) middleware.Responder

func (PostSilencesHandlerFunc) Handle

func (fn PostSilencesHandlerFunc) Handle(params PostSilencesParams) middleware.Responder

Handle executing the request and returning a response

type PostSilencesNotFound

PostSilencesNotFound A silence with the specified ID was not found

swagger:response postSilencesNotFound

type PostSilencesNotFound struct {

    /*
      In: Body
    */
    Payload string `json:"body,omitempty"`
}

func NewPostSilencesNotFound

func NewPostSilencesNotFound() *PostSilencesNotFound

NewPostSilencesNotFound creates PostSilencesNotFound with default headers values

func (*PostSilencesNotFound) SetPayload

func (o *PostSilencesNotFound) SetPayload(payload string)

SetPayload sets the payload to the post silences not found response

func (*PostSilencesNotFound) WithPayload

func (o *PostSilencesNotFound) WithPayload(payload string) *PostSilencesNotFound

WithPayload adds the payload to the post silences not found response

func (*PostSilencesNotFound) WriteResponse

func (o *PostSilencesNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type PostSilencesOK

PostSilencesOK Create / update silence response

swagger:response postSilencesOK

type PostSilencesOK struct {

    /*
      In: Body
    */
    Payload *PostSilencesOKBody `json:"body,omitempty"`
}

func NewPostSilencesOK

func NewPostSilencesOK() *PostSilencesOK

NewPostSilencesOK creates PostSilencesOK with default headers values

func (*PostSilencesOK) SetPayload

func (o *PostSilencesOK) SetPayload(payload *PostSilencesOKBody)

SetPayload sets the payload to the post silences o k response

func (*PostSilencesOK) WithPayload

func (o *PostSilencesOK) WithPayload(payload *PostSilencesOKBody) *PostSilencesOK

WithPayload adds the payload to the post silences o k response

func (*PostSilencesOK) WriteResponse

func (o *PostSilencesOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type PostSilencesOKBody

PostSilencesOKBody post silences o k body

swagger:model PostSilencesOKBody

type PostSilencesOKBody struct {

    // silence ID
    SilenceID string `json:"silenceID,omitempty"`
}

func (*PostSilencesOKBody) ContextValidate

func (o *PostSilencesOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this post silences o k body based on context it is used

func (*PostSilencesOKBody) MarshalBinary

func (o *PostSilencesOKBody) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*PostSilencesOKBody) UnmarshalBinary

func (o *PostSilencesOKBody) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*PostSilencesOKBody) Validate

func (o *PostSilencesOKBody) Validate(formats strfmt.Registry) error

Validate validates this post silences o k body

type PostSilencesParams

PostSilencesParams contains all the bound params for the post silences operation typically these are obtained from a http.Request

swagger:parameters postSilences

type PostSilencesParams struct {

    // HTTP Request Object
    HTTPRequest *http.Request `json:"-"`

    /*The silence to create
      Required: true
      In: body
    */
    Silence *models.PostableSilence
}

func NewPostSilencesParams

func NewPostSilencesParams() PostSilencesParams

NewPostSilencesParams creates a new PostSilencesParams object

There are no default values defined in the spec.

func (*PostSilencesParams) BindRequest

func (o *PostSilencesParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewPostSilencesParams() beforehand.

type PostSilencesURL

PostSilencesURL generates an URL for the post silences operation

type PostSilencesURL struct {
    // contains filtered or unexported fields
}

func (*PostSilencesURL) Build

func (o *PostSilencesURL) Build() (*url.URL, error)

Build a url path and query string

func (*PostSilencesURL) BuildFull

func (o *PostSilencesURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*PostSilencesURL) Must

func (o *PostSilencesURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*PostSilencesURL) SetBasePath

func (o *PostSilencesURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*PostSilencesURL) String

func (o *PostSilencesURL) String() string

String returns the string representation of the path with query string

func (*PostSilencesURL) StringFull

func (o *PostSilencesURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*PostSilencesURL) WithBasePath

func (o *PostSilencesURL) WithBasePath(bp string) *PostSilencesURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string