Documentation ¶
Index ¶
- type Client
- type ClientOption
- type ClientService
- type SendForbidden
- func (o *SendForbidden) Code() int
- func (o *SendForbidden) Error() string
- func (o *SendForbidden) GetPayload() *models.RestError
- func (o *SendForbidden) IsClientError() bool
- func (o *SendForbidden) IsCode(code int) bool
- func (o *SendForbidden) IsRedirect() bool
- func (o *SendForbidden) IsServerError() bool
- func (o *SendForbidden) IsSuccess() bool
- func (o *SendForbidden) String() string
- type SendInternalServerError
- func (o *SendInternalServerError) Code() int
- func (o *SendInternalServerError) Error() string
- func (o *SendInternalServerError) GetPayload() *models.RestError
- func (o *SendInternalServerError) IsClientError() bool
- func (o *SendInternalServerError) IsCode(code int) bool
- func (o *SendInternalServerError) IsRedirect() bool
- func (o *SendInternalServerError) IsServerError() bool
- func (o *SendInternalServerError) IsSuccess() bool
- func (o *SendInternalServerError) String() string
- type SendNotFound
- func (o *SendNotFound) Code() int
- func (o *SendNotFound) Error() string
- func (o *SendNotFound) GetPayload() *models.RestError
- func (o *SendNotFound) IsClientError() bool
- func (o *SendNotFound) IsCode(code int) bool
- func (o *SendNotFound) IsRedirect() bool
- func (o *SendNotFound) IsServerError() bool
- func (o *SendNotFound) IsSuccess() bool
- func (o *SendNotFound) String() string
- type SendOK
- func (o *SendOK) Code() int
- func (o *SendOK) Error() string
- func (o *SendOK) GetPayload() *models.MailerSendMailResponse
- func (o *SendOK) IsClientError() bool
- func (o *SendOK) IsCode(code int) bool
- func (o *SendOK) IsRedirect() bool
- func (o *SendOK) IsServerError() bool
- func (o *SendOK) IsSuccess() bool
- func (o *SendOK) String() string
- type SendParams
- func (o *SendParams) SetBody(body *models.MailerMail)
- func (o *SendParams) SetContext(ctx context.Context)
- func (o *SendParams) SetDefaults()
- func (o *SendParams) SetHTTPClient(client *http.Client)
- func (o *SendParams) SetTimeout(timeout time.Duration)
- func (o *SendParams) WithBody(body *models.MailerMail) *SendParams
- func (o *SendParams) WithContext(ctx context.Context) *SendParams
- func (o *SendParams) WithDefaults() *SendParams
- func (o *SendParams) WithHTTPClient(client *http.Client) *SendParams
- func (o *SendParams) WithTimeout(timeout time.Duration) *SendParams
- func (o *SendParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type SendReader
- type SendUnauthorized
- func (o *SendUnauthorized) Code() int
- func (o *SendUnauthorized) Error() string
- func (o *SendUnauthorized) IsClientError() bool
- func (o *SendUnauthorized) IsCode(code int) bool
- func (o *SendUnauthorized) IsRedirect() bool
- func (o *SendUnauthorized) IsServerError() bool
- func (o *SendUnauthorized) IsSuccess() bool
- func (o *SendUnauthorized) String() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client for mailer service API
func (*Client) Send ¶
func (a *Client) Send(params *SendParams, opts ...ClientOption) (*SendOK, error)
Send sends an email to a user or any email address
func (*Client) SetTransport ¶
func (a *Client) SetTransport(transport runtime.ClientTransport)
SetTransport changes the transport on the client
type ClientOption ¶
type ClientOption func(*runtime.ClientOperation)
ClientOption is the option for Client methods
type ClientService ¶
type ClientService interface { Send(params *SendParams, opts ...ClientOption) (*SendOK, error) SetTransport(transport runtime.ClientTransport) }
ClientService is the interface for Client methods
func New ¶
func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService
New creates a new mailer service API client.
type SendForbidden ¶
SendForbidden describes a response with status code 403, with default header values.
User has no permission to access this resource
func NewSendForbidden ¶
func NewSendForbidden() *SendForbidden
NewSendForbidden creates a SendForbidden with default headers values
func (*SendForbidden) Code ¶ added in v4.0.1
func (o *SendForbidden) Code() int
Code gets the status code for the send forbidden response
func (*SendForbidden) Error ¶
func (o *SendForbidden) Error() string
func (*SendForbidden) GetPayload ¶
func (o *SendForbidden) GetPayload() *models.RestError
func (*SendForbidden) IsClientError ¶
func (o *SendForbidden) IsClientError() bool
IsClientError returns true when this send forbidden response has a 4xx status code
func (*SendForbidden) IsCode ¶
func (o *SendForbidden) IsCode(code int) bool
IsCode returns true when this send forbidden response a status code equal to that given
func (*SendForbidden) IsRedirect ¶
func (o *SendForbidden) IsRedirect() bool
IsRedirect returns true when this send forbidden response has a 3xx status code
func (*SendForbidden) IsServerError ¶
func (o *SendForbidden) IsServerError() bool
IsServerError returns true when this send forbidden response has a 5xx status code
func (*SendForbidden) IsSuccess ¶
func (o *SendForbidden) IsSuccess() bool
IsSuccess returns true when this send forbidden response has a 2xx status code
func (*SendForbidden) String ¶
func (o *SendForbidden) String() string
type SendInternalServerError ¶
SendInternalServerError describes a response with status code 500, with default header values.
An internal error occurred in the backend
func NewSendInternalServerError ¶
func NewSendInternalServerError() *SendInternalServerError
NewSendInternalServerError creates a SendInternalServerError with default headers values
func (*SendInternalServerError) Code ¶ added in v4.0.1
func (o *SendInternalServerError) Code() int
Code gets the status code for the send internal server error response
func (*SendInternalServerError) Error ¶
func (o *SendInternalServerError) Error() string
func (*SendInternalServerError) GetPayload ¶
func (o *SendInternalServerError) GetPayload() *models.RestError
func (*SendInternalServerError) IsClientError ¶
func (o *SendInternalServerError) IsClientError() bool
IsClientError returns true when this send internal server error response has a 4xx status code
func (*SendInternalServerError) IsCode ¶
func (o *SendInternalServerError) IsCode(code int) bool
IsCode returns true when this send internal server error response a status code equal to that given
func (*SendInternalServerError) IsRedirect ¶
func (o *SendInternalServerError) IsRedirect() bool
IsRedirect returns true when this send internal server error response has a 3xx status code
func (*SendInternalServerError) IsServerError ¶
func (o *SendInternalServerError) IsServerError() bool
IsServerError returns true when this send internal server error response has a 5xx status code
func (*SendInternalServerError) IsSuccess ¶
func (o *SendInternalServerError) IsSuccess() bool
IsSuccess returns true when this send internal server error response has a 2xx status code
func (*SendInternalServerError) String ¶
func (o *SendInternalServerError) String() string
type SendNotFound ¶
SendNotFound describes a response with status code 404, with default header values.
Resource does not exist in the system
func NewSendNotFound ¶
func NewSendNotFound() *SendNotFound
NewSendNotFound creates a SendNotFound with default headers values
func (*SendNotFound) Code ¶ added in v4.0.1
func (o *SendNotFound) Code() int
Code gets the status code for the send not found response
func (*SendNotFound) Error ¶
func (o *SendNotFound) Error() string
func (*SendNotFound) GetPayload ¶
func (o *SendNotFound) GetPayload() *models.RestError
func (*SendNotFound) IsClientError ¶
func (o *SendNotFound) IsClientError() bool
IsClientError returns true when this send not found response has a 4xx status code
func (*SendNotFound) IsCode ¶
func (o *SendNotFound) IsCode(code int) bool
IsCode returns true when this send not found response a status code equal to that given
func (*SendNotFound) IsRedirect ¶
func (o *SendNotFound) IsRedirect() bool
IsRedirect returns true when this send not found response has a 3xx status code
func (*SendNotFound) IsServerError ¶
func (o *SendNotFound) IsServerError() bool
IsServerError returns true when this send not found response has a 5xx status code
func (*SendNotFound) IsSuccess ¶
func (o *SendNotFound) IsSuccess() bool
IsSuccess returns true when this send not found response has a 2xx status code
func (*SendNotFound) String ¶
func (o *SendNotFound) String() string
type SendOK ¶
type SendOK struct {
Payload *models.MailerSendMailResponse
}
SendOK describes a response with status code 200, with default header values.
A successful response.
func (*SendOK) GetPayload ¶
func (o *SendOK) GetPayload() *models.MailerSendMailResponse
func (*SendOK) IsClientError ¶
IsClientError returns true when this send o k response has a 4xx status code
func (*SendOK) IsCode ¶
IsCode returns true when this send o k response a status code equal to that given
func (*SendOK) IsRedirect ¶
IsRedirect returns true when this send o k response has a 3xx status code
func (*SendOK) IsServerError ¶
IsServerError returns true when this send o k response has a 5xx status code
type SendParams ¶
type SendParams struct { // Body. Body *models.MailerMail Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
SendParams contains all the parameters to send to the API endpoint
for the send operation. Typically these are written to a http.Request.
func NewSendParams ¶
func NewSendParams() *SendParams
NewSendParams creates a new SendParams 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 NewSendParamsWithContext ¶
func NewSendParamsWithContext(ctx context.Context) *SendParams
NewSendParamsWithContext creates a new SendParams object with the ability to set a context for a request.
func NewSendParamsWithHTTPClient ¶
func NewSendParamsWithHTTPClient(client *http.Client) *SendParams
NewSendParamsWithHTTPClient creates a new SendParams object with the ability to set a custom HTTPClient for a request.
func NewSendParamsWithTimeout ¶
func NewSendParamsWithTimeout(timeout time.Duration) *SendParams
NewSendParamsWithTimeout creates a new SendParams object with the ability to set a timeout on a request.
func (*SendParams) SetBody ¶
func (o *SendParams) SetBody(body *models.MailerMail)
SetBody adds the body to the send params
func (*SendParams) SetContext ¶
func (o *SendParams) SetContext(ctx context.Context)
SetContext adds the context to the send params
func (*SendParams) SetDefaults ¶
func (o *SendParams) SetDefaults()
SetDefaults hydrates default values in the send params (not the query body).
All values with no default are reset to their zero value.
func (*SendParams) SetHTTPClient ¶
func (o *SendParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the send params
func (*SendParams) SetTimeout ¶
func (o *SendParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the send params
func (*SendParams) WithBody ¶
func (o *SendParams) WithBody(body *models.MailerMail) *SendParams
WithBody adds the body to the send params
func (*SendParams) WithContext ¶
func (o *SendParams) WithContext(ctx context.Context) *SendParams
WithContext adds the context to the send params
func (*SendParams) WithDefaults ¶
func (o *SendParams) WithDefaults() *SendParams
WithDefaults hydrates default values in the send params (not the query body).
All values with no default are reset to their zero value.
func (*SendParams) WithHTTPClient ¶
func (o *SendParams) WithHTTPClient(client *http.Client) *SendParams
WithHTTPClient adds the HTTPClient to the send params
func (*SendParams) WithTimeout ¶
func (o *SendParams) WithTimeout(timeout time.Duration) *SendParams
WithTimeout adds the timeout to the send params
func (*SendParams) WriteToRequest ¶
func (o *SendParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type SendReader ¶
type SendReader struct {
// contains filtered or unexported fields
}
SendReader is a Reader for the Send structure.
func (*SendReader) ReadResponse ¶
func (o *SendReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type SendUnauthorized ¶
type SendUnauthorized struct { }
SendUnauthorized describes a response with status code 401, with default header values.
User is not authenticated
func NewSendUnauthorized ¶
func NewSendUnauthorized() *SendUnauthorized
NewSendUnauthorized creates a SendUnauthorized with default headers values
func (*SendUnauthorized) Code ¶ added in v4.0.1
func (o *SendUnauthorized) Code() int
Code gets the status code for the send unauthorized response
func (*SendUnauthorized) Error ¶
func (o *SendUnauthorized) Error() string
func (*SendUnauthorized) IsClientError ¶
func (o *SendUnauthorized) IsClientError() bool
IsClientError returns true when this send unauthorized response has a 4xx status code
func (*SendUnauthorized) IsCode ¶
func (o *SendUnauthorized) IsCode(code int) bool
IsCode returns true when this send unauthorized response a status code equal to that given
func (*SendUnauthorized) IsRedirect ¶
func (o *SendUnauthorized) IsRedirect() bool
IsRedirect returns true when this send unauthorized response has a 3xx status code
func (*SendUnauthorized) IsServerError ¶
func (o *SendUnauthorized) IsServerError() bool
IsServerError returns true when this send unauthorized response has a 5xx status code
func (*SendUnauthorized) IsSuccess ¶
func (o *SendUnauthorized) IsSuccess() bool
IsSuccess returns true when this send unauthorized response has a 2xx status code
func (*SendUnauthorized) String ¶
func (o *SendUnauthorized) String() string