...

Package silence

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

Overview ▾

Index ▾

type Client
    func (a *Client) DeleteSilence(params *DeleteSilenceParams, opts ...ClientOption) (*DeleteSilenceOK, error)
    func (a *Client) GetSilence(params *GetSilenceParams, opts ...ClientOption) (*GetSilenceOK, error)
    func (a *Client) GetSilences(params *GetSilencesParams, opts ...ClientOption) (*GetSilencesOK, error)
    func (a *Client) PostSilences(params *PostSilencesParams, opts ...ClientOption) (*PostSilencesOK, error)
    func (a *Client) SetTransport(transport runtime.ClientTransport)
type ClientOption
type ClientService
    func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService
type DeleteSilenceInternalServerError
    func NewDeleteSilenceInternalServerError() *DeleteSilenceInternalServerError
    func (o *DeleteSilenceInternalServerError) Error() string
    func (o *DeleteSilenceInternalServerError) GetPayload() string
    func (o *DeleteSilenceInternalServerError) IsClientError() bool
    func (o *DeleteSilenceInternalServerError) IsCode(code int) bool
    func (o *DeleteSilenceInternalServerError) IsRedirect() bool
    func (o *DeleteSilenceInternalServerError) IsServerError() bool
    func (o *DeleteSilenceInternalServerError) IsSuccess() bool
    func (o *DeleteSilenceInternalServerError) String() string
type DeleteSilenceOK
    func NewDeleteSilenceOK() *DeleteSilenceOK
    func (o *DeleteSilenceOK) Error() string
    func (o *DeleteSilenceOK) IsClientError() bool
    func (o *DeleteSilenceOK) IsCode(code int) bool
    func (o *DeleteSilenceOK) IsRedirect() bool
    func (o *DeleteSilenceOK) IsServerError() bool
    func (o *DeleteSilenceOK) IsSuccess() bool
    func (o *DeleteSilenceOK) String() string
