trade_action

package
v0.68.0 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	GetTradeHistoryByCriteriaFAILEDConstant  = "FAILED"
	GetTradeHistoryByCriteriaINITConstant    = "INIT"
	GetTradeHistoryByCriteriaSUCCESSConstant = "SUCCESS"
)

Get the enum in GetTradeHistoryByCriteriaParams

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client for trade action API

func (*Client) Commit deprecated

func (a *Client) Commit(params *CommitParams, authInfo runtime.ClientAuthInfoWriter) (*CommitOK, error)

Deprecated: 2022-08-10 - Use CommitShort instead.

Commit commit a chain of actions or operations This API is used to create a chained operations

Other detail info:

  • Required permission : resource=ADMIN:NAMESPACE:{namespace}:TRADE, action=1 (CREATE)
  • Returns : chain action history
  • FULFILL_ITEM operation supported item type : INGAMEITEM,LOOTBOX,OPTIONBOX

## Restrictions for metadata

1. Cannot use "." as the key name -

{ "data.2": "value" }

2. Cannot use "$" as the prefix in key names -

{ "$data": "value" }

func (*Client) CommitShort

func (a *Client) CommitShort(params *CommitParams, authInfo runtime.ClientAuthInfoWriter) (*CommitOK, error)

CommitShort commit a chain of actions or operations This API is used to create a chained operations

Other detail info:

  • Required permission : resource=ADMIN:NAMESPACE:{namespace}:TRADE, action=1 (CREATE)
  • Returns : chain action history
  • FULFILL_ITEM operation supported item type : INGAMEITEM,LOOTBOX,OPTIONBOX

## Restrictions for metadata

1. Cannot use "." as the key name -

{ "data.2": "value" }

2. Cannot use "$" as the prefix in key names -

{ "$data": "value" }

func (*Client) GetTradeHistoryByCriteria deprecated

func (a *Client) GetTradeHistoryByCriteria(params *GetTradeHistoryByCriteriaParams, authInfo runtime.ClientAuthInfoWriter) (*GetTradeHistoryByCriteriaOK, error)

Deprecated: 2022-08-10 - Use GetTradeHistoryByCriteriaShort instead.

GetTradeHistoryByCriteria retrieve trade history by criteria This API is used to fetch trade history based on the provided criteria

Other detail info:

  • Required permission : resource=ADMIN:NAMESPACE:{namespace}:TRADE, action=2 (REDA)
  • Returns : trade history list based on criteria

func (*Client) GetTradeHistoryByCriteriaShort

func (a *Client) GetTradeHistoryByCriteriaShort(params *GetTradeHistoryByCriteriaParams, authInfo runtime.ClientAuthInfoWriter) (*GetTradeHistoryByCriteriaOK, error)

GetTradeHistoryByCriteriaShort retrieve trade history by criteria This API is used to fetch trade history based on the provided criteria

Other detail info:

  • Required permission : resource=ADMIN:NAMESPACE:{namespace}:TRADE, action=2 (REDA)
  • Returns : trade history list based on criteria

func (*Client) GetTradeHistoryByTransactionID deprecated

func (a *Client) GetTradeHistoryByTransactionID(params *GetTradeHistoryByTransactionIDParams, authInfo runtime.ClientAuthInfoWriter) (*GetTradeHistoryByTransactionIDOK, error)

Deprecated: 2022-08-10 - Use GetTradeHistoryByTransactionIDShort instead.

GetTradeHistoryByTransactionID retrieve trade history by transaction id This API is used to fetch a specific trade history using transaction ID

Other detail info:

  • Required permission : resource=ADMIN:NAMESPACE:{namespace}:TRADE, action=2 (REDA)
  • Returns : trade history based on transaction ID

func (*Client) GetTradeHistoryByTransactionIDShort

func (a *Client) GetTradeHistoryByTransactionIDShort(params *GetTradeHistoryByTransactionIDParams, authInfo runtime.ClientAuthInfoWriter) (*GetTradeHistoryByTransactionIDOK, error)

GetTradeHistoryByTransactionIDShort retrieve trade history by transaction id This API is used to fetch a specific trade history using transaction ID

Other detail info:

  • Required permission : resource=ADMIN:NAMESPACE:{namespace}:TRADE, action=2 (REDA)
  • Returns : trade history based on transaction ID

func (*Client) SetTransport

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

SetTransport changes the transport on the client

type ClientService

