v3

package
v0.0.0-...-cb4139d Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2023 License: AGPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ADRatio

type ADRatio struct {
	AdRatio     fixedpoint.Value `json:"ad_ratio"`
	AssetInUsdt fixedpoint.Value `json:"asset_in_usdt"`
	DebtInUsdt  fixedpoint.Value `json:"debt_in_usdt"`
}

type Account

type Account = maxapi.Account

type CancelOrderRequest

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

func (*CancelOrderRequest) ClientOrderID

func (c *CancelOrderRequest) ClientOrderID(clientOrderID string) *CancelOrderRequest

func (*CancelOrderRequest) Do

func (c *CancelOrderRequest) Do(ctx context.Context) (*max.Order, error)

func (*CancelOrderRequest) GetParameters

func (c *CancelOrderRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*CancelOrderRequest) GetParametersJSON

func (c *CancelOrderRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*CancelOrderRequest) GetParametersQuery

func (c *CancelOrderRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*CancelOrderRequest) GetQueryParameters

func (c *CancelOrderRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*CancelOrderRequest) GetSlugParameters

func (c *CancelOrderRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*CancelOrderRequest) GetSlugsMap

func (c *CancelOrderRequest) GetSlugsMap() (map[string]string, error)

func (*CancelOrderRequest) Id

type CancelWalletOrderAllRequest

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

func (*CancelWalletOrderAllRequest) Do

func (*CancelWalletOrderAllRequest) GetParameters

func (c *CancelWalletOrderAllRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*CancelWalletOrderAllRequest) GetParametersJSON

func (c *CancelWalletOrderAllRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*CancelWalletOrderAllRequest) GetParametersQuery

func (c *CancelWalletOrderAllRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*CancelWalletOrderAllRequest) GetQueryParameters

func (c *CancelWalletOrderAllRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*CancelWalletOrderAllRequest) GetSlugParameters

func (c *CancelWalletOrderAllRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*CancelWalletOrderAllRequest) GetSlugsMap

func (c *CancelWalletOrderAllRequest) GetSlugsMap() (map[string]string, error)

func (*CancelWalletOrderAllRequest) GroupID

func (*CancelWalletOrderAllRequest) Market

func (*CancelWalletOrderAllRequest) Side

func (*CancelWalletOrderAllRequest) WalletType

type Client

type Client struct {
	Client requestgen.AuthenticatedAPIClient
}

func (*Client) NewCancelOrderRequest

func (s *Client) NewCancelOrderRequest() *CancelOrderRequest

func (*Client) NewCancelWalletOrderAllRequest

func (s *Client) NewCancelWalletOrderAllRequest(walletType WalletType) *CancelWalletOrderAllRequest

func (*Client) NewCreateWalletOrderRequest

func (s *Client) NewCreateWalletOrderRequest(walletType WalletType) *CreateWalletOrderRequest

func (*Client) NewGetMarginADRatioRequest

func (s *Client) NewGetMarginADRatioRequest() *GetMarginADRatioRequest

func (*Client) NewGetMarginBorrowingLimitsRequest

func (s *Client) NewGetMarginBorrowingLimitsRequest() *GetMarginBorrowingLimitsRequest

func (*Client) NewGetMarginInterestHistoryRequest

func (s *Client) NewGetMarginInterestHistoryRequest(currency string) *GetMarginInterestHistoryRequest

func (*Client) NewGetMarginInterestRatesRequest

func (s *Client) NewGetMarginInterestRatesRequest() *GetMarginInterestRatesRequest

func (*Client) NewGetMarginLiquidationHistoryRequest

func (s *Client) NewGetMarginLiquidationHistoryRequest() *GetMarginLiquidationHistoryRequest

func (*Client) NewGetMarginLoanHistoryRequest

func (s *Client) NewGetMarginLoanHistoryRequest() *GetMarginLoanHistoryRequest

func (*Client) NewGetOrderRequest

func (s *Client) NewGetOrderRequest() *GetOrderRequest

func (*Client) NewGetOrderTradesRequest

func (s *Client) NewGetOrderTradesRequest() *GetOrderTradesRequest

func (*Client) NewGetWalletAccountsRequest

func (s *Client) NewGetWalletAccountsRequest(walletType WalletType) *GetWalletAccountsRequest

func (*Client) NewGetWalletOpenOrdersRequest

