Documentation
¶
Index ¶
- func ComputeHmac256(message string, secret string) string
- func CreateNonce() int64
- type Account
- type AccountBalance
- type AccountInfo
- type Bank
- type BankAccount
- type Book
- type Client
- type Deposit
- type ExchangeFees
- type Order
- type OrderBook
- type RequestForOrder
- type Response
- type ResponseForCancelStatus
- type ResponseForDeposit
- type ResponseForOpenOrder
- type ResponseForOrder
- type ResponseForOrderBook
- type ResponseForPagination
- type ResponseForTicker
- type ResponseForTrade
- type ResponseForTransaction
- type Send
- type Ticker
- type Trade
- type Withdraw
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AccountBalance ¶
type AccountBalance struct {
Success bool `json:"success"`
JPY string `json:"jpy"`
BTC string `json:"btc"`
JPYReserved string `json:"jpy_reserved"`
BTCReserved string `json:"btc_reserved"`
JPYLendInUse string `json:"jpy_lend_in_use"`
BTCLendInUse string `json:"btc_lend_in_use"`
JPYLent string `json:"jpy_lent"`
BTCLent string `json:"btc_lent"`
JPYDebt string `json:"jpy_debt"`
BTCDebt string `json:"btc_debt"`
JPYTsumitate string `json:"jpy_tsumitate"`
BTCTsumitate string `json:"btc_tsumitate"`
}
type AccountInfo ¶
type AccountInfo struct {
Success bool `json:"success"`
ID int `json:"id"`
Email string `json:"email"`
IdentityStatus string `json:"identity_status"`
BitcoinAddress string `json:"bitcoin_address"`
TakerFee string `json:"taker_fee"`
MakerFee string `json:"maker_fee"`
ExchangeFees map[string]ExchangeFees `json:"exchange_fees"`
}
type BankAccount ¶
type BankAccount struct {
// contains filtered or unexported fields
}
type Client ¶
type ExchangeFees ¶
type Order ¶
type Order struct {
// contains filtered or unexported fields
}
func (Order) Cancel ¶
cancel a created order specified by order id. Optional argument amount is to refund partially.
func (Order) CancelStatus ¶
func (a Order) CancelStatus(id string) (*ResponseForCancelStatus, error)
CancelStatus returns the status of the order cancellation.
func (Order) Create ¶
func (a Order) Create(op RequestForOrder) (*ResponseForOrder, error)
Create a order object with given parameters.In live mode, this issues a transaction.
func (Order) Opens ¶
func (a Order) Opens() ([]ResponseForOrder, error)
List charges filtered by params
func (Order) Transactions ¶
func (a Order) Transactions() ([]ResponseForTransaction, error)
Get Order Transactions
type RequestForOrder ¶
type RequestForOrder struct {
Pair string `json:"pair"` // 取引ペア(例: "btc_jpy")
OrderType string `json:"order_type"` // 注文方法("buy", "sell", "market_buy", "market_sell")
Price string `json:"rate,omitempty"` // 注文のレート(例: "28000")、指値注文の場合に必要
Amount string `json:"amount,omitempty"` // 注文での量(例: "0.1")、指値注文および成行売り注文の場合に必要
MarketBuyAmount string `json:"market_buy_amount,omitempty"` // 成行買で利用する日本円の金額(例: "10000")、成行買い注文の場合に必要
StopLossRate string `json:"stop_loss_rate,omitempty"` // 逆指値レート、オプショナル
TimeInForce string `json:"time_in_force,omitempty"` // 注文有効期間("good_til_cancelled" あるいは "post_only")、オプショナル
}
type ResponseForCancelStatus ¶
type ResponseForDeposit ¶
type ResponseForOpenOrder ¶
type ResponseForOpenOrder struct {
ID int `json:"id"`
Pair string `json:"pair"`
Rate float64 `json:"rate"` // nullの場合があるためポインタ型を使用
PendingAmount string `json:"pending_amount"` // nullの場合があるためポインタ型を使用
OrderType string `json:"order_type"`
PendingMarketBuyAmount string `json:"pending_market_buy_amount"` // nullの場合があるためポインタ型を使用
StopLossRate string `json:"stop_loss_rate"` // nullの場合があるためポインタ型を使用
CreatedAt time.Time `json:"created_at"`
}
type ResponseForOrder ¶
type ResponseForOrder struct {
ID int `json:"id"`
Pair string `json:"pair"`
Rate string `json:"rate"`
Amount string `json:"amount"`
OrderType string `json:"order_type"`
TimeInForce string `json:"time_in_force"`
StopLossRate string `json:"stop_loss_rate,omitempty"`
CreatedAt time.Time `json:"created_at"`
}
type ResponseForOrderBook ¶
func (*ResponseForOrderBook) UnmarshalJSON ¶
func (o *ResponseForOrderBook) UnmarshalJSON(data []byte) error
type ResponseForPagination ¶
type ResponseForTicker ¶
type ResponseForTrade ¶
type ResponseForTransaction ¶
type ResponseForTransaction struct {
ID int `json:"id"`
OrderID int `json:"order_id"`
Pair string `json:"pair"`
Side string `json:"side"`
Rate string `json:"rate"`
Fee string `json:"fee"`
FeeCurrency string `json:"fee_currency"`
Liquidity string `json:"liquidity"`
Funds map[string]interface{} `json:"funds"`
CreatedAt time.Time `json:"created_at"`
}
type Send ¶
type Send struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.