type ClientService interface {
	Commit(params *CommitParams, authInfo runtime.ClientAuthInfoWriter) (*CommitOK, error)
	CommitShort(params *CommitParams, authInfo runtime.ClientAuthInfoWriter) (*CommitOK, error)
	GetTradeHistoryByCriteria(params *GetTradeHistoryByCriteriaParams, authInfo runtime.ClientAuthInfoWriter) (*GetTradeHistoryByCriteriaOK, error)
	GetTradeHistoryByCriteriaShort(params *GetTradeHistoryByCriteriaParams, authInfo runtime.ClientAuthInfoWriter) (*GetTradeHistoryByCriteriaOK, error)
	GetTradeHistoryByTransactionID(params *GetTradeHistoryByTransactionIDParams, authInfo runtime.ClientAuthInfoWriter) (*GetTradeHistoryByTransactionIDOK, error)
	GetTradeHistoryByTransactionIDShort(params *GetTradeHistoryByTransactionIDParams, authInfo runtime.ClientAuthInfoWriter) (*GetTradeHistoryByTransactionIDOK, 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 trade action API client.

type CommitOK

type CommitOK struct {
	Payload *platformclientmodels.TradeChainActionHistoryInfo
}

CommitOK handles this case with default header values.

successful operation

func NewCommitOK

func NewCommitOK() *CommitOK

NewCommitOK creates a CommitOK with default headers values

func (*CommitOK) Error

func (o *CommitOK) Error() string

func (*CommitOK) GetPayload

func (*CommitOK) ToJSONString

func (o *CommitOK) ToJSONString() string

type CommitParams

type CommitParams struct {

	/*RetryPolicy*/
	RetryPolicy *utils.Retry
	/*Body*/
	Body *platformclientmodels.TradeChainedActionCommitRequest
	/*Namespace
	  Namespace

	*/
	Namespace string

	AuthInfoWriter runtime.ClientAuthInfoWriter
	Context        context.Context
	HTTPClient     *http.Client

	// XFlightId is an optional parameter from this SDK
	XFlightId *string
	// contains filtered or unexported fields
}

CommitParams contains all the parameters to send to the API endpoint for the commit operation typically these are written to a http.Request

func NewCommitParams

func NewCommitParams() *CommitParams

NewCommitParams creates a new CommitParams object with the default values initialized.

func NewCommitParamsWithContext

func NewCommitParamsWithContext(ctx context.Context) *CommitParams

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

func NewCommitParamsWithHTTPClient

func NewCommitParamsWithHTTPClient(client *http.Client) *CommitParams

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

func NewCommitParamsWithTimeout

func NewCommitParamsWithTimeout(timeout time.Duration) *CommitParams

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

func (*CommitParams) SetAuthInfoWriter

func (o *CommitParams) SetAuthInfoWriter(authInfoWriter runtime.ClientAuthInfoWriter)

SetAuthInfoWriter adds the authInfoWriter to the commit params

func (*CommitParams) SetBody

SetBody adds the body to the commit params

func (*CommitParams) SetContext

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

SetContext adds the context to the commit params

func (*CommitParams) SetFlightId added in v0.63.0

func (o *CommitParams) SetFlightId(flightId string)

SetFlightId adds the flightId as the header value for this specific endpoint

func (*CommitParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the commit params

func (*CommitParams) SetHTTPClientTransport

func (o *CommitParams) SetHTTPClientTransport(roundTripper http.RoundTripper)

SetHTTPClient adds the HTTPClient Transport to the commit params

func (*CommitParams) SetNamespace

func (o *CommitParams) SetNamespace(namespace string)

SetNamespace adds the namespace to the commit params

func (*CommitParams) SetTimeout

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

SetTimeout adds the timeout to the commit params

func (*CommitParams) WithBody

WithBody adds the body to the commit params

func (*CommitParams) WithContext

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

WithContext adds the context to the commit params

func (*CommitParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the commit params

func (*CommitParams) WithNamespace

func (o *CommitParams) WithNamespace(namespace string) *CommitParams

WithNamespace adds the namespace to the commit params

func (*CommitParams) WithTimeout

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

WithTimeout adds the timeout to the commit params

func (*CommitParams) WriteToRequest

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

WriteToRequest writes these params to a swagger request

type CommitReader

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

CommitReader is a Reader for the Commit structure.

func (*CommitReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type GetTradeHistoryByCriteriaOK

type GetTradeHistoryByCriteriaOK struct {
	Payload *platformclientmodels.TradeActionPagingSlicedResult
}

GetTradeHistoryByCriteriaOK handles this case with default header values.

successful operation

func NewGetTradeHistoryByCriteriaOK

func NewGetTradeHistoryByCriteriaOK() *GetTradeHistoryByCriteriaOK

NewGetTradeHistoryByCriteriaOK creates a GetTradeHistoryByCriteriaOK with default headers values

func (*GetTradeHistoryByCriteriaOK) Error

func (*GetTradeHistoryByCriteriaOK) GetPayload added in v0.60.0

func (*GetTradeHistoryByCriteriaOK) ToJSONString added in v0.60.0

func (o *GetTradeHistoryByCriteriaOK) ToJSONString() string

type GetTradeHistoryByCriteriaParams

type GetTradeHistoryByCriteriaParams struct {

	/*RetryPolicy*/
	RetryPolicy *utils.Retry
	/*Namespace
	  Namespace

	*/
	Namespace string
	/*Limit*/
	Limit *int32
	/*Offset*/
	Offset *int32
	/*Status
	  Status of the trade (SUCCESS/FAIL)

	*/
	Status *string
	/*Type
	  Type of the trade

	*/
	Type *string
	/*UserID
	  User ID for which the trade history is queried

	*/
	UserID *string

	AuthInfoWriter runtime.ClientAuthInfoWriter
	Context        context.Context
	HTTPClient     *http.Client

	// XFlightId is an optional parameter from this SDK
	XFlightId *string
	// contains filtered or unexported fields
}

GetTradeHistoryByCriteriaParams contains all the parameters to send to the API endpoint for the get trade history by criteria operation typically these are written to a http.Request

func NewGetTradeHistoryByCriteriaParams

func NewGetTradeHistoryByCriteriaParams() *GetTradeHistoryByCriteriaParams

NewGetTradeHistoryByCriteriaParams creates a new GetTradeHistoryByCriteriaParams object with the default values initialized.

func NewGetTradeHistoryByCriteriaParamsWithContext

func NewGetTradeHistoryByCriteriaParamsWithContext(ctx context.Context) *GetTradeHistoryByCriteriaParams

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

func NewGetTradeHistoryByCriteriaParamsWithHTTPClient

func NewGetTradeHistoryByCriteriaParamsWithHTTPClient(client *http.Client) *GetTradeHistoryByCriteriaParams

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

func NewGetTradeHistoryByCriteriaParamsWithTimeout

func NewGetTradeHistoryByCriteriaParamsWithTimeout(timeout time.Duration) *GetTradeHistoryByCriteriaParams

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

func (*GetTradeHistoryByCriteriaParams) SetAuthInfoWriter

func (o *GetTradeHistoryByCriteriaParams) SetAuthInfoWriter(authInfoWriter runtime.ClientAuthInfoWriter)

SetAuthInfoWriter adds the authInfoWriter to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetContext

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

SetContext adds the context to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetFlightId added in v0.63.0

func (o *GetTradeHistoryByCriteriaParams) SetFlightId(flightId string)

SetFlightId adds the flightId as the header value for this specific endpoint

func (*GetTradeHistoryByCriteriaParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetHTTPClientTransport

func (o *GetTradeHistoryByCriteriaParams) SetHTTPClientTransport(roundTripper http.RoundTripper)

SetHTTPClient adds the HTTPClient Transport to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetLimit

func (o *GetTradeHistoryByCriteriaParams) SetLimit(limit *int32)

SetLimit adds the limit to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetNamespace

func (o *GetTradeHistoryByCriteriaParams) SetNamespace(namespace string)

SetNamespace adds the namespace to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetOffset

func (o *GetTradeHistoryByCriteriaParams) SetOffset(offset *int32)

SetOffset adds the offset to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetStatus

func (o *GetTradeHistoryByCriteriaParams) SetStatus(status *string)

SetStatus adds the status to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetTimeout

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

SetTimeout adds the timeout to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetType

func (o *GetTradeHistoryByCriteriaParams) SetType(typeVar *string)

SetType adds the type to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) SetUserID

func (o *GetTradeHistoryByCriteriaParams) SetUserID(userID *string)

SetUserID adds the userId to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithContext

WithContext adds the context to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithHTTPClient

WithHTTPClient adds the HTTPClient to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithLimit

WithLimit adds the limit to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithNamespace

WithNamespace adds the namespace to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithOffset

WithOffset adds the offset to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithStatus

WithStatus adds the status to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithTimeout

WithTimeout adds the timeout to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithType

WithType adds the typeVar to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WithUserID

WithUserID adds the userID to the get trade history by criteria params

func (*GetTradeHistoryByCriteriaParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type GetTradeHistoryByCriteriaReader

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

GetTradeHistoryByCriteriaReader is a Reader for the GetTradeHistoryByCriteria structure.

func (*GetTradeHistoryByCriteriaReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type GetTradeHistoryByTransactionIDOK

type GetTradeHistoryByTransactionIDOK struct {
	Payload *platformclientmodels.TradeChainActionHistoryInfo
}

GetTradeHistoryByTransactionIDOK handles this case with default header values.

successful operation

func NewGetTradeHistoryByTransactionIDOK

func NewGetTradeHistoryByTransactionIDOK() *GetTradeHistoryByTransactionIDOK

NewGetTradeHistoryByTransactionIDOK creates a GetTradeHistoryByTransactionIDOK with default headers values

func (*GetTradeHistoryByTransactionIDOK) Error

func (*GetTradeHistoryByTransactionIDOK) GetPayload added in v0.60.0

func (*GetTradeHistoryByTransactionIDOK) ToJSONString added in v0.60.0

func (o *GetTradeHistoryByTransactionIDOK) ToJSONString() string

type GetTradeHistoryByTransactionIDParams

type GetTradeHistoryByTransactionIDParams struct {

	/*RetryPolicy*/
	RetryPolicy *utils.Retry
	/*Namespace
	  Namespace

	*/
	Namespace string
	/*TransactionID
	  Transaction ID to query the trade history

	*/
	TransactionID string

	AuthInfoWriter runtime.ClientAuthInfoWriter
	Context        context.Context
	HTTPClient     *http.Client

	// XFlightId is an optional parameter from this SDK
	XFlightId *string
	// contains filtered or unexported fields
}

GetTradeHistoryByTransactionIDParams contains all the parameters to send to the API endpoint for the get trade history by transaction id operation typically these are written to a http.Request

func NewGetTradeHistoryByTransactionIDParams

func NewGetTradeHistoryByTransactionIDParams() *GetTradeHistoryByTransactionIDParams

NewGetTradeHistoryByTransactionIDParams creates a new GetTradeHistoryByTransactionIDParams object with the default values initialized.

func NewGetTradeHistoryByTransactionIDParamsWithContext

func NewGetTradeHistoryByTransactionIDParamsWithContext(ctx context.Context) *GetTradeHistoryByTransactionIDParams

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

func NewGetTradeHistoryByTransactionIDParamsWithHTTPClient

func NewGetTradeHistoryByTransactionIDParamsWithHTTPClient(client *http.Client) *GetTradeHistoryByTransactionIDParams

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

func NewGetTradeHistoryByTransactionIDParamsWithTimeout

func NewGetTradeHistoryByTransactionIDParamsWithTimeout(timeout time.Duration) *GetTradeHistoryByTransactionIDParams

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

func (*GetTradeHistoryByTransactionIDParams) SetAuthInfoWriter

func (o *GetTradeHistoryByTransactionIDParams) SetAuthInfoWriter(authInfoWriter runtime.ClientAuthInfoWriter)

SetAuthInfoWriter adds the authInfoWriter to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) SetContext

SetContext adds the context to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) SetFlightId added in v0.63.0

func (o *GetTradeHistoryByTransactionIDParams) SetFlightId(flightId string)

SetFlightId adds the flightId as the header value for this specific endpoint

func (*GetTradeHistoryByTransactionIDParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) SetHTTPClientTransport

func (o *GetTradeHistoryByTransactionIDParams) SetHTTPClientTransport(roundTripper http.RoundTripper)

SetHTTPClient adds the HTTPClient Transport to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) SetNamespace

func (o *GetTradeHistoryByTransactionIDParams) SetNamespace(namespace string)

SetNamespace adds the namespace to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) SetTimeout

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

SetTimeout adds the timeout to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) SetTransactionID

func (o *GetTradeHistoryByTransactionIDParams) SetTransactionID(transactionID string)

SetTransactionID adds the transactionId to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) WithContext

WithContext adds the context to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) WithHTTPClient

WithHTTPClient adds the HTTPClient to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) WithNamespace

WithNamespace adds the namespace to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) WithTimeout

WithTimeout adds the timeout to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) WithTransactionID

WithTransactionID adds the transactionID to the get trade history by transaction id params

func (*GetTradeHistoryByTransactionIDParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type GetTradeHistoryByTransactionIDReader

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

GetTradeHistoryByTransactionIDReader is a Reader for the GetTradeHistoryByTransactionID structure.

func (*GetTradeHistoryByTransactionIDReader) ReadResponse

func (o *GetTradeHistoryByTransactionIDReader) 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