func (s *Client) NewGetWalletOpenOrdersRequest(walletType WalletType) *GetWalletOpenOrdersRequest

func (*Client) NewGetWalletOrderHistoryRequest

func (s *Client) NewGetWalletOrderHistoryRequest(walletType WalletType) *GetWalletOrderHistoryRequest

func (*Client) NewGetWalletTradesRequest

func (s *Client) NewGetWalletTradesRequest(walletType WalletType) *GetWalletTradesRequest

func (*Client) NewMarginLoanRequest

func (s *Client) NewMarginLoanRequest() *MarginLoanRequest

func (*Client) NewMarginRepayRequest

func (s *Client) NewMarginRepayRequest() *MarginRepayRequest

type CreateWalletOrderRequest

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

func (*CreateWalletOrderRequest) ClientOrderID

func (c *CreateWalletOrderRequest) ClientOrderID(clientOrderID string) *CreateWalletOrderRequest

func (*CreateWalletOrderRequest) Do

func (c *CreateWalletOrderRequest) Do(ctx context.Context) (*max.Order, error)

func (*CreateWalletOrderRequest) GetParameters

func (c *CreateWalletOrderRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*CreateWalletOrderRequest) GetParametersJSON

func (c *CreateWalletOrderRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*CreateWalletOrderRequest) GetParametersQuery

func (c *CreateWalletOrderRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*CreateWalletOrderRequest) GetQueryParameters

func (c *CreateWalletOrderRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*CreateWalletOrderRequest) GetSlugParameters

func (c *CreateWalletOrderRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*CreateWalletOrderRequest) GetSlugsMap

func (c *CreateWalletOrderRequest) GetSlugsMap() (map[string]string, error)

func (*CreateWalletOrderRequest) GroupID

func (*CreateWalletOrderRequest) Market

func (*CreateWalletOrderRequest) OrderType

func (c *CreateWalletOrderRequest) OrderType(orderType max.OrderType) *CreateWalletOrderRequest

func (*CreateWalletOrderRequest) Price

func (*CreateWalletOrderRequest) Side

func (*CreateWalletOrderRequest) StopPrice

func (c *CreateWalletOrderRequest) StopPrice(stopPrice string) *CreateWalletOrderRequest

func (*CreateWalletOrderRequest) Volume

func (*CreateWalletOrderRequest) WalletType

func (c *CreateWalletOrderRequest) WalletType(walletType max.WalletType) *CreateWalletOrderRequest

type GetMarginADRatioRequest

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

func (*GetMarginADRatioRequest) Do

func (*GetMarginADRatioRequest) GetParameters

func (g *GetMarginADRatioRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetMarginADRatioRequest) GetParametersJSON

func (g *GetMarginADRatioRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetMarginADRatioRequest) GetParametersQuery

func (g *GetMarginADRatioRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetMarginADRatioRequest) GetQueryParameters

func (g *GetMarginADRatioRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetMarginADRatioRequest) GetSlugParameters

func (g *GetMarginADRatioRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetMarginADRatioRequest) GetSlugsMap

func (g *GetMarginADRatioRequest) GetSlugsMap() (map[string]string, error)

type GetMarginBorrowingLimitsRequest

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

func (*GetMarginBorrowingLimitsRequest) Do

func (*GetMarginBorrowingLimitsRequest) GetParameters

func (g *GetMarginBorrowingLimitsRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetMarginBorrowingLimitsRequest) GetParametersJSON

func (g *GetMarginBorrowingLimitsRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetMarginBorrowingLimitsRequest) GetParametersQuery

func (g *GetMarginBorrowingLimitsRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetMarginBorrowingLimitsRequest) GetQueryParameters

func (g *GetMarginBorrowingLimitsRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetMarginBorrowingLimitsRequest) GetSlugParameters

func (g *GetMarginBorrowingLimitsRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetMarginBorrowingLimitsRequest) GetSlugsMap

func (g *GetMarginBorrowingLimitsRequest) GetSlugsMap() (map[string]string, error)

type GetMarginInterestHistoryRequest

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

func (*GetMarginInterestHistoryRequest) Currency

func (*GetMarginInterestHistoryRequest) Do

func (*GetMarginInterestHistoryRequest) EndTime

func (*GetMarginInterestHistoryRequest) GetParameters

func (g *GetMarginInterestHistoryRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetMarginInterestHistoryRequest) GetParametersJSON

func (g *GetMarginInterestHistoryRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetMarginInterestHistoryRequest) GetParametersQuery

func (g *GetMarginInterestHistoryRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetMarginInterestHistoryRequest) GetQueryParameters

func (g *GetMarginInterestHistoryRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetMarginInterestHistoryRequest) GetSlugParameters

func (g *GetMarginInterestHistoryRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetMarginInterestHistoryRequest) GetSlugsMap

func (g *GetMarginInterestHistoryRequest) GetSlugsMap() (map[string]string, error)

func (*GetMarginInterestHistoryRequest) Limit

func (*GetMarginInterestHistoryRequest) StartTime

type GetMarginInterestRatesRequest

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

func (*GetMarginInterestRatesRequest) Do

func (*GetMarginInterestRatesRequest) GetParameters

func (g *GetMarginInterestRatesRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetMarginInterestRatesRequest) GetParametersJSON

func (g *GetMarginInterestRatesRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetMarginInterestRatesRequest) GetParametersQuery

func (g *GetMarginInterestRatesRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetMarginInterestRatesRequest) GetQueryParameters

func (g *GetMarginInterestRatesRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetMarginInterestRatesRequest) GetSlugParameters

func (g *GetMarginInterestRatesRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetMarginInterestRatesRequest) GetSlugsMap

func (g *GetMarginInterestRatesRequest) GetSlugsMap() (map[string]string, error)

type GetMarginLiquidationHistoryRequest

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

func (*GetMarginLiquidationHistoryRequest) Do

func (*GetMarginLiquidationHistoryRequest) EndTime

func (*GetMarginLiquidationHistoryRequest) GetParameters

func (g *GetMarginLiquidationHistoryRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetMarginLiquidationHistoryRequest) GetParametersJSON

func (g *GetMarginLiquidationHistoryRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetMarginLiquidationHistoryRequest) GetParametersQuery

func (g *GetMarginLiquidationHistoryRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetMarginLiquidationHistoryRequest) GetQueryParameters

func (g *GetMarginLiquidationHistoryRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetMarginLiquidationHistoryRequest) GetSlugParameters

func (g *GetMarginLiquidationHistoryRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetMarginLiquidationHistoryRequest) GetSlugsMap

func (g *GetMarginLiquidationHistoryRequest) GetSlugsMap() (map[string]string, error)

func (*GetMarginLiquidationHistoryRequest) Limit

func (*GetMarginLiquidationHistoryRequest) StartTime

type GetMarginLoanHistoryRequest

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

func (*GetMarginLoanHistoryRequest) Currency

func (*GetMarginLoanHistoryRequest) Do

func (*GetMarginLoanHistoryRequest) EndTime

func (*GetMarginLoanHistoryRequest) GetParameters

func (g *GetMarginLoanHistoryRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetMarginLoanHistoryRequest) GetParametersJSON

func (g *GetMarginLoanHistoryRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetMarginLoanHistoryRequest) GetParametersQuery

func (g *GetMarginLoanHistoryRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetMarginLoanHistoryRequest) GetQueryParameters

func (g *GetMarginLoanHistoryRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetMarginLoanHistoryRequest) GetSlugParameters

func (g *GetMarginLoanHistoryRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetMarginLoanHistoryRequest) GetSlugsMap

func (g *GetMarginLoanHistoryRequest) GetSlugsMap() (map[string]string, error)

func (*GetMarginLoanHistoryRequest) Limit

func (*GetMarginLoanHistoryRequest) StartTime

type GetMarginRepaymentHistoryRequest

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

func (*GetMarginRepaymentHistoryRequest) Currency

func (*GetMarginRepaymentHistoryRequest) Do

func (*GetMarginRepaymentHistoryRequest) EndTime

func (*GetMarginRepaymentHistoryRequest) GetParameters

func (g *GetMarginRepaymentHistoryRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetMarginRepaymentHistoryRequest) GetParametersJSON

func (g *GetMarginRepaymentHistoryRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetMarginRepaymentHistoryRequest) GetParametersQuery

func (g *GetMarginRepaymentHistoryRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetMarginRepaymentHistoryRequest) GetQueryParameters

func (g *GetMarginRepaymentHistoryRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetMarginRepaymentHistoryRequest) GetSlugParameters

func (g *GetMarginRepaymentHistoryRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetMarginRepaymentHistoryRequest) GetSlugsMap

func (g *GetMarginRepaymentHistoryRequest) GetSlugsMap() (map[string]string, error)

func (*GetMarginRepaymentHistoryRequest) Limit

func (*GetMarginRepaymentHistoryRequest) StartTime

type GetOrderRequest

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

func (*GetOrderRequest) ClientOrderID

func (g *GetOrderRequest) ClientOrderID(clientOrderID string) *GetOrderRequest

func (*GetOrderRequest) Do

func (g *GetOrderRequest) Do(ctx context.Context) (*max.Order, error)

func (*GetOrderRequest) GetParameters

func (g *GetOrderRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetOrderRequest) GetParametersJSON

func (g *GetOrderRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetOrderRequest) GetParametersQuery

func (g *GetOrderRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetOrderRequest) GetQueryParameters

func (g *GetOrderRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetOrderRequest) GetSlugParameters

func (g *GetOrderRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetOrderRequest) GetSlugsMap

func (g *GetOrderRequest) GetSlugsMap() (map[string]string, error)

func (*GetOrderRequest) Id

type GetOrderTradesRequest

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

func (*GetOrderTradesRequest) ClientOrderID

func (g *GetOrderTradesRequest) ClientOrderID(clientOrderID string) *GetOrderTradesRequest

func (*GetOrderTradesRequest) Do

func (*GetOrderTradesRequest) GetParameters

func (g *GetOrderTradesRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetOrderTradesRequest) GetParametersJSON

func (g *GetOrderTradesRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetOrderTradesRequest) GetParametersQuery

func (g *GetOrderTradesRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetOrderTradesRequest) GetQueryParameters

func (g *GetOrderTradesRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetOrderTradesRequest) GetSlugParameters

func (g *GetOrderTradesRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetOrderTradesRequest) GetSlugsMap

func (g *GetOrderTradesRequest) GetSlugsMap() (map[string]string, error)

func (*GetOrderTradesRequest) OrderID

func (g *GetOrderTradesRequest) OrderID(orderID uint64) *GetOrderTradesRequest

type GetWalletAccountsRequest

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

func (*GetWalletAccountsRequest) Currency

func (*GetWalletAccountsRequest) Do

func (g *GetWalletAccountsRequest) Do(ctx context.Context) ([]max.Account, error)

func (*GetWalletAccountsRequest) GetParameters

func (g *GetWalletAccountsRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetWalletAccountsRequest) GetParametersJSON

func (g *GetWalletAccountsRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetWalletAccountsRequest) GetParametersQuery

func (g *GetWalletAccountsRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetWalletAccountsRequest) GetQueryParameters

func (g *GetWalletAccountsRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetWalletAccountsRequest) GetSlugParameters

func (g *GetWalletAccountsRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetWalletAccountsRequest) GetSlugsMap

func (g *GetWalletAccountsRequest) GetSlugsMap() (map[string]string, error)

func (*GetWalletAccountsRequest) WalletType

func (g *GetWalletAccountsRequest) WalletType(walletType max.WalletType) *GetWalletAccountsRequest

type GetWalletOpenOrdersRequest

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

func (*GetWalletOpenOrdersRequest) Do

func (g *GetWalletOpenOrdersRequest) Do(ctx context.Context) ([]max.Order, error)

func (*GetWalletOpenOrdersRequest) GetParameters

func (g *GetWalletOpenOrdersRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetWalletOpenOrdersRequest) GetParametersJSON

func (g *GetWalletOpenOrdersRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetWalletOpenOrdersRequest) GetParametersQuery

func (g *GetWalletOpenOrdersRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetWalletOpenOrdersRequest) GetQueryParameters

func (g *GetWalletOpenOrdersRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetWalletOpenOrdersRequest) GetSlugParameters

func (g *GetWalletOpenOrdersRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetWalletOpenOrdersRequest) GetSlugsMap

func (g *GetWalletOpenOrdersRequest) GetSlugsMap() (map[string]string, error)

func (*GetWalletOpenOrdersRequest) Market

func (*GetWalletOpenOrdersRequest) WalletType

func (g *GetWalletOpenOrdersRequest) WalletType(walletType max.WalletType) *GetWalletOpenOrdersRequest

