kucoin

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KuCoin

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

func New

func New(apiKey, apiSecret, apiPassphrase string) *KuCoin

func NewWithConfig

func NewWithConfig(config *APIConfig) *KuCoin

func (*KuCoin) Account

func (kc *KuCoin) Account(accountId string) (*kucoin.AccountModel, error)

Account returns an account when you know the accountId.

func (*KuCoin) Accounts

func (kc *KuCoin) Accounts(currency, typo string) (kucoin.AccountsModel, error)

Accounts returns a list of accounts.

func (*KuCoin) ApplyWithdrawal

func (kc *KuCoin) ApplyWithdrawal(currency, address, amount, memo, isInner, remark, chain string) (string, error)

ApplyWithdrawal applies a withdrawal.

func (*KuCoin) CancelOrder

func (kc *KuCoin) CancelOrder(orderId string, currency CurrencyPair) (bool, error)

func (*KuCoin) CancelWithdrawal

func (kc *KuCoin) CancelWithdrawal(withdrawalId string) (*kucoin.CancelWithdrawalResultModel, error)

CancelWithdrawal cancels a withdrawal by withdrawalId.

func (*KuCoin) CreateAccount

func (kc *KuCoin) CreateAccount(typo, currency string) (*kucoin.AccountModel, error)

CreateAccount creates an account according to type(main|trade) and currency Parameter #1 typo is type of account.

func (*KuCoin) CreateDepositAddress

func (kc *KuCoin) CreateDepositAddress(currency, chain string) (*kucoin.DepositAddressModel, error)

CreateDepositAddress creates a deposit address.

func (*KuCoin) DepositAddresses

func (kc *KuCoin) DepositAddresses(currency, chain string) (*kucoin.DepositAddressModel, error)

DepositAddresses returns the deposit address of currency for deposit. If return data is empty, you may need create a deposit address first.

func (*KuCoin) Deposits

func (kc *KuCoin) Deposits(currency, startAt, endAt, status string) (*kucoin.DepositsModel, error)

Deposits returns a list of deposit.

func (*KuCoin) GetAccount

func (kc *KuCoin) GetAccount() (*Account, error)

func (*KuCoin) GetDepth

func (kc *KuCoin) GetDepth(size int, currency CurrencyPair) (*Depth, error)

func (*KuCoin) GetExchangeName

func (kc *KuCoin) GetExchangeName() string

func (*KuCoin) GetKlineRecords

func (kc *KuCoin) GetKlineRecords(currency CurrencyPair, period KlinePeriod, size int, optional ...OptionalParameter) ([]Kline, error)

func (*KuCoin) GetOneOrder

func (kc *KuCoin) GetOneOrder(orderId string, currency CurrencyPair) (*Order, error)

func (*KuCoin) GetOrderHistorys

func (kc *KuCoin) GetOrderHistorys(currency CurrencyPair, optional ...OptionalParameter) ([]Order, error)

func (*KuCoin) GetTicker

func (kc *KuCoin) GetTicker(currency CurrencyPair) (*Ticker, error)

func (*KuCoin) GetTrades

func (kc *KuCoin) GetTrades(currency CurrencyPair, since int64) ([]Trade, error)

func (*KuCoin) GetUnfinishOrders

func (kc *KuCoin) GetUnfinishOrders(currency CurrencyPair) ([]Order, error)

func (*KuCoin) InnerTransfer

func (kc *KuCoin) InnerTransfer(currency, from, to, amount string) (string, error)

The inner transfer interface is used for transferring assets between the accounts of a user and is free of charges. For example, a user could transfer assets from their main account to their trading account on the platform.

func (*KuCoin) LimitBuy

func (kc *KuCoin) LimitBuy(amount, price string, currency CurrencyPair, opt ...LimitOrderOptionalParameter) (*Order, error)

func (*KuCoin) LimitSell

func (kc *KuCoin) LimitSell(amount, price string, currency CurrencyPair, opt ...LimitOrderOptionalParameter) (*Order, error)

func (*KuCoin) MarketBuy

func (kc *KuCoin) MarketBuy(amount, price string, currency CurrencyPair) (*Order, error)

func (*KuCoin) MarketSell

func (kc *KuCoin) MarketSell(amount, price string, currency CurrencyPair) (*Order, error)

func (*KuCoin) SubAccount

func (kc *KuCoin) SubAccount(subUserId string) (*kucoin.SubAccountModel, error)

SubAccount returns the detail of a sub-account.

func (*KuCoin) SubAccountUsers

func (kc *KuCoin) SubAccountUsers() (kucoin.SubAccountUsersModel, error)

SubAccountUsers returns a list of sub-account user.

func (*KuCoin) SubAccounts

func (kc *KuCoin) SubAccounts() (kucoin.SubAccountsModel, error)

SubAccounts returns the aggregated balance of all sub-accounts of the current user.

func (*KuCoin) SubTransfer

func (kc *KuCoin) SubTransfer(currency, amount, direction, subUserId, accountType, subAccountType string) (string, error)

SubTransfer transfers between master account and sub-account.

func (*KuCoin) WithdrawalQuotas

func (kc *KuCoin) WithdrawalQuotas(currency, chain string) (*kucoin.WithdrawalQuotasModel, error)

WithdrawalQuotas returns the quotas of withdrawal.

func (*KuCoin) Withdrawals

func (kc *KuCoin) Withdrawals(currency, startAt, endAt, status string) (*kucoin.WithdrawalsModel, error)

Deposits returns a list of deposit.

Jump to

Keyboard shortcuts

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