type DeleteSilenceParams
    func NewDeleteSilenceParams() *DeleteSilenceParams
    func NewDeleteSilenceParamsWithContext(ctx context.Context) *DeleteSilenceParams
    func NewDeleteSilenceParamsWithHTTPClient(client *http.Client) *DeleteSilenceParams
    func NewDeleteSilenceParamsWithTimeout(timeout time.Duration) *DeleteSilenceParams
    func (o *DeleteSilenceParams) SetContext(ctx context.Context)
    func (o *DeleteSilenceParams) SetDefaults()
    func (o *DeleteSilenceParams) SetHTTPClient(client *http.Client)
    func (o *DeleteSilenceParams) SetSilenceID(silenceID strfmt.UUID)
    func (o *DeleteSilenceParams) SetTimeout(timeout time.Duration)
    func (o *DeleteSilenceParams) WithContext(ctx context.Context) *DeleteSilenceParams
    func (o *DeleteSilenceParams) WithDefaults() *DeleteSilenceParams
    func (o *DeleteSilenceParams) WithHTTPClient(client *http.Client) *DeleteSilenceParams
    func (o *DeleteSilenceParams) WithSilenceID(silenceID strfmt.UUID) *DeleteSilenceParams
    func (o *DeleteSilenceParams) WithTimeout(timeout time.Duration) *DeleteSilenceParams
    func (o *DeleteSilenceParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
type DeleteSilenceReader
    func (o *DeleteSilenceReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
type GetSilenceInternalServerError
    func NewGetSilenceInternalServerError() *GetSilenceInternalServerError
    func (o *GetSilenceInternalServerError) Error() string
    func (o *GetSilenceInternalServerError) GetPayload() string
    func (o *GetSilenceInternalServerError) IsClientError() bool
    func (o *GetSilenceInternalServerError) IsCode(code int) bool
    func (o *GetSilenceInternalServerError) IsRedirect() bool
    func (o *GetSilenceInternalServerError) IsServerError() bool
    func (o *GetSilenceInternalServerError) IsSuccess() bool
    func (o *GetSilenceInternalServerError) String() string
type GetSilenceNotFound
    func NewGetSilenceNotFound() *GetSilenceNotFound
    func (o *GetSilenceNotFound) Error() string
    func (o *GetSilenceNotFound) IsClientError() bool
    func (o *GetSilenceNotFound) IsCode(code int) bool
    func (o *GetSilenceNotFound) IsRedirect() bool
    func (o *GetSilenceNotFound) IsServerError() bool
    func (o *GetSilenceNotFound) IsSuccess() bool
    func (o *GetSilenceNotFound) String() string
type GetSilenceOK
    func NewGetSilenceOK() *GetSilenceOK
    func (o *GetSilenceOK) Error() string
    func (o *GetSilenceOK) GetPayload() *models.GettableSilence
    func (o *GetSilenceOK) IsClientError() bool
    func (o *GetSilenceOK) IsCode(code int) bool
    func (o *GetSilenceOK) IsRedirect() bool
    func (o *GetSilenceOK) IsServerError() bool
    func (o *GetSilenceOK) IsSuccess() bool
    func (o *GetSilenceOK) String() string
type GetSilenceParams
    func NewGetSilenceParams() *GetSilenceParams
    func NewGetSilenceParamsWithContext(ctx context.Context) *GetSilenceParams
    func NewGetSilenceParamsWithHTTPClient(client *http.Client) *GetSilenceParams
    func NewGetSilenceParamsWithTimeout(timeout time.Duration) *GetSilenceParams
    func (o *GetSilenceParams) SetContext(ctx context.Context)
    func (o *GetSilenceParams) SetDefaults()
    func (o *GetSilenceParams) SetHTTPClient(client *http.Client)
    func (o *GetSilenceParams) SetSilenceID(silenceID strfmt.UUID)
    func (o *GetSilenceParams) SetTimeout(timeout time.Duration)
    func (o *GetSilenceParams) WithContext(ctx context.Context) *GetSilenceParams
    func (o *GetSilenceParams) WithDefaults() *GetSilenceParams
    func (o *GetSilenceParams) WithHTTPClient(client *http.Client) *GetSilenceParams
    func (o *GetSilenceParams) WithSilenceID(silenceID strfmt.UUID) *GetSilenceParams
    func (o *GetSilenceParams) WithTimeout(timeout time.Duration) *GetSilenceParams
    func (o *GetSilenceParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
type GetSilenceReader
    func (o *GetSilenceReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
type GetSilencesInternalServerError
    func NewGetSilencesInternalServerError() *GetSilencesInternalServerError
    func (o *GetSilencesInternalServerError) Error() string
    func (o *GetSilencesInternalServerError) GetPayload() string
    func (o *GetSilencesInternalServerError) IsClientError() bool
    func (o *GetSilencesInternalServerError) IsCode(code int) bool
    func (o *GetSilencesInternalServerError) IsRedirect() bool
    func (o *GetSilencesInternalServerError) IsServerError() bool
    func (o *GetSilencesInternalServerError) IsSuccess() bool
    func (o *GetSilencesInternalServerError) String() string
type GetSilencesOK
    func NewGetSilencesOK() *GetSilencesOK
    func (o *GetSilencesOK) Error() string
    func (o *GetSilencesOK) GetPayload() models.GettableSilences
    func (o *GetSilencesOK) IsClientError() bool
    func (o *GetSilencesOK) IsCode(code int) bool
    func (o *GetSilencesOK) IsRedirect() bool
    func (o *GetSilencesOK) IsServerError() bool
    func (o *GetSilencesOK) IsSuccess() bool
    func (o *GetSilencesOK) String() string
type GetSilencesParams
    func NewGetSilencesParams() *GetSilencesParams
    func NewGetSilencesParamsWithContext(ctx context.Context) *GetSilencesParams
    func NewGetSilencesParamsWithHTTPClient(client *http.Client) *GetSilencesParams
    func NewGetSilencesParamsWithTimeout(timeout time.Duration) *GetSilencesParams
    func (o *GetSilencesParams) SetContext(ctx context.Context)
    func (o *GetSilencesParams) SetDefaults()
    func (o *GetSilencesParams) SetFilter(filter []string)
    func (o *GetSilencesParams) SetHTTPClient(client *http.Client)
    func (o *GetSilencesParams) SetTimeout(timeout time.Duration)
    func (o *GetSilencesParams) WithContext(ctx context.Context) *GetSilencesParams
    func (o *GetSilencesParams) WithDefaults() *GetSilencesParams
    func (o *GetSilencesParams) WithFilter(filter []string) *GetSilencesParams
    func (o *GetSilencesParams) WithHTTPClient(client *http.Client) *GetSilencesParams
    func (o *GetSilencesParams) WithTimeout(timeout time.Duration) *GetSilencesParams
    func (o *GetSilencesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
type GetSilencesReader
    func (o *GetSilencesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
type PostSilencesBadRequest
    func NewPostSilencesBadRequest() *PostSilencesBadRequest
    func (o *PostSilencesBadRequest) Error() string
    func (o *PostSilencesBadRequest) GetPayload() string
    func (o *PostSilencesBadRequest) IsClientError() bool
    func (o *PostSilencesBadRequest) IsCode(code int) bool
    func (o *PostSilencesBadRequest) IsRedirect() bool
    func (o *PostSilencesBadRequest) IsServerError() bool
    func (o *PostSilencesBadRequest) IsSuccess() bool
    func (o *PostSilencesBadRequest) String() string
type PostSilencesNotFound
    func NewPostSilencesNotFound() *PostSilencesNotFound
    func (o *PostSilencesNotFound) Error() string
    func (o *PostSilencesNotFound) GetPayload() string
    func (o *PostSilencesNotFound) IsClientError() bool
    func (o *PostSilencesNotFound) IsCode(code int) bool
    func (o *PostSilencesNotFound) IsRedirect() bool
    func (o *PostSilencesNotFound) IsServerError() bool
    func (o *PostSilencesNotFound) IsSuccess() bool
    func (o *PostSilencesNotFound) String() string
type PostSilencesOK
    func NewPostSilencesOK() *PostSilencesOK
    func (o *PostSilencesOK) Error() string
    func (o *PostSilencesOK) GetPayload() *PostSilencesOKBody
    func (o *PostSilencesOK) IsClientError() bool
    func (o *PostSilencesOK) IsCode(code int) bool
    func (o *PostSilencesOK) IsRedirect() bool
    func (o *PostSilencesOK) IsServerError() bool
    func (o *PostSilencesOK) IsSuccess() bool
    func (o *PostSilencesOK) String() string
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 NewPostSilencesParamsWithContext(ctx context.Context) *PostSilencesParams
    func NewPostSilencesParamsWithHTTPClient(client *http.Client) *PostSilencesParams
    func NewPostSilencesParamsWithTimeout(timeout time.Duration) *PostSilencesParams
    func (o *PostSilencesParams) SetContext(ctx context.Context)
    func (o *PostSilencesParams) SetDefaults()
    func (o *PostSilencesParams) SetHTTPClient(client *http.Client)
    func (o *PostSilencesParams) SetSilence(silence *models.PostableSilence)
    func (o *PostSilencesParams) SetTimeout(timeout time.Duration)
    func (o *PostSilencesParams) WithContext(ctx context.Context) *PostSilencesParams
    func (o *PostSilencesParams) WithDefaults() *PostSilencesParams
    func (o *PostSilencesParams) WithHTTPClient(client *http.Client) *PostSilencesParams
    func (o *PostSilencesParams) WithSilence(silence *models.PostableSilence) *PostSilencesParams
    func (o *PostSilencesParams) WithTimeout(timeout time.Duration) *PostSilencesParams
    func (o *PostSilencesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
type PostSilencesReader
    func (o *PostSilencesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

Package files

delete_silence_parameters.go delete_silence_responses.go get_silence_parameters.go get_silence_responses.go get_silences_parameters.go get_silences_responses.go post_silences_parameters.go post_silences_responses.go silence_client.go

type Client

Client for silence API

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

func (*Client) DeleteSilence

func (a *Client) DeleteSilence(params *DeleteSilenceParams, opts ...ClientOption) (*DeleteSilenceOK, error)

DeleteSilence Delete a silence by its ID

func (*Client) GetSilence

func (a *Client) GetSilence(params *GetSilenceParams, opts ...ClientOption) (*GetSilenceOK, error)

GetSilence Get a silence by its ID

func (*Client) GetSilences

func (a *Client) GetSilences(params *GetSilencesParams, opts ...ClientOption) (*GetSilencesOK, error)

GetSilences Get a list of silences

func (*Client) PostSilences

func (a *Client) PostSilences(params *PostSilencesParams, opts ...ClientOption) (*PostSilencesOK, error)

PostSilences Post a new silence or update an existing one

func (*Client) SetTransport

func (a *Client) SetTransport(transport runtime.ClientTransport)

SetTransport changes the transport on the client

type ClientOption

ClientOption is the option for Client methods

type ClientOption func(*runtime.ClientOperation)

type ClientService

ClientService is the interface for Client methods

type ClientService interface {
    DeleteSilence(params *DeleteSilenceParams, opts ...ClientOption) (*DeleteSilenceOK, error)

    GetSilence(params *GetSilenceParams, opts ...ClientOption) (*GetSilenceOK, error)

    GetSilences(params *GetSilencesParams, opts ...ClientOption) (*GetSilencesOK, error)

    PostSilences(params *PostSilencesParams, opts ...ClientOption) (*PostSilencesOK, error)

    SetTransport(transport runtime.ClientTransport)
}

func New

func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService

New creates a new silence API client.

type DeleteSilenceInternalServerError

DeleteSilenceInternalServerError describes a response with status code 500, with default header values.

Internal server error

type DeleteSilenceInternalServerError struct {
    Payload string
}

func NewDeleteSilenceInternalServerError

func NewDeleteSilenceInternalServerError() *DeleteSilenceInternalServerError

NewDeleteSilenceInternalServerError creates a DeleteSilenceInternalServerError with default headers values

func (*DeleteSilenceInternalServerError) Error

func (o *DeleteSilenceInternalServerError) Error() string

func (*DeleteSilenceInternalServerError) GetPayload

func (o *DeleteSilenceInternalServerError) GetPayload() string

func (*DeleteSilenceInternalServerError) IsClientError

func (o *DeleteSilenceInternalServerError) IsClientError() bool

IsClientError returns true when this delete silence internal server error response has a 4xx status code

func (*DeleteSilenceInternalServerError) IsCode

func (o *DeleteSilenceInternalServerError) IsCode(code int) bool

IsCode returns true when this delete silence internal server error response a status code equal to that given

func (*DeleteSilenceInternalServerError) IsRedirect

func (o *DeleteSilenceInternalServerError) IsRedirect() bool

IsRedirect returns true when this delete silence internal server error response has a 3xx status code

func (*DeleteSilenceInternalServerError) IsServerError

func (o *DeleteSilenceInternalServerError) IsServerError() bool

IsServerError returns true when this delete silence internal server error response has a 5xx status code

func (*DeleteSilenceInternalServerError) IsSuccess

func (o *DeleteSilenceInternalServerError) IsSuccess() bool

IsSuccess returns true when this delete silence internal server error response has a 2xx status code

func (*DeleteSilenceInternalServerError) String

func (o *DeleteSilenceInternalServerError) String() string

type DeleteSilenceOK

DeleteSilenceOK describes a response with status code 200, with default header values.

Delete silence response

type DeleteSilenceOK struct {
}

func NewDeleteSilenceOK

func NewDeleteSilenceOK() *DeleteSilenceOK

NewDeleteSilenceOK creates a DeleteSilenceOK with default headers values

func (*DeleteSilenceOK) Error

func (o *DeleteSilenceOK) Error() string

func (*DeleteSilenceOK) IsClientError

func (o *DeleteSilenceOK) IsClientError() bool

IsClientError returns true when this delete silence o k response has a 4xx status code

func (*DeleteSilenceOK) IsCode

func (o *DeleteSilenceOK) IsCode(code int) bool

IsCode returns true when this delete silence o k response a status code equal to that given

func (*DeleteSilenceOK) IsRedirect

func (o *DeleteSilenceOK) IsRedirect() bool

IsRedirect returns true when this delete silence o k response has a 3xx status code

func (*DeleteSilenceOK) IsServerError

func (o *DeleteSilenceOK) IsServerError() bool

IsServerError returns true when this delete silence o k response has a 5xx status code

func (*DeleteSilenceOK) IsSuccess

func (o *DeleteSilenceOK) IsSuccess() bool

IsSuccess returns true when this delete silence o k response has a 2xx status code

func (*DeleteSilenceOK) String

func (o *DeleteSilenceOK) String() string

type DeleteSilenceParams

DeleteSilenceParams contains all the parameters to send to the API endpoint

for the delete silence operation.

Typically these are written to a http.Request.
type DeleteSilenceParams struct {

    /* SilenceID.

       ID of the silence to get

       Format: uuid
    */
    SilenceID strfmt.UUID

    Context    context.Context
    HTTPClient *http.Client
    // contains filtered or unexported fields
}

func NewDeleteSilenceParams

func NewDeleteSilenceParams() *DeleteSilenceParams

NewDeleteSilenceParams creates a new DeleteSilenceParams object, with the default timeout for this client.

Default values are not hydrated, since defaults are normally applied by the API server side.

To enforce default values in parameter, use SetDefaults or WithDefaults.

func NewDeleteSilenceParamsWithContext

func NewDeleteSilenceParamsWithContext(ctx context.Context) *DeleteSilenceParams

NewDeleteSilenceParamsWithContext creates a new DeleteSilenceParams object with the ability to set a context for a request.

func NewDeleteSilenceParamsWithHTTPClient

func NewDeleteSilenceParamsWithHTTPClient(client *http.Client) *DeleteSilenceParams

NewDeleteSilenceParamsWithHTTPClient creates a new DeleteSilenceParams object with the ability to set a custom HTTPClient for a request.

func NewDeleteSilenceParamsWithTimeout

func NewDeleteSilenceParamsWithTimeout(timeout time.Duration) *DeleteSilenceParams

NewDeleteSilenceParamsWithTimeout creates a new DeleteSilenceParams object with the ability to set a timeout on a request.

func (*DeleteSilenceParams) SetContext

func (o *DeleteSilenceParams) SetContext(ctx context.Context)

SetContext adds the context to the delete silence params

func (*DeleteSilenceParams) SetDefaults

func (o *DeleteSilenceParams) SetDefaults()

SetDefaults hydrates default values in the delete silence params (not the query body).

All values with no default are reset to their zero value.

func (*DeleteSilenceParams) SetHTTPClient

func (o *DeleteSilenceParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the delete silence params

func (*DeleteSilenceParams) SetSilenceID

func (o *DeleteSilenceParams) SetSilenceID(silenceID strfmt.UUID)

SetSilenceID adds the silenceId to the delete silence params

func (*DeleteSilenceParams) SetTimeout

func (o *DeleteSilenceParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the delete silence params

func (*DeleteSilenceParams) WithContext

func (o *DeleteSilenceParams) WithContext(ctx context.Context) *DeleteSilenceParams

WithContext adds the context to the delete silence params

func (*DeleteSilenceParams) WithDefaults

func (o *DeleteSilenceParams) WithDefaults() *DeleteSilenceParams

WithDefaults hydrates default values in the delete silence params (not the query body).

All values with no default are reset to their zero value.

func (*DeleteSilenceParams) WithHTTPClient

func (o *DeleteSilenceParams) WithHTTPClient(client *http.Client) *DeleteSilenceParams

WithHTTPClient adds the HTTPClient to the delete silence params

func (*DeleteSilenceParams) WithSilenceID

func (o *DeleteSilenceParams) WithSilenceID(silenceID strfmt.UUID) *DeleteSilenceParams

WithSilenceID adds the silenceID to the delete silence params

func (*DeleteSilenceParams) WithTimeout

func (o *DeleteSilenceParams) WithTimeout(timeout time.Duration) *DeleteSilenceParams

WithTimeout adds the timeout to the delete silence params

func (*DeleteSilenceParams) WriteToRequest

func (o *DeleteSilenceParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type DeleteSilenceReader

DeleteSilenceReader is a Reader for the DeleteSilence structure.

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

func (*DeleteSilenceReader) ReadResponse

func (o *DeleteSilenceReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

type GetSilenceInternalServerError

GetSilenceInternalServerError describes a response with status code 500, with default header values.

Internal server error

type GetSilenceInternalServerError struct {
    Payload string
}

func NewGetSilenceInternalServerError

func NewGetSilenceInternalServerError() *GetSilenceInternalServerError

NewGetSilenceInternalServerError creates a GetSilenceInternalServerError with default headers values

func (*GetSilenceInternalServerError) Error

func (o *GetSilenceInternalServerError) Error() string

func (*GetSilenceInternalServerError) GetPayload

func (o *GetSilenceInternalServerError) GetPayload() string

func (*GetSilenceInternalServerError) IsClientError

func (o *GetSilenceInternalServerError) IsClientError() bool

IsClientError returns true when this get silence internal server error response has a 4xx status code

func (*GetSilenceInternalServerError) IsCode

func (o *GetSilenceInternalServerError) IsCode(code int) bool

IsCode returns true when this get silence internal server error response a status code equal to that given

func (*GetSilenceInternalServerError) IsRedirect

func (o *GetSilenceInternalServerError) IsRedirect() bool

IsRedirect returns true when this get silence internal server error response has a 3xx status code

func (*GetSilenceInternalServerError) IsServerError

func (o *GetSilenceInternalServerError) IsServerError() bool

IsServerError returns true when this get silence internal server error response has a 5xx status code

func (*GetSilenceInternalServerError) IsSuccess

func (o *GetSilenceInternalServerError) IsSuccess() bool

IsSuccess returns true when this get silence internal server error response has a 2xx status code

func (*GetSilenceInternalServerError) String

func (o *GetSilenceInternalServerError) String() string

type GetSilenceNotFound

GetSilenceNotFound describes a response with status code 404, with default header values.

A silence with the specified ID was not found

type GetSilenceNotFound struct {
}

func NewGetSilenceNotFound

func NewGetSilenceNotFound() *GetSilenceNotFound

NewGetSilenceNotFound creates a GetSilenceNotFound with default headers values

func (*GetSilenceNotFound) Error

func (o *GetSilenceNotFound) Error() string

func (*GetSilenceNotFound) IsClientError

func (o *GetSilenceNotFound) IsClientError() bool

IsClientError returns true when this get silence not found response has a 4xx status code

func (*GetSilenceNotFound) IsCode

func (o *GetSilenceNotFound) IsCode(code int) bool

IsCode returns true when this get silence not found response a status code equal to that given

func (*GetSilenceNotFound) IsRedirect

func (o *GetSilenceNotFound) IsRedirect() bool

IsRedirect returns true when this get silence not found response has a 3xx status code

func (*GetSilenceNotFound) IsServerError

func (o *GetSilenceNotFound) IsServerError() bool

IsServerError returns true when this get silence not found response has a 5xx status code

func (*GetSilenceNotFound) IsSuccess

func (o *GetSilenceNotFound) IsSuccess() bool

IsSuccess returns true when this get silence not found response has a 2xx status code

func (*GetSilenceNotFound) String

func (o *GetSilenceNotFound) String() string

type GetSilenceOK

GetSilenceOK describes a response with status code 200, with default header values.

Get silence response

type GetSilenceOK struct {
    Payload *models.GettableSilence
}

func NewGetSilenceOK

func NewGetSilenceOK() *GetSilenceOK

NewGetSilenceOK creates a GetSilenceOK with default headers values

func (*GetSilenceOK) Error

func (o *GetSilenceOK) Error() string

func (*GetSilenceOK) GetPayload

func (o *GetSilenceOK) GetPayload() *models.GettableSilence

func (*GetSilenceOK) IsClientError

func (o *GetSilenceOK) IsClientError() bool

IsClientError returns true when this get silence o k response has a 4xx status code

func (*GetSilenceOK) IsCode

func (o *GetSilenceOK) IsCode(code int) bool

IsCode returns true when this get silence o k response a status code equal to that given

func (*GetSilenceOK) IsRedirect

func (o *GetSilenceOK) IsRedirect() bool

IsRedirect returns true when this get silence o k response has a 3xx status code

func (*GetSilenceOK) IsServerError

func (o *GetSilenceOK) IsServerError() bool

IsServerError returns true when this get silence o k response has a 5xx status code

func (*GetSilenceOK) IsSuccess

func (o *GetSilenceOK) IsSuccess() bool

IsSuccess returns true when this get silence o k response has a 2xx status code

func (*GetSilenceOK) String

func (o *GetSilenceOK) String() string

type GetSilenceParams

GetSilenceParams contains all the parameters to send to the API endpoint

for the get silence operation.

Typically these are written to a http.Request.
type GetSilenceParams struct {

    /* SilenceID.

       ID of the silence to get

       Format: uuid
    */
    SilenceID strfmt.UUID

    Context    context.Context
    HTTPClient *http.Client
    // contains filtered or unexported fields
}

func NewGetSilenceParams

func NewGetSilenceParams() *GetSilenceParams

NewGetSilenceParams creates a new GetSilenceParams object, with the default timeout for this client.

Default values are not hydrated, since defaults are normally applied by the API server side.

To enforce default values in parameter, use SetDefaults or WithDefaults.

func NewGetSilenceParamsWithContext

func NewGetSilenceParamsWithContext(ctx context.Context) *GetSilenceParams

NewGetSilenceParamsWithContext creates a new GetSilenceParams object with the ability to set a context for a request.

func NewGetSilenceParamsWithHTTPClient

func NewGetSilenceParamsWithHTTPClient(client *http.Client) *GetSilenceParams

NewGetSilenceParamsWithHTTPClient creates a new GetSilenceParams object with the ability to set a custom HTTPClient for a request.

func NewGetSilenceParamsWithTimeout

func NewGetSilenceParamsWithTimeout(timeout time.Duration) *GetSilenceParams

NewGetSilenceParamsWithTimeout creates a new GetSilenceParams object with the ability to set a timeout on a request.

func (*GetSilenceParams) SetContext

func (o *GetSilenceParams) SetContext(ctx context.Context)

SetContext adds the context to the get silence params

func (*GetSilenceParams) SetDefaults

func (o *GetSilenceParams) SetDefaults()

SetDefaults hydrates default values in the get silence params (not the query body).

All values with no default are reset to their zero value.

func (*GetSilenceParams) SetHTTPClient

func (o *GetSilenceParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the get silence params

func (*GetSilenceParams) SetSilenceID

func (o *GetSilenceParams) SetSilenceID(silenceID strfmt.UUID)

SetSilenceID adds the silenceId to the get silence params

func (*GetSilenceParams) SetTimeout

func (o *GetSilenceParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the get silence params

func (*GetSilenceParams) WithContext

func (o *GetSilenceParams) WithContext(ctx context.Context) *GetSilenceParams

WithContext adds the context to the get silence params

func (*GetSilenceParams) WithDefaults

func (o *GetSilenceParams) WithDefaults() *GetSilenceParams

WithDefaults hydrates default values in the get silence params (not the query body).

All values with no default are reset to their zero value.

func (*GetSilenceParams) WithHTTPClient

func (o *GetSilenceParams) WithHTTPClient(client *http.Client) *GetSilenceParams

WithHTTPClient adds the HTTPClient to the get silence params

func (*GetSilenceParams) WithSilenceID

func (o *GetSilenceParams) WithSilenceID(silenceID strfmt.UUID) *GetSilenceParams

WithSilenceID adds the silenceID to the get silence params

func (*GetSilenceParams) WithTimeout

func (o *GetSilenceParams) WithTimeout(timeout time.Duration) *GetSilenceParams

WithTimeout adds the timeout to the get silence params

func (*GetSilenceParams) WriteToRequest

func (o *GetSilenceParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type GetSilenceReader

GetSilenceReader is a Reader for the GetSilence structure.

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

func (*GetSilenceReader) ReadResponse

func (o *GetSilenceReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

type GetSilencesInternalServerError

GetSilencesInternalServerError describes a response with status code 500, with default header values.

Internal server error

type GetSilencesInternalServerError struct {
    Payload string
}

func NewGetSilencesInternalServerError

func NewGetSilencesInternalServerError() *GetSilencesInternalServerError

NewGetSilencesInternalServerError creates a GetSilencesInternalServerError with default headers values

func (*GetSilencesInternalServerError) Error

func (o *GetSilencesInternalServerError) Error() string

func (*GetSilencesInternalServerError) GetPayload

func (o *GetSilencesInternalServerError) GetPayload() string

func (*GetSilencesInternalServerError) IsClientError

func (o *GetSilencesInternalServerError) IsClientError() bool

IsClientError returns true when this get silences internal server error response has a 4xx status code

func (*GetSilencesInternalServerError) IsCode

func (o *GetSilencesInternalServerError) IsCode(code int) bool

IsCode returns true when this get silences internal server error response a status code equal to that given

func (*GetSilencesInternalServerError) IsRedirect

func (o *GetSilencesInternalServerError) IsRedirect() bool

IsRedirect returns true when this get silences internal server error response has a 3xx status code

func (*GetSilencesInternalServerError) IsServerError

func (o *GetSilencesInternalServerError) IsServerError() bool

IsServerError returns true when this get silences internal server error response has a 5xx status code

func (*GetSilencesInternalServerError) IsSuccess

func (o *GetSilencesInternalServerError) IsSuccess() bool

IsSuccess returns true when this get silences internal server error response has a 2xx status code

func (*GetSilencesInternalServerError) String

func (o *GetSilencesInternalServerError) String() string

type GetSilencesOK

GetSilencesOK describes a response with status code 200, with default header values.

Get silences response

type GetSilencesOK struct {
    Payload models.GettableSilences
}

func NewGetSilencesOK

func NewGetSilencesOK() *GetSilencesOK

NewGetSilencesOK creates a GetSilencesOK with default headers values

func (*GetSilencesOK) Error

func (o *GetSilencesOK) Error() string

func (*GetSilencesOK) GetPayload

func (o *GetSilencesOK) GetPayload() models.GettableSilences

func (*GetSilencesOK) IsClientError

func (o *GetSilencesOK) IsClientError() bool

IsClientError returns true when this get silences o k response has a 4xx status code

func (*GetSilencesOK) IsCode

func (o *GetSilencesOK) IsCode(code int) bool

IsCode returns true when this get silences o k response a status code equal to that given

func (*GetSilencesOK) IsRedirect

func (o *GetSilencesOK) IsRedirect() bool

IsRedirect returns true when this get silences o k response has a 3xx status code

func (*GetSilencesOK) IsServerError

func (o *GetSilencesOK) IsServerError() bool

IsServerError returns true when this get silences o k response has a 5xx status code

func (*GetSilencesOK) IsSuccess

func (o *GetSilencesOK) IsSuccess() bool

IsSuccess returns true when this get silences o k response has a 2xx status code

func (*GetSilencesOK) String

func (o *GetSilencesOK) String() string

type GetSilencesParams

GetSilencesParams contains all the parameters to send to the API endpoint

for the get silences operation.

Typically these are written to a http.Request.
type GetSilencesParams struct {

    /* Filter.

       A list of matchers to filter silences by
    */
    Filter []string

    Context    context.Context
    HTTPClient *http.Client
    // contains filtered or unexported fields
}

func NewGetSilencesParams

func NewGetSilencesParams() *GetSilencesParams

NewGetSilencesParams creates a new GetSilencesParams object, with the default timeout for this client.

Default values are not hydrated, since defaults are normally applied by the API server side.

To enforce default values in parameter, use SetDefaults or WithDefaults.

func NewGetSilencesParamsWithContext

func NewGetSilencesParamsWithContext(ctx context.Context) *GetSilencesParams

NewGetSilencesParamsWithContext creates a new GetSilencesParams object with the ability to set a context for a request.

func NewGetSilencesParamsWithHTTPClient

func NewGetSilencesParamsWithHTTPClient(client *http.Client) *GetSilencesParams

NewGetSilencesParamsWithHTTPClient creates a new GetSilencesParams object with the ability to set a custom HTTPClient for a request.

func NewGetSilencesParamsWithTimeout

func NewGetSilencesParamsWithTimeout(timeout time.Duration) *GetSilencesParams

NewGetSilencesParamsWithTimeout creates a new GetSilencesParams object with the ability to set a timeout on a request.

func (*GetSilencesParams) SetContext

func (o *GetSilencesParams) SetContext(ctx context.Context)

SetContext adds the context to the get silences params

func (*GetSilencesParams) SetDefaults

func (o *GetSilencesParams) SetDefaults()

SetDefaults hydrates default values in the get silences params (not the query body).

All values with no default are reset to their zero value.

func (*GetSilencesParams) SetFilter

func (o *GetSilencesParams) SetFilter(filter []string)

SetFilter adds the filter to the get silences params

func (*GetSilencesParams) SetHTTPClient

func (o *GetSilencesParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the get silences params

func (*GetSilencesParams) SetTimeout

func (o *GetSilencesParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the get silences params

func (*GetSilencesParams) WithContext

func (o *GetSilencesParams) WithContext(ctx context.Context) *GetSilencesParams

WithContext adds the context to the get silences params

func (*GetSilencesParams) WithDefaults

func (o *GetSilencesParams) WithDefaults() *GetSilencesParams

WithDefaults hydrates default values in the get silences params (not the query body).

All values with no default are reset to their zero value.

func (*GetSilencesParams) WithFilter

func (o *GetSilencesParams) WithFilter(filter []string) *GetSilencesParams

WithFilter adds the filter to the get silences params

func (*GetSilencesParams) WithHTTPClient

func (o *GetSilencesParams) WithHTTPClient(client *http.Client) *GetSilencesParams

WithHTTPClient adds the HTTPClient to the get silences params

func (*GetSilencesParams) WithTimeout

func (o *GetSilencesParams) WithTimeout(timeout time.Duration) *GetSilencesParams

WithTimeout adds the timeout to the get silences params

func (*GetSilencesParams) WriteToRequest

func (o *GetSilencesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type GetSilencesReader

GetSilencesReader is a Reader for the GetSilences structure.

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

func (*GetSilencesReader) ReadResponse

func (o *GetSilencesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

type PostSilencesBadRequest

PostSilencesBadRequest describes a response with status code 400, with default header values.

Bad request

type PostSilencesBadRequest struct {
    Payload string
}

func NewPostSilencesBadRequest

func NewPostSilencesBadRequest() *PostSilencesBadRequest

NewPostSilencesBadRequest creates a PostSilencesBadRequest with default headers values

func (*PostSilencesBadRequest) Error

func (o *PostSilencesBadRequest) Error() string

func (*PostSilencesBadRequest) GetPayload

func (o *PostSilencesBadRequest) GetPayload() string

func (*PostSilencesBadRequest) IsClientError

func (o *PostSilencesBadRequest) IsClientError() bool

IsClientError returns true when this post silences bad request response has a 4xx status code

func (*PostSilencesBadRequest) IsCode

func (o *PostSilencesBadRequest) IsCode(code int) bool

IsCode returns true when this post silences bad request response a status code equal to that given

func (*PostSilencesBadRequest) IsRedirect

func (o *PostSilencesBadRequest) IsRedirect() bool

IsRedirect returns true when this post silences bad request response has a 3xx status code

func (*PostSilencesBadRequest) IsServerError

func (o *PostSilencesBadRequest) IsServerError() bool

IsServerError returns true when this post silences bad request response has a 5xx status code

func (*PostSilencesBadRequest) IsSuccess

func (o *PostSilencesBadRequest) IsSuccess() bool

IsSuccess returns true when this post silences bad request response has a 2xx status code

func (*PostSilencesBadRequest) String

func (o *PostSilencesBadRequest) String() string

type PostSilencesNotFound

PostSilencesNotFound describes a response with status code 404, with default header values.

A silence with the specified ID was not found

type PostSilencesNotFound struct {
    Payload string
}

func NewPostSilencesNotFound

func NewPostSilencesNotFound() *PostSilencesNotFound

NewPostSilencesNotFound creates a PostSilencesNotFound with default headers values

func (*PostSilencesNotFound) Error

func (o *PostSilencesNotFound) Error() string

func (*PostSilencesNotFound) GetPayload

func (o *PostSilencesNotFound) GetPayload() string

func (*PostSilencesNotFound) IsClientError

func (o *PostSilencesNotFound) IsClientError() bool

IsClientError returns true when this post silences not found response has a 4xx status code

func (*PostSilencesNotFound) IsCode

func (o *PostSilencesNotFound) IsCode(code int) bool

IsCode returns true when this post silences not found response a status code equal to that given

func (*PostSilencesNotFound) IsRedirect

func (o *PostSilencesNotFound) IsRedirect() bool

IsRedirect returns true when this post silences not found response has a 3xx status code

func (*PostSilencesNotFound) IsServerError

func (o *PostSilencesNotFound) IsServerError() bool

IsServerError returns true when this post silences not found response has a 5xx status code

func (*PostSilencesNotFound) IsSuccess

func (o *PostSilencesNotFound) IsSuccess() bool

IsSuccess returns true when this post silences not found response has a 2xx status code

func (*PostSilencesNotFound) String

func (o *PostSilencesNotFound) String() string

type PostSilencesOK

PostSilencesOK describes a response with status code 200, with default header values.

Create / update silence response

type PostSilencesOK struct {
    Payload *PostSilencesOKBody
}

func NewPostSilencesOK

func NewPostSilencesOK() *PostSilencesOK

NewPostSilencesOK creates a PostSilencesOK with default headers values

func (*PostSilencesOK) Error

func (o *PostSilencesOK) Error() string

func (*PostSilencesOK) GetPayload

func (o *PostSilencesOK) GetPayload() *PostSilencesOKBody

func (*PostSilencesOK) IsClientError

func (o *PostSilencesOK) IsClientError() bool

IsClientError returns true when this post silences o k response has a 4xx status code

func (*PostSilencesOK) IsCode

func (o *PostSilencesOK) IsCode(code int) bool

IsCode returns true when this post silences o k response a status code equal to that given

func (*PostSilencesOK) IsRedirect

func (o *PostSilencesOK) IsRedirect() bool

IsRedirect returns true when this post silences o k response has a 3xx status code

func (*PostSilencesOK) IsServerError

func (o *PostSilencesOK) IsServerError() bool

IsServerError returns true when this post silences o k response has a 5xx status code

func (*PostSilencesOK) IsSuccess

func (o *PostSilencesOK) IsSuccess() bool

IsSuccess returns true when this post silences o k response has a 2xx status code

func (*PostSilencesOK) String

func (o *PostSilencesOK) String() string

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 parameters to send to the API endpoint

for the post silences operation.

Typically these are written to a http.Request.
type PostSilencesParams struct {

    /* Silence.

       The silence to create
    */
    Silence *models.PostableSilence

    Context    context.Context
    HTTPClient *http.Client
    // contains filtered or unexported fields
}

func NewPostSilencesParams

func NewPostSilencesParams() *PostSilencesParams

NewPostSilencesParams creates a new PostSilencesParams object, with the default timeout for this client.

Default values are not hydrated, since defaults are normally applied by the API server side.

To enforce default values in parameter, use SetDefaults or WithDefaults.

func NewPostSilencesParamsWithContext

func NewPostSilencesParamsWithContext(ctx context.Context) *PostSilencesParams

NewPostSilencesParamsWithContext creates a new PostSilencesParams object with the ability to set a context for a request.

func NewPostSilencesParamsWithHTTPClient

func NewPostSilencesParamsWithHTTPClient(client *http.Client) *PostSilencesParams

NewPostSilencesParamsWithHTTPClient creates a new PostSilencesParams object with the ability to set a custom HTTPClient for a request.

func NewPostSilencesParamsWithTimeout

func NewPostSilencesParamsWithTimeout(timeout time.Duration) *PostSilencesParams

NewPostSilencesParamsWithTimeout creates a new PostSilencesParams object with the ability to set a timeout on a request.

func (*PostSilencesParams) SetContext

func (o *PostSilencesParams) SetContext(ctx context.Context)

SetContext adds the context to the post silences params

func (*PostSilencesParams) SetDefaults

func (o *PostSilencesParams) SetDefaults()

SetDefaults hydrates default values in the post silences params (not the query body).

All values with no default are reset to their zero value.

func (*PostSilencesParams) SetHTTPClient

func (o *PostSilencesParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the post silences params

func (*PostSilencesParams) SetSilence

func (o *PostSilencesParams) SetSilence(silence *models.PostableSilence)

SetSilence adds the silence to the post silences params

func (*PostSilencesParams) SetTimeout

func (o *PostSilencesParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the post silences params

func (*PostSilencesParams) WithContext

func (o *PostSilencesParams) WithContext(ctx context.Context) *PostSilencesParams

WithContext adds the context to the post silences params

func (*PostSilencesParams) WithDefaults

func (o *PostSilencesParams) WithDefaults() *PostSilencesParams

WithDefaults hydrates default values in the post silences params (not the query body).

All values with no default are reset to their zero value.

func (*PostSilencesParams) WithHTTPClient

func (o *PostSilencesParams) WithHTTPClient(client *http.Client) *PostSilencesParams

WithHTTPClient adds the HTTPClient to the post silences params

func (*PostSilencesParams) WithSilence

func (o *PostSilencesParams) WithSilence(silence *models.PostableSilence) *PostSilencesParams

WithSilence adds the silence to the post silences params

func (*PostSilencesParams) WithTimeout

func (o *PostSilencesParams) WithTimeout(timeout time.Duration) *PostSilencesParams

WithTimeout adds the timeout to the post silences params

func (*PostSilencesParams) WriteToRequest

func (o *PostSilencesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type PostSilencesReader

PostSilencesReader is a Reader for the PostSilences structure.

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

func (*PostSilencesReader) ReadResponse

func (o *PostSilencesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.