type GetWalletOrderHistoryRequest

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

func (*GetWalletOrderHistoryRequest) Do

func (g *GetWalletOrderHistoryRequest) Do(ctx context.Context) ([]max.Order, error)

func (*GetWalletOrderHistoryRequest) FromID

func (*GetWalletOrderHistoryRequest) GetParameters

func (g *GetWalletOrderHistoryRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetWalletOrderHistoryRequest) GetParametersJSON

func (g *GetWalletOrderHistoryRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetWalletOrderHistoryRequest) GetParametersQuery

func (g *GetWalletOrderHistoryRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetWalletOrderHistoryRequest) GetQueryParameters

func (g *GetWalletOrderHistoryRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetWalletOrderHistoryRequest) GetSlugParameters

func (g *GetWalletOrderHistoryRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetWalletOrderHistoryRequest) GetSlugsMap

func (g *GetWalletOrderHistoryRequest) GetSlugsMap() (map[string]string, error)

func (*GetWalletOrderHistoryRequest) Limit

func (*GetWalletOrderHistoryRequest) Market

func (*GetWalletOrderHistoryRequest) WalletType

func (g *GetWalletOrderHistoryRequest) WalletType(walletType max.WalletType) *GetWalletOrderHistoryRequest

type GetWalletTradesRequest

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

func (*GetWalletTradesRequest) Do

func (*GetWalletTradesRequest) EndTime

func (*GetWalletTradesRequest) From

func (*GetWalletTradesRequest) GetParameters

func (g *GetWalletTradesRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*GetWalletTradesRequest) GetParametersJSON

func (g *GetWalletTradesRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*GetWalletTradesRequest) GetParametersQuery

func (g *GetWalletTradesRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*GetWalletTradesRequest) GetQueryParameters

func (g *GetWalletTradesRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*GetWalletTradesRequest) GetSlugParameters

func (g *GetWalletTradesRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*GetWalletTradesRequest) GetSlugsMap

func (g *GetWalletTradesRequest) GetSlugsMap() (map[string]string, error)

func (*GetWalletTradesRequest) Limit

func (*GetWalletTradesRequest) Market

func (*GetWalletTradesRequest) StartTime

func (g *GetWalletTradesRequest) StartTime(startTime time.Time) *GetWalletTradesRequest

func (*GetWalletTradesRequest) WalletType

func (g *GetWalletTradesRequest) WalletType(walletType max.WalletType) *GetWalletTradesRequest

type LiquidationRecord

type LiquidationRecord struct {
	SN              string                     `json:"sn"`
	AdRatio         fixedpoint.Value           `json:"ad_ratio"`
	ExpectedAdRatio fixedpoint.Value           `json:"expected_ad_ratio"`
	CreatedAt       types.MillisecondTimestamp `json:"created_at"`
	State           LiquidationState           `json:"state"`
}

type LiquidationState

type LiquidationState string
const (
	LiquidationStateProcessing LiquidationState = "processing"
	LiquidationStateDebt       LiquidationState = "debt"
	LiquidationStateLiquidated LiquidationState = "liquidated"
)

type LoanRecord

type LoanRecord struct {
	SN           string                     `json:"sn"`
	Currency     string                     `json:"currency"`
	Amount       fixedpoint.Value           `json:"amount"`
	State        string                     `json:"state"`
	CreatedAt    types.MillisecondTimestamp `json:"created_at"`
	InterestRate fixedpoint.Value           `json:"interest_rate"`
}

type MarginBorrowingLimitMap

type MarginBorrowingLimitMap map[string]fixedpoint.Value

type MarginInterestRate

type MarginInterestRate struct {
	HourlyInterestRate     fixedpoint.Value `json:"hourly_interest_rate"`
	NextHourlyInterestRate fixedpoint.Value `json:"next_hourly_interest_rate"`
}

type MarginInterestRateMap

type MarginInterestRateMap map[string]MarginInterestRate

type MarginInterestRecord

type MarginInterestRecord struct {
	Currency     string                     `json:"currency"`
	Amount       fixedpoint.Value           `json:"amount"`
	InterestRate fixedpoint.Value           `json:"interest_rate"`
	CreatedAt    types.MillisecondTimestamp `json:"created_at"`
}

type MarginLoanRequest

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

func (*MarginLoanRequest) Amount

func (m *MarginLoanRequest) Amount(amount string) *MarginLoanRequest

func (*MarginLoanRequest) Currency

func (m *MarginLoanRequest) Currency(currency string) *MarginLoanRequest

func (*MarginLoanRequest) Do

func (*MarginLoanRequest) GetParameters

func (m *MarginLoanRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*MarginLoanRequest) GetParametersJSON

func (m *MarginLoanRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*MarginLoanRequest) GetParametersQuery

func (m *MarginLoanRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*MarginLoanRequest) GetQueryParameters

func (m *MarginLoanRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*MarginLoanRequest) GetSlugParameters

func (m *MarginLoanRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*MarginLoanRequest) GetSlugsMap

func (m *MarginLoanRequest) GetSlugsMap() (map[string]string, error)

type MarginRepayRequest

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

func (*MarginRepayRequest) Amount

func (m *MarginRepayRequest) Amount(amount string) *MarginRepayRequest

func (*MarginRepayRequest) Currency

func (m *MarginRepayRequest) Currency(currency string) *MarginRepayRequest

func (*MarginRepayRequest) Do

func (*MarginRepayRequest) GetParameters

func (m *MarginRepayRequest) GetParameters() (map[string]interface{}, error)

GetParameters builds and checks the parameters and return the result in a map object

func (*MarginRepayRequest) GetParametersJSON

func (m *MarginRepayRequest) GetParametersJSON() ([]byte, error)

GetParametersJSON converts the parameters from GetParameters into the JSON format

func (*MarginRepayRequest) GetParametersQuery

func (m *MarginRepayRequest) GetParametersQuery() (url.Values, error)

GetParametersQuery converts the parameters from GetParameters into the url.Values format

func (*MarginRepayRequest) GetQueryParameters

func (m *MarginRepayRequest) GetQueryParameters() (url.Values, error)

GetQueryParameters builds and checks the query parameters and returns url.Values

func (*MarginRepayRequest) GetSlugParameters

func (m *MarginRepayRequest) GetSlugParameters() (map[string]interface{}, error)

GetSlugParameters builds and checks the slug parameters and return the result in a map object

func (*MarginRepayRequest) GetSlugsMap

func (m *MarginRepayRequest) GetSlugsMap() (map[string]string, error)

type MarginService

type MarginService struct {
	Client *maxapi.RestClient
}

type Order

type Order = maxapi.Order

type OrderCancelResponse

type OrderCancelResponse struct {
	Order Order
	Error *string
}

type OrderType

type OrderType = maxapi.OrderType

type RepaymentRecord

type RepaymentRecord struct {
	SN        string                     `json:"sn"`
	Currency  string                     `json:"currency"`
	Amount    fixedpoint.Value           `json:"amount"`
	Principal fixedpoint.Value           `json:"principal"`
	Interest  fixedpoint.Value           `json:"interest"`
	CreatedAt types.MillisecondTimestamp `json:"created_at"`
	State     string                     `json:"state"`
}

type Trade

type Trade struct {
	ID                      uint64                     `json:"id" db:"exchange_id"`
	WalletType              WalletType                 `json:"wallet_type,omitempty"`
	Price                   fixedpoint.Value           `json:"price"`
	Volume                  fixedpoint.Value           `json:"volume"`
	Funds                   fixedpoint.Value           `json:"funds"`
	Market                  string                     `json:"market"`
	MarketName              string                     `json:"market_name"`
	CreatedAt               types.MillisecondTimestamp `json:"created_at"`
	Side                    string                     `json:"side"`
	OrderID                 uint64                     `json:"order_id"`
	Fee                     fixedpoint.Value           `json:"fee"` // float number as string
	FeeCurrency             string                     `json:"fee_currency"`
	Liquidity               string                     `json:"liquidity"`
	SelfTradeBidFee         fixedpoint.Value           `json:"self_trade_bid_fee"`
	SelfTradeBidFeeCurrency string                     `json:"self_trade_bid_fee_currency"`
	SelfTradeBidOrderID     uint64                     `json:"self_trade_bid_order_id"`
}

func (Trade) IsBuyer

func (t Trade) IsBuyer() bool

func (Trade) IsMaker

func (t Trade) IsMaker() bool

type WalletType

type WalletType = maxapi.WalletType

create type alias

Jump to

Keyboard shortcuts

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