Documentation ¶
Index ¶
- Constants
- func ToPrice(price float64) float64
- func ToSide(side int) string
- func ToSize(size float64) float64
- func ToTimeByOrderID(s string) (time.Time, error)
- func ToType(isMarket bool) string
- type API
- type APIHeaders
- type Client
- func (c *Client) APIHost() string
- func (c *Client) Addresses(req *addresses.Request) (*addresses.Response, *http.Response, error)
- func (c *Client) Balance(req *balance.Request) (*balance.Response, *http.Response, error)
- func (c *Client) BankAccounts(req *bankaccounts.Request) (*bankaccounts.Response, *http.Response, error)
- func (c *Client) Board(req *board.Request) (*board.Response, *http.Response, error)
- func (c *Client) CancelByID(req *cpositions.Request) (*cpositions.Response, *http.Response, error)
- func (c *Client) CancelOrderAll(req *corders.Request) (*corders.Response, *http.Response, error)
- func (c *Client) Chats(req *chats.Request) (*chats.Response, *http.Response, error)
- func (c *Client) ChildOrdersMe(req *childorders.Request) (*childorders.Response, *http.Response, error)
- func (c *Client) Coinins(req *coinins.Request) (*coinins.Response, *http.Response, error)
- func (c *Client) Coinouts(req *coinouts.Request) (*coinouts.Response, *http.Response, error)
- func (c *Client) Collateral(req *collateral.Request) (*collateral.Response, *http.Response, error)
- func (c *Client) CollateralAccounts(req *amounts.Request) (*amounts.Response, *http.Response, error)
- func (c *Client) Executions(req *executions.Request) (*executions.Response, *http.Response, error)
- func (c *Client) ExecutionsMe(req *ex.Request) (*ex.Response, *http.Response, error)
- func (c *Client) Health(req *health.Request) (*health.Response, *http.Response, error)
- func (c *Client) Histories(req *histories.Request) (*histories.Response, *http.Response, error)
- func (c *Client) Markets(req *markets.Request) (*markets.Response, *http.Response, error)
- func (c *Client) OrderSP(req *sp.Request) (*sp.Response, *http.Response, error)
- func (c *Client) OrderSingle(req *single.Request) (*single.Response, *http.Response, error)
- func (c *Client) Permissions(req *permissions.Request) (*permissions.Response, *http.Response, error)
- func (c *Client) Positions(req *positions.Request) (*positions.Response, *http.Response, error)
- func (c *Client) Ticker(req *ticker.Request) (*ticker.Response, *http.Response, error)
- type ClientOpts
- type Limit
Constants ¶
View Source
const ( // MARKET is 成行き MARKET = "MARKET" // LIMIT is 指値 LIMIT = "LIMIT" // BUY is 買い注文 BUY = "BUY" // SELL is 売り注文 SELL = "SELL" // Type TimeInForce IOC = "IOC" FOK = "FOK" APIREMAIN = 500 APIREMAINFORORDER = 300 TIMELAYOUT = "20060102.150405.999999999" )
View Source
const ( APIHost string = "https://api.bitflyer.jp" APIHostCom string = "https://api.bitflyer.com" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type APIHeaders ¶
基本的には5分毎リセット
type Client ¶
type Client struct { Host string HTTPClient *httpclient.Client AuthConfig *auth.AuthConfig }
func NewClient ¶
func NewClient(opts *ClientOpts) *Client
func (*Client) BankAccounts ¶
func (c *Client) BankAccounts(req *bankaccounts.Request) (*bankaccounts.Response, *http.Response, error)
func (*Client) CancelByID ¶
func (c *Client) CancelByID(req *cpositions.Request) (*cpositions.Response, *http.Response, error)
func (*Client) CancelOrderAll ¶
func (*Client) ChildOrdersMe ¶
func (c *Client) ChildOrdersMe(req *childorders.Request) (*childorders.Response, *http.Response, error)
func (*Client) Collateral ¶
func (c *Client) Collateral(req *collateral.Request) (*collateral.Response, *http.Response, error)
func (*Client) CollateralAccounts ¶
func (*Client) Executions ¶
func (c *Client) Executions(req *executions.Request) (*executions.Response, *http.Response, error)
func (*Client) ExecutionsMe ¶
func (*Client) OrderSingle ¶
func (*Client) Permissions ¶
func (c *Client) Permissions(req *permissions.Request) (*permissions.Response, *http.Response, error)
# Private APIs
Permissions
type ClientOpts ¶
type ClientOpts struct {
AuthConfig *auth.AuthConfig
}
type Limit ¶
type Limit struct { Period int // Period is リセットまでの秒数 PeriodForOrder int // Period is リセットまでの秒数 Remain int // Remain is 残Requests RemainForOrder int // Remain is 残Requests Reset time.Time // Reset Remainの詳細時間(sec未満なし) ResetForOrder time.Time // Reset Remainの詳細時間(sec未満なし) }
Limit is API Limit, ForOrder is Order(child/parent), CancelAll
func (*Limit) CheckForOrder ¶
CheckForOrder is check API limit for Order method
Click to show internal directories.
Click to hide internal directories.