usage_management

package
v0.0.0-...-33e56a9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 24, 2025 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API interface {
	/*
	   GetSystemUsage generates an aggregated response by account of the usage recorded in the system during the time window specified*/
	GetSystemUsage(ctx context.Context, params *GetSystemUsageParams) (*GetSystemUsageOK, error)
	/*
	   GetUsage generates an aggregated response of the usage recorded in the system during the time window specified for the selected account*/
	GetUsage(ctx context.Context, params *GetUsageParams) (*GetUsageOK, error)
}

API is the interface of the usage management client

type Client

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

Client for usage management API

func New

func New(transport runtime.ClientTransport, formats strfmt.Registry, authInfo runtime.ClientAuthInfoWriter) *Client

New creates a new usage management API client.

func (*Client) GetSystemUsage

func (a *Client) GetSystemUsage(ctx context.Context, params *GetSystemUsageParams) (*GetSystemUsageOK, error)

GetSystemUsage generates an aggregated response by account of the usage recorded in the system during the time window specified

func (*Client) GetUsage

func (a *Client) GetUsage(ctx context.Context, params *GetUsageParams) (*GetUsageOK, error)

GetUsage generates an aggregated response of the usage recorded in the system during the time window specified for the selected account

type GetSystemUsageInternalServerError

type GetSystemUsageInternalServerError struct {
	Payload *models.ErrorResponse
}

GetSystemUsageInternalServerError handles this case with default header values.

Something unexpected happend, error raised

func NewGetSystemUsageInternalServerError

func NewGetSystemUsageInternalServerError() *GetSystemUsageInternalServerError

NewGetSystemUsageInternalServerError creates a GetSystemUsageInternalServerError with default headers values

func (*GetSystemUsageInternalServerError) Error

func (*GetSystemUsageInternalServerError) GetPayload

type GetSystemUsageOK

type GetSystemUsageOK struct {
	Payload []*models.Usage
}

GetSystemUsageOK handles this case with default header values.

Description of a successfully operation

func NewGetSystemUsageOK

func NewGetSystemUsageOK() *GetSystemUsageOK

NewGetSystemUsageOK creates a GetSystemUsageOK with default headers values

func (*GetSystemUsageOK) Error

func (o *GetSystemUsageOK) Error() string

func (*GetSystemUsageOK) GetPayload

func (o *GetSystemUsageOK) GetPayload() []*models.Usage

type GetSystemUsageParams

type GetSystemUsageParams struct {

	/*From
	  Datetime from which to get the usage report

	*/
	From *int64
	/*Region
	  Resource region to filter the usage

	*/
	Region *string
	/*Resource
	  Resource type to filter the usage

	*/
	Resource *string
	/*To
	  Datetime until which to get the usage report

	*/
	To *int64

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

GetSystemUsageParams contains all the parameters to send to the API endpoint for the get system usage operation typically these are written to a http.Request

func NewGetSystemUsageParams

func NewGetSystemUsageParams() *GetSystemUsageParams

NewGetSystemUsageParams creates a new GetSystemUsageParams object with the default values initialized.

func NewGetSystemUsageParamsWithContext

func NewGetSystemUsageParamsWithContext(ctx context.Context) *GetSystemUsageParams

NewGetSystemUsageParamsWithContext creates a new GetSystemUsageParams object with the default values initialized, and the ability to set a context for a request

func NewGetSystemUsageParamsWithHTTPClient

func NewGetSystemUsageParamsWithHTTPClient(client *http.Client) *GetSystemUsageParams

NewGetSystemUsageParamsWithHTTPClient creates a new GetSystemUsageParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewGetSystemUsageParamsWithTimeout

func NewGetSystemUsageParamsWithTimeout(timeout time.Duration) *GetSystemUsageParams

NewGetSystemUsageParamsWithTimeout creates a new GetSystemUsageParams object with the default values initialized, and the ability to set a timeout on a request

func (*GetSystemUsageParams) SetContext

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

SetContext adds the context to the get system usage params

func (*GetSystemUsageParams) SetFrom

func (o *GetSystemUsageParams) SetFrom(from *int64)

SetFrom adds the from to the get system usage params

func (*GetSystemUsageParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the get system usage params

func (*GetSystemUsageParams) SetRegion

func (o *GetSystemUsageParams) SetRegion(region *string)

SetRegion adds the region to the get system usage params

func (*GetSystemUsageParams) SetResource

func (o *GetSystemUsageParams) SetResource(resource *string)

SetResource adds the resource to the get system usage params

func (*GetSystemUsageParams) SetTimeout

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

SetTimeout adds the timeout to the get system usage params

func (*GetSystemUsageParams) SetTo

func (o *GetSystemUsageParams) SetTo(to *int64)

SetTo adds the to to the get system usage params

func (*GetSystemUsageParams) WithContext

WithContext adds the context to the get system usage params

func (*GetSystemUsageParams) WithFrom

func (o *GetSystemUsageParams) WithFrom(from *int64) *GetSystemUsageParams

WithFrom adds the from to the get system usage params

func (*GetSystemUsageParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the get system usage params

func (*GetSystemUsageParams) WithRegion

func (o *GetSystemUsageParams) WithRegion(region *string) *GetSystemUsageParams

WithRegion adds the region to the get system usage params

func (*GetSystemUsageParams) WithResource

func (o *GetSystemUsageParams) WithResource(resource *string) *GetSystemUsageParams

WithResource adds the resource to the get system usage params

func (*GetSystemUsageParams) WithTimeout

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

WithTimeout adds the timeout to the get system usage params

func (*GetSystemUsageParams) WithTo

WithTo adds the to to the get system usage params

func (*GetSystemUsageParams) WriteToRequest

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

WriteToRequest writes these params to a swagger request

type GetSystemUsageReader

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

GetSystemUsageReader is a Reader for the GetSystemUsage structure.

func (*GetSystemUsageReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type GetUsageInternalServerError

type GetUsageInternalServerError struct {
	Payload *models.ErrorResponse
}

GetUsageInternalServerError handles this case with default header values.

Something unexpected happend, error raised

func NewGetUsageInternalServerError

func NewGetUsageInternalServerError() *GetUsageInternalServerError

NewGetUsageInternalServerError creates a GetUsageInternalServerError with default headers values

func (*GetUsageInternalServerError) Error

func (*GetUsageInternalServerError) GetPayload

type GetUsageNotFound

type GetUsageNotFound struct {
	Payload *models.ErrorResponse
}

GetUsageNotFound handles this case with default header values.

Item not found in the system

func NewGetUsageNotFound

func NewGetUsageNotFound() *GetUsageNotFound

NewGetUsageNotFound creates a GetUsageNotFound with default headers values

func (*GetUsageNotFound) Error

func (o *GetUsageNotFound) Error() string

func (*GetUsageNotFound) GetPayload

func (o *GetUsageNotFound) GetPayload() *models.ErrorResponse

type GetUsageOK

type GetUsageOK struct {
	Payload *models.Usage
}

GetUsageOK handles this case with default header values.

Description of a successfully operation

func NewGetUsageOK

func NewGetUsageOK() *GetUsageOK

NewGetUsageOK creates a GetUsageOK with default headers values

func (*GetUsageOK) Error

func (o *GetUsageOK) Error() string

func (*GetUsageOK) GetPayload

func (o *GetUsageOK) GetPayload() *models.Usage

type GetUsageParams

type GetUsageParams struct {

	/*From
	  Datetime from which to get the usage report

	*/
	From *int64
	/*ID
	  Id of the account to be checked

	*/
	ID string
	/*Region
	  Resource region to filter the usage

	*/
	Region *string
	/*Resource
	  Resource type to filter the usage

	*/
	Resource *string
	/*To
	  Datetime until which to get the usage report

	*/
	To *int64

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

GetUsageParams contains all the parameters to send to the API endpoint for the get usage operation typically these are written to a http.Request

func NewGetUsageParams

func NewGetUsageParams() *GetUsageParams

NewGetUsageParams creates a new GetUsageParams object with the default values initialized.

func NewGetUsageParamsWithContext

func NewGetUsageParamsWithContext(ctx context.Context) *GetUsageParams

NewGetUsageParamsWithContext creates a new GetUsageParams object with the default values initialized, and the ability to set a context for a request

func NewGetUsageParamsWithHTTPClient

func NewGetUsageParamsWithHTTPClient(client *http.Client) *GetUsageParams

NewGetUsageParamsWithHTTPClient creates a new GetUsageParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewGetUsageParamsWithTimeout

func NewGetUsageParamsWithTimeout(timeout time.Duration) *GetUsageParams

NewGetUsageParamsWithTimeout creates a new GetUsageParams object with the default values initialized, and the ability to set a timeout on a request

func (*GetUsageParams) SetContext

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

SetContext adds the context to the get usage params

func (*GetUsageParams) SetFrom

func (o *GetUsageParams) SetFrom(from *int64)

SetFrom adds the from to the get usage params

func (*GetUsageParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the get usage params

func (*GetUsageParams) SetID

func (o *GetUsageParams) SetID(id string)

SetID adds the id to the get usage params

func (*GetUsageParams) SetRegion

func (o *GetUsageParams) SetRegion(region *string)

SetRegion adds the region to the get usage params

func (*GetUsageParams) SetResource

func (o *GetUsageParams) SetResource(resource *string)

SetResource adds the resource to the get usage params

func (*GetUsageParams) SetTimeout

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

SetTimeout adds the timeout to the get usage params

func (*GetUsageParams) SetTo

func (o *GetUsageParams) SetTo(to *int64)

SetTo adds the to to the get usage params

func (*GetUsageParams) WithContext

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

WithContext adds the context to the get usage params

func (*GetUsageParams) WithFrom

func (o *GetUsageParams) WithFrom(from *int64) *GetUsageParams

WithFrom adds the from to the get usage params

func (*GetUsageParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the get usage params

func (*GetUsageParams) WithID

func (o *GetUsageParams) WithID(id string) *GetUsageParams

WithID adds the id to the get usage params

func (*GetUsageParams) WithRegion

func (o *GetUsageParams) WithRegion(region *string) *GetUsageParams

WithRegion adds the region to the get usage params

func (*GetUsageParams) WithResource

func (o *GetUsageParams) WithResource(resource *string) *GetUsageParams

WithResource adds the resource to the get usage params

func (*GetUsageParams) WithTimeout

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

WithTimeout adds the timeout to the get usage params

func (*GetUsageParams) WithTo

func (o *GetUsageParams) WithTo(to *int64) *GetUsageParams

WithTo adds the to to the get usage params

func (*GetUsageParams) WriteToRequest

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

WriteToRequest writes these params to a swagger request

type GetUsageReader

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

GetUsageReader is a Reader for the GetUsage structure.

func (*GetUsageReader) ReadResponse

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

ReadResponse reads a server response into the received o.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL