Documentation
¶
Index ¶
- type Client
- func (a *Client) CreateCredits(params *CreateCreditsParams, authInfo runtime.ClientAuthInfoWriter, ...) (*CreateCreditsCreated, error)
- func (a *Client) GetCredit(params *GetCreditParams, authInfo runtime.ClientAuthInfoWriter, ...) (*GetCreditOK, error)
- func (a *Client) SetTransport(transport runtime.ClientTransport)
- type ClientOption
- type ClientService
- type CreateCreditsBadRequest
- type CreateCreditsCreated
- type CreateCreditsNotFound
- type CreateCreditsParams
- func (o *CreateCreditsParams) SetAutoCommit(autoCommit *bool)
- func (o *CreateCreditsParams) SetBody(body []*kbmodel.InvoiceItem)
- func (o *CreateCreditsParams) SetContext(ctx context.Context)
- func (o *CreateCreditsParams) SetDefaults()
- func (o *CreateCreditsParams) SetHTTPClient(client *http.Client)
- func (o *CreateCreditsParams) SetPluginProperty(pluginProperty []string)
- func (o *CreateCreditsParams) SetTimeout(timeout time.Duration)
- func (o *CreateCreditsParams) SetXKillbillComment(xKillbillComment *string)
- func (o *CreateCreditsParams) SetXKillbillCreatedBy(xKillbillCreatedBy string)
- func (o *CreateCreditsParams) SetXKillbillReason(xKillbillReason *string)
- func (o *CreateCreditsParams) WithAutoCommit(autoCommit *bool) *CreateCreditsParams
- func (o *CreateCreditsParams) WithBody(body []*kbmodel.InvoiceItem) *CreateCreditsParams
- func (o *CreateCreditsParams) WithContext(ctx context.Context) *CreateCreditsParams
- func (o *CreateCreditsParams) WithDefaults() *CreateCreditsParams
- func (o *CreateCreditsParams) WithHTTPClient(client *http.Client) *CreateCreditsParams
- func (o *CreateCreditsParams) WithPluginProperty(pluginProperty []string) *CreateCreditsParams
- func (o *CreateCreditsParams) WithTimeout(timeout time.Duration) *CreateCreditsParams
- func (o *CreateCreditsParams) WithXKillbillComment(xKillbillComment *string) *CreateCreditsParams
- func (o *CreateCreditsParams) WithXKillbillCreatedBy(xKillbillCreatedBy string) *CreateCreditsParams
- func (o *CreateCreditsParams) WithXKillbillReason(xKillbillReason *string) *CreateCreditsParams
- func (o *CreateCreditsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type CreateCreditsReader
- type GetCreditBadRequest
- type GetCreditNotFound
- type GetCreditOK
- type GetCreditParams
- func (o *GetCreditParams) SetContext(ctx context.Context)
- func (o *GetCreditParams) SetCreditID(creditID strfmt.UUID)
- func (o *GetCreditParams) SetDefaults()
- func (o *GetCreditParams) SetHTTPClient(client *http.Client)
- func (o *GetCreditParams) SetTimeout(timeout time.Duration)
- func (o *GetCreditParams) WithContext(ctx context.Context) *GetCreditParams
- func (o *GetCreditParams) WithCreditID(creditID strfmt.UUID) *GetCreditParams
- func (o *GetCreditParams) WithDefaults() *GetCreditParams
- func (o *GetCreditParams) WithHTTPClient(client *http.Client) *GetCreditParams
- func (o *GetCreditParams) WithTimeout(timeout time.Duration) *GetCreditParams
- func (o *GetCreditParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type GetCreditReader
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 credit API
func (*Client) CreateCredits ¶
func (a *Client) CreateCredits(params *CreateCreditsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*CreateCreditsCreated, error)
CreateCredits creates a credit
func (*Client) GetCredit ¶
func (a *Client) GetCredit(params *GetCreditParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetCreditOK, error)
GetCredit retrieves a credit by id
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 { CreateCredits(params *CreateCreditsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*CreateCreditsCreated, error) GetCredit(params *GetCreditParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetCreditOK, 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 credit API client.
type CreateCreditsBadRequest ¶
type CreateCreditsBadRequest struct { }
CreateCreditsBadRequest describes a response with status code 400, with default header values.
Invalid account id supplied
func NewCreateCreditsBadRequest ¶
func NewCreateCreditsBadRequest() *CreateCreditsBadRequest
NewCreateCreditsBadRequest creates a CreateCreditsBadRequest with default headers values
func (*CreateCreditsBadRequest) Error ¶
func (o *CreateCreditsBadRequest) Error() string
type CreateCreditsCreated ¶
type CreateCreditsCreated struct {
Payload []*kbmodel.InvoiceItem
}
CreateCreditsCreated describes a response with status code 201, with default header values.
Created credit successfully
func NewCreateCreditsCreated ¶
func NewCreateCreditsCreated() *CreateCreditsCreated
NewCreateCreditsCreated creates a CreateCreditsCreated with default headers values
func (*CreateCreditsCreated) Error ¶
func (o *CreateCreditsCreated) Error() string
func (*CreateCreditsCreated) GetPayload ¶
func (o *CreateCreditsCreated) GetPayload() []*kbmodel.InvoiceItem
type CreateCreditsNotFound ¶
type CreateCreditsNotFound struct { }
CreateCreditsNotFound describes a response with status code 404, with default header values.
Account not found
func NewCreateCreditsNotFound ¶
func NewCreateCreditsNotFound() *CreateCreditsNotFound
NewCreateCreditsNotFound creates a CreateCreditsNotFound with default headers values
func (*CreateCreditsNotFound) Error ¶
func (o *CreateCreditsNotFound) Error() string
type CreateCreditsParams ¶
type CreateCreditsParams struct { // XKillbillComment. XKillbillComment *string // XKillbillCreatedBy. XKillbillCreatedBy string // XKillbillReason. XKillbillReason *string // AutoCommit. AutoCommit *bool // Body. Body []*kbmodel.InvoiceItem // PluginProperty. PluginProperty []string Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
CreateCreditsParams contains all the parameters to send to the API endpoint
for the create credits operation. Typically these are written to a http.Request.
func NewCreateCreditsParams ¶
func NewCreateCreditsParams() *CreateCreditsParams
NewCreateCreditsParams creates a new CreateCreditsParams 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 NewCreateCreditsParamsWithContext ¶
func NewCreateCreditsParamsWithContext(ctx context.Context) *CreateCreditsParams
NewCreateCreditsParamsWithContext creates a new CreateCreditsParams object with the ability to set a context for a request.
func NewCreateCreditsParamsWithHTTPClient ¶
func NewCreateCreditsParamsWithHTTPClient(client *http.Client) *CreateCreditsParams
NewCreateCreditsParamsWithHTTPClient creates a new CreateCreditsParams object with the ability to set a custom HTTPClient for a request.
func NewCreateCreditsParamsWithTimeout ¶
func NewCreateCreditsParamsWithTimeout(timeout time.Duration) *CreateCreditsParams
NewCreateCreditsParamsWithTimeout creates a new CreateCreditsParams object with the ability to set a timeout on a request.
func (*CreateCreditsParams) SetAutoCommit ¶
func (o *CreateCreditsParams) SetAutoCommit(autoCommit *bool)
SetAutoCommit adds the autoCommit to the create credits params
func (*CreateCreditsParams) SetBody ¶
func (o *CreateCreditsParams) SetBody(body []*kbmodel.InvoiceItem)
SetBody adds the body to the create credits params
func (*CreateCreditsParams) SetContext ¶
func (o *CreateCreditsParams) SetContext(ctx context.Context)
SetContext adds the context to the create credits params
func (*CreateCreditsParams) SetDefaults ¶
func (o *CreateCreditsParams) SetDefaults()
SetDefaults hydrates default values in the create credits params (not the query body).
All values with no default are reset to their zero value.
func (*CreateCreditsParams) SetHTTPClient ¶
func (o *CreateCreditsParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the create credits params
func (*CreateCreditsParams) SetPluginProperty ¶
func (o *CreateCreditsParams) SetPluginProperty(pluginProperty []string)
SetPluginProperty adds the pluginProperty to the create credits params
func (*CreateCreditsParams) SetTimeout ¶
func (o *CreateCreditsParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the create credits params
func (*CreateCreditsParams) SetXKillbillComment ¶
func (o *CreateCreditsParams) SetXKillbillComment(xKillbillComment *string)
SetXKillbillComment adds the xKillbillComment to the create credits params
func (*CreateCreditsParams) SetXKillbillCreatedBy ¶
func (o *CreateCreditsParams) SetXKillbillCreatedBy(xKillbillCreatedBy string)
SetXKillbillCreatedBy adds the xKillbillCreatedBy to the create credits params
func (*CreateCreditsParams) SetXKillbillReason ¶
func (o *CreateCreditsParams) SetXKillbillReason(xKillbillReason *string)
SetXKillbillReason adds the xKillbillReason to the create credits params
func (*CreateCreditsParams) WithAutoCommit ¶
func (o *CreateCreditsParams) WithAutoCommit(autoCommit *bool) *CreateCreditsParams
WithAutoCommit adds the autoCommit to the create credits params
func (*CreateCreditsParams) WithBody ¶
func (o *CreateCreditsParams) WithBody(body []*kbmodel.InvoiceItem) *CreateCreditsParams
WithBody adds the body to the create credits params
func (*CreateCreditsParams) WithContext ¶
func (o *CreateCreditsParams) WithContext(ctx context.Context) *CreateCreditsParams
WithContext adds the context to the create credits params
func (*CreateCreditsParams) WithDefaults ¶
func (o *CreateCreditsParams) WithDefaults() *CreateCreditsParams
WithDefaults hydrates default values in the create credits params (not the query body).
All values with no default are reset to their zero value.
func (*CreateCreditsParams) WithHTTPClient ¶
func (o *CreateCreditsParams) WithHTTPClient(client *http.Client) *CreateCreditsParams
WithHTTPClient adds the HTTPClient to the create credits params
func (*CreateCreditsParams) WithPluginProperty ¶
func (o *CreateCreditsParams) WithPluginProperty(pluginProperty []string) *CreateCreditsParams
WithPluginProperty adds the pluginProperty to the create credits params
func (*CreateCreditsParams) WithTimeout ¶
func (o *CreateCreditsParams) WithTimeout(timeout time.Duration) *CreateCreditsParams
WithTimeout adds the timeout to the create credits params
func (*CreateCreditsParams) WithXKillbillComment ¶
func (o *CreateCreditsParams) WithXKillbillComment(xKillbillComment *string) *CreateCreditsParams
WithXKillbillComment adds the xKillbillComment to the create credits params
func (*CreateCreditsParams) WithXKillbillCreatedBy ¶
func (o *CreateCreditsParams) WithXKillbillCreatedBy(xKillbillCreatedBy string) *CreateCreditsParams
WithXKillbillCreatedBy adds the xKillbillCreatedBy to the create credits params
func (*CreateCreditsParams) WithXKillbillReason ¶
func (o *CreateCreditsParams) WithXKillbillReason(xKillbillReason *string) *CreateCreditsParams
WithXKillbillReason adds the xKillbillReason to the create credits params
func (*CreateCreditsParams) WriteToRequest ¶
func (o *CreateCreditsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type CreateCreditsReader ¶
type CreateCreditsReader struct {
// contains filtered or unexported fields
}
CreateCreditsReader is a Reader for the CreateCredits structure.
func (*CreateCreditsReader) ReadResponse ¶
func (o *CreateCreditsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type GetCreditBadRequest ¶
type GetCreditBadRequest struct { }
GetCreditBadRequest describes a response with status code 400, with default header values.
Invalid credit id supplied
func NewGetCreditBadRequest ¶
func NewGetCreditBadRequest() *GetCreditBadRequest
NewGetCreditBadRequest creates a GetCreditBadRequest with default headers values
func (*GetCreditBadRequest) Error ¶
func (o *GetCreditBadRequest) Error() string
type GetCreditNotFound ¶
type GetCreditNotFound struct { }
GetCreditNotFound describes a response with status code 404, with default header values.
Credit not found
func NewGetCreditNotFound ¶
func NewGetCreditNotFound() *GetCreditNotFound
NewGetCreditNotFound creates a GetCreditNotFound with default headers values
func (*GetCreditNotFound) Error ¶
func (o *GetCreditNotFound) Error() string
type GetCreditOK ¶
type GetCreditOK struct {
Payload *kbmodel.InvoiceItem
}
GetCreditOK describes a response with status code 200, with default header values.
successful operation
func NewGetCreditOK ¶
func NewGetCreditOK() *GetCreditOK
NewGetCreditOK creates a GetCreditOK with default headers values
func (*GetCreditOK) Error ¶
func (o *GetCreditOK) Error() string
func (*GetCreditOK) GetPayload ¶
func (o *GetCreditOK) GetPayload() *kbmodel.InvoiceItem
type GetCreditParams ¶
type GetCreditParams struct { // CreditID. // // Format: uuid CreditID strfmt.UUID Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
GetCreditParams contains all the parameters to send to the API endpoint
for the get credit operation. Typically these are written to a http.Request.
func NewGetCreditParams ¶
func NewGetCreditParams() *GetCreditParams
NewGetCreditParams creates a new GetCreditParams 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 NewGetCreditParamsWithContext ¶
func NewGetCreditParamsWithContext(ctx context.Context) *GetCreditParams
NewGetCreditParamsWithContext creates a new GetCreditParams object with the ability to set a context for a request.
func NewGetCreditParamsWithHTTPClient ¶
func NewGetCreditParamsWithHTTPClient(client *http.Client) *GetCreditParams
NewGetCreditParamsWithHTTPClient creates a new GetCreditParams object with the ability to set a custom HTTPClient for a request.
func NewGetCreditParamsWithTimeout ¶
func NewGetCreditParamsWithTimeout(timeout time.Duration) *GetCreditParams
NewGetCreditParamsWithTimeout creates a new GetCreditParams object with the ability to set a timeout on a request.
func (*GetCreditParams) SetContext ¶
func (o *GetCreditParams) SetContext(ctx context.Context)
SetContext adds the context to the get credit params
func (*GetCreditParams) SetCreditID ¶
func (o *GetCreditParams) SetCreditID(creditID strfmt.UUID)
SetCreditID adds the creditId to the get credit params
func (*GetCreditParams) SetDefaults ¶
func (o *GetCreditParams) SetDefaults()
SetDefaults hydrates default values in the get credit params (not the query body).
All values with no default are reset to their zero value.
func (*GetCreditParams) SetHTTPClient ¶
func (o *GetCreditParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the get credit params
func (*GetCreditParams) SetTimeout ¶
func (o *GetCreditParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the get credit params
func (*GetCreditParams) WithContext ¶
func (o *GetCreditParams) WithContext(ctx context.Context) *GetCreditParams
WithContext adds the context to the get credit params
func (*GetCreditParams) WithCreditID ¶
func (o *GetCreditParams) WithCreditID(creditID strfmt.UUID) *GetCreditParams
WithCreditID adds the creditID to the get credit params
func (*GetCreditParams) WithDefaults ¶
func (o *GetCreditParams) WithDefaults() *GetCreditParams
WithDefaults hydrates default values in the get credit params (not the query body).
All values with no default are reset to their zero value.
func (*GetCreditParams) WithHTTPClient ¶
func (o *GetCreditParams) WithHTTPClient(client *http.Client) *GetCreditParams
WithHTTPClient adds the HTTPClient to the get credit params
func (*GetCreditParams) WithTimeout ¶
func (o *GetCreditParams) WithTimeout(timeout time.Duration) *GetCreditParams
WithTimeout adds the timeout to the get credit params
func (*GetCreditParams) WriteToRequest ¶
func (o *GetCreditParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type GetCreditReader ¶
type GetCreditReader struct {
// contains filtered or unexported fields
}
GetCreditReader is a Reader for the GetCredit structure.
func (*GetCreditReader) ReadResponse ¶
func (o *GetCreditReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.