public

package
v2.0.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2019 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthRequest

type AuthRequest struct {
	ClientID     string `json:"client_id" mapstructure:"client_id"`
	ClientSecret string `json:"client_secret" mapstructure:"client_secret"`
	GrantType    string `json:"grant_type" mapstructure:"grant_type"`
}

type AuthResponse

type AuthResponse struct {
	AccessToken  string `json:"access_token" mapstructure:"access_token"`
	ExpiresIn    int64  `json:"expires_in" mapstructure:"expires_in"`
	RefreshToken string `json:"refresh_token" mapstructure:"refresh_token"`
	Scope        string `json:"scope" mapstructure:"scope"`
	TokenType    string `json:"token_type" mapstructure:"token_type"`
}

type DisableHeartbeatRequest

type DisableHeartbeatRequest struct{}

type DisableHeartbeatResponse

type DisableHeartbeatResponse string

type GetAnnouncementsRequest

type GetAnnouncementsRequest struct{}

type GetAnnouncementsResponse

type GetAnnouncementsResponse []struct {
	Body            string `json:"body" mapstructure:"body"`
	ID              int64  `json:"id" mapstructure:"id"`
	Important       bool   `json:"important" mapstructure:"important"`
	PublicationTime int64  `json:"publication_time" mapstructure:"publication_time"`
	Title           string `json:"title" mapstructure:"title"`
}

type GetBookSummaryByCurrencyRequest

type GetBookSummaryByCurrencyRequest struct {
	Currency string `json:"currency" mapstructure:"currency"`
	Kind     string `json:"kind" mapstructure:"kind"`
}

type GetBookSummaryByCurrencyResponse

type GetBookSummaryByCurrencyResponse []struct {
	AskPrice               interface{} `json:"ask_price" mapstructure:"ask_price"`
	BaseCurrency           string      `json:"base_currency" mapstructure:"base_currency"`
	BidPrice               interface{} `json:"bid_price" mapstructure:"bid_price"`
	CreationTimestamp      int64       `json:"creation_timestamp" mapstructure:"creation_timestamp"`
	CurrentFunding         int64       `json:"current_funding" mapstructure:"current_funding"`
	EstimatedDeliveryPrice float64     `json:"estimated_delivery_price" mapstructure:"estimated_delivery_price"`
	Funding8h              float64     `json:"funding_8h" mapstructure:"funding_8h"`
	High                   int64       `json:"high" mapstructure:"high"`
	InstrumentName         string      `json:"instrument_name" mapstructure:"instrument_name"`
	Last                   int64       `json:"last" mapstructure:"last"`
	Low                    int64       `json:"low" mapstructure:"low"`
	MarkPrice              float64     `json:"mark_price" mapstructure:"mark_price"`
	MidPrice               interface{} `json:"mid_price" mapstructure:"mid_price"`
	OpenInterest           int64       `json:"open_interest" mapstructure:"open_interest"`
	QuoteCurrency          string      `json:"quote_currency" mapstructure:"quote_currency"`
	Volume                 int64       `json:"volume" mapstructure:"volume"`
	VolumeUsd              int64       `json:"volume_usd" mapstructure:"volume_usd"`
}

type GetBookSummaryByInstrumentRequest

type GetBookSummaryByInstrumentRequest struct {
	InstrumentName string `json:"instrument_name" mapstructure:"instrument_name"`
}

type GetBookSummaryByInstrumentResponse

type GetBookSummaryByInstrumentResponse []struct {
	AskPrice          float64 `json:"ask_price" mapstructure:"ask_price"`
	BaseCurrency      string  `json:"base_currency" mapstructure:"base_currency"`
	BidPrice          float64 `json:"bid_price" mapstructure:"bid_price"`
	CreationTimestamp int64   `json:"creation_timestamp" mapstructure:"creation_timestamp"`
	High              float64 `json:"high" mapstructure:"high"`
	InstrumentName    string  `json:"instrument_name" mapstructure:"instrument_name"`
	InterestRate      float64 `json:"interest_rate" mapstructure:"interest_rate"`
	Last              float64 `json:"last" mapstructure:"last"`
	Low               float64 `json:"low" mapstructure:"low"`
	MarkPrice         float64 `json:"mark_price" mapstructure:"mark_price"`
	MidPrice          float64 `json:"mid_price" mapstructure:"mid_price"`
	OpenInterest      float64 `json:"open_interest" mapstructure:"open_interest"`
	QuoteCurrency     string  `json:"quote_currency" mapstructure:"quote_currency"`
	UnderlyingIndex   string  `json:"underlying_index" mapstructure:"underlying_index"`
	UnderlyingPrice   float64 `json:"underlying_price" mapstructure:"underlying_price"`
	Volume            float64 `json:"volume" mapstructure:"volume"`
}

type GetCurrenciesRequest

type GetCurrenciesRequest struct{}

type GetCurrenciesResponse

type GetCurrenciesResponse []struct {
	CoinType                       string  `json:"coin_type" mapstructure:"coin_type"`
	Currency                       string  `json:"currency" mapstructure:"currency"`
	CurrencyLong                   string  `json:"currency_long" mapstructure:"currency_long"`
	DisabledDepositAddressCreation bool    `json:"disabled_deposit_address_creation" mapstructure:"disabled_deposit_address_creation"`
	FeePrecision                   int64   `json:"fee_precision" mapstructure:"fee_precision"`
	MinConfirmations               int64   `json:"min_confirmations" mapstructure:"min_confirmations"`
	MinWithdrawalFee               float64 `json:"min_withdrawal_fee" mapstructure:"min_withdrawal_fee"`
	WithdrawalFee                  float64 `json:"withdrawal_fee" mapstructure:"withdrawal_fee"`
	WithdrawalPriorities           []struct {
		Name  string  `json:"name" mapstructure:"name"`
		Value float64 `json:"value" mapstructure:"value"`
	} `json:"withdrawal_priorities" mapstructure:"withdrawal_priorities"`
}

type GetHistoricalVolatilityRequest

type GetHistoricalVolatilityRequest struct {
	Currency string `json:"currency" mapstructure:"currency"`
}

type GetHistoricalVolatilityResponse

type GetHistoricalVolatilityResponse [][]int64

type GetInstrumentsRequest

type GetInstrumentsRequest struct {
	Currency string `json:"currency" mapstructure:"currency"`
	Expired  bool   `json:"expired" mapstructure:"expired"`
	Kind     string `json:"kind" mapstructure:"kind"`
}

type GetInstrumentsResponse

type GetInstrumentsResponse []struct {
	BaseCurrency        string  `json:"base_currency" mapstructure:"base_currency"`
	ContractSize        int64   `json:"contract_size" mapstructure:"contract_size"`
	CreationTimestamp   int64   `json:"creation_timestamp" mapstructure:"creation_timestamp"`
	ExpirationTimestamp int64   `json:"expiration_timestamp" mapstructure:"expiration_timestamp"`
	InstrumentName      string  `json:"instrument_name" mapstructure:"instrument_name"`
	IsActive            bool    `json:"is_active" mapstructure:"is_active"`
	Kind                string  `json:"kind" mapstructure:"kind"`
	MinTradeAmount      int64   `json:"min_trade_amount" mapstructure:"min_trade_amount"`
	QuoteCurrency       string  `json:"quote_currency" mapstructure:"quote_currency"`
	SettlementPeriod    string  `json:"settlement_period" mapstructure:"settlement_period"`
	TickSize            float64 `json:"tick_size" mapstructure:"tick_size"`
}

type GetLastSettlementsByCurrencyRequest

type GetLastSettlementsByCurrencyRequest struct {
	Count    int64  `json:"count" mapstructure:"count"`
	Currency string `json:"currency" mapstructure:"currency"`
	Type     string `json:"type" mapstructure:"type"`
}

type GetLastSettlementsByCurrencyResponse

type GetLastSettlementsByCurrencyResponse struct {
	Continuation string `json:"continuation" mapstructure:"continuation"`
	Settlements  []struct {
		IndexPrice        float64 `json:"index_price" mapstructure:"index_price"`
		InstrumentName    string  `json:"instrument_name" mapstructure:"instrument_name"`
		MarkPrice         float64 `json:"mark_price" mapstructure:"mark_price"`
		Position          int64   `json:"position" mapstructure:"position"`
		ProfitLoss        float64 `json:"profit_loss" mapstructure:"profit_loss"`
		SessionProfitLoss float64 `json:"session_profit_loss" mapstructure:"session_profit_loss"`
		Timestamp         int64   `json:"timestamp" mapstructure:"timestamp"`
		Type              string  `json:"type" mapstructure:"type"`
	} `json:"settlements" mapstructure:"settlements"`
}

type GetLastSettlementsByInstrumentRequest

type GetLastSettlementsByInstrumentRequest struct {
	Count          int64  `json:"count" mapstructure:"count"`
	InstrumentName string `json:"instrument_name" mapstructure:"instrument_name"`
	Type           string `json:"type" mapstructure:"type"`
}

type GetLastSettlementsByInstrumentResponse

type GetLastSettlementsByInstrumentResponse struct {
	Continuation string `json:"continuation" mapstructure:"continuation"`
	Settlements  []struct {
		IndexPrice        float64 `json:"index_price" mapstructure:"index_price"`
		InstrumentName    string  `json:"instrument_name" mapstructure:"instrument_name"`
		MarkPrice         float64 `json:"mark_price" mapstructure:"mark_price"`
		Position          int64   `json:"position" mapstructure:"position"`
		ProfitLoss        int64   `json:"profit_loss" mapstructure:"profit_loss"`
		SessionProfitLoss float64 `json:"session_profit_loss" mapstructure:"session_profit_loss"`
		Timestamp         int64   `json:"timestamp" mapstructure:"timestamp"`
		Type              string  `json:"type" mapstructure:"type"`
	} `json:"settlements" mapstructure:"settlements"`
}

type GetLastTradesByCurrencyAndTimeRequest

type GetLastTradesByCurrencyAndTimeRequest struct {
	Count          int64  `json:"count" mapstructure:"count"`
	Currency       string `json:"currency" mapstructure:"currency"`
	EndTimestamp   int64  `json:"end_timestamp" mapstructure:"end_timestamp"`
	StartTimestamp int64  `json:"start_timestamp" mapstructure:"start_timestamp"`
}

type GetLastTradesByCurrencyAndTimeResponse

type GetLastTradesByCurrencyAndTimeResponse struct {
	HasMore bool `json:"has_more" mapstructure:"has_more"`
	Trades  []struct {
		Amount         int64   `json:"amount" mapstructure:"amount"`
		Direction      string  `json:"direction" mapstructure:"direction"`
		IndexPrice     float64 `json:"index_price" mapstructure:"index_price"`
		InstrumentName string  `json:"instrument_name" mapstructure:"instrument_name"`
		Iv             float64 `json:"iv" mapstructure:"iv"`
		Price          float64 `json:"price" mapstructure:"price"`
		TickDirection  int64   `json:"tick_direction" mapstructure:"tick_direction"`
		Timestamp      int64   `json:"timestamp" mapstructure:"timestamp"`
		TradeID        string  `json:"trade_id" mapstructure:"trade_id"`
		TradeSeq       int64   `json:"trade_seq" mapstructure:"trade_seq"`
	} `json:"trades" mapstructure:"trades"`
}

type GetLastTradesByCurrencyRequest

type GetLastTradesByCurrencyRequest struct {
	Count    int64  `json:"count" mapstructure:"count"`
	Currency string `json:"currency" mapstructure:"currency"`
}

type GetLastTradesByCurrencyResponse

type GetLastTradesByCurrencyResponse struct {
	HasMore bool `json:"has_more" mapstructure:"has_more"`
	Trades  []struct {
		Amount         int64   `json:"amount" mapstructure:"amount"`
		Direction      string  `json:"direction" mapstructure:"direction"`
		IndexPrice     float64 `json:"index_price" mapstructure:"index_price"`
		InstrumentName string  `json:"instrument_name" mapstructure:"instrument_name"`
		Iv             float64 `json:"iv" mapstructure:"iv"`
		Price          float64 `json:"price" mapstructure:"price"`
		TickDirection  int64   `json:"tick_direction" mapstructure:"tick_direction"`
		Timestamp      int64   `json:"timestamp" mapstructure:"timestamp"`
		TradeID        string  `json:"trade_id" mapstructure:"trade_id"`
		TradeSeq       int64   `json:"trade_seq" mapstructure:"trade_seq"`
	} `json:"trades" mapstructure:"trades"`
}

type GetLastTradesByInstrumentAndTimeRequest

type GetLastTradesByInstrumentAndTimeRequest struct {
	Count          int64  `json:"count" mapstructure:"count"`
	EndTimestamp   int64  `json:"end_timestamp" mapstructure:"end_timestamp"`
	InstrumentName string `json:"instrument_name" mapstructure:"instrument_name"`
}

type GetLastTradesByInstrumentAndTimeResponse

type GetLastTradesByInstrumentAndTimeResponse struct {
	HasMore bool `json:"has_more" mapstructure:"has_more"`
	Trades  []struct {
		Amount         int64   `json:"amount" mapstructure:"amount"`
		Direction      string  `json:"direction" mapstructure:"direction"`
		IndexPrice     float64 `json:"index_price" mapstructure:"index_price"`
		InstrumentName string  `json:"instrument_name" mapstructure:"instrument_name"`
		Price          float64 `json:"price" mapstructure:"price"`
		TickDirection  int64   `json:"tick_direction" mapstructure:"tick_direction"`
		Timestamp      int64   `json:"timestamp" mapstructure:"timestamp"`
		TradeID        string  `json:"trade_id" mapstructure:"trade_id"`
		TradeSeq       int64   `json:"trade_seq" mapstructure:"trade_seq"`
	} `json:"trades" mapstructure:"trades"`
}

type GetLastTradesByInstrumentRequest

type GetLastTradesByInstrumentRequest struct {
	Count          int64  `json:"count" mapstructure:"count"`
	InstrumentName string `json:"instrument_name" mapstructure:"instrument_name"`
}

type GetLastTradesByInstrumentResponse

type GetLastTradesByInstrumentResponse struct {
	HasMore bool `json:"has_more" mapstructure:"has_more"`
	Trades  []struct {
		Amount         int64   `json:"amount" mapstructure:"amount"`
		Direction      string  `json:"direction" mapstructure:"direction"`
		IndexPrice     float64 `json:"index_price" mapstructure:"index_price"`
		InstrumentName string  `json:"instrument_name" mapstructure:"instrument_name"`
		Price          int64   `json:"price" mapstructure:"price"`
		TickDirection  int64   `json:"tick_direction" mapstructure:"tick_direction"`
		Timestamp      int64   `json:"timestamp" mapstructure:"timestamp"`
		TradeID        string  `json:"trade_id" mapstructure:"trade_id"`
		TradeSeq       int64   `json:"trade_seq" mapstructure:"trade_seq"`
	} `json:"trades" mapstructure:"trades"`
}

type GetOptionMarkPricesRequest

type GetOptionMarkPricesRequest struct {
	Currency string `json:"currency" mapstructure:"currency"`
}

type GetOptionMarkPricesResponse

type GetOptionMarkPricesResponse struct {
	ETH_22FEB19_120_C []float64 `json:"ETH-22FEB19-120-C" mapstructure:"ETH-22FEB19-120-C"`
	ETH_22FEB19_120_P []float64 `json:"ETH-22FEB19-120-P" mapstructure:"ETH-22FEB19-120-P"`
	ETH_22FEB19_140_C []float64 `json:"ETH-22FEB19-140-C" mapstructure:"ETH-22FEB19-140-C"`
	ETH_22FEB19_140_P []float64 `json:"ETH-22FEB19-140-P" mapstructure:"ETH-22FEB19-140-P"`
}

type GetOrderBookRequest

type GetOrderBookRequest struct {
	Depth          int64  `json:"depth" mapstructure:"depth"`
	InstrumentName string `json:"instrument_name" mapstructure:"instrument_name"`
}

type GetOrderBookResponse

type GetOrderBookResponse struct {
	Asks            []interface{} `json:"asks" mapstructure:"asks"`
	BestAskAmount   int64         `json:"best_ask_amount" mapstructure:"best_ask_amount"`
	BestAskPrice    int64         `json:"best_ask_price" mapstructure:"best_ask_price"`
	BestBidAmount   int64         `json:"best_bid_amount" mapstructure:"best_bid_amount"`
	BestBidPrice    float64       `json:"best_bid_price" mapstructure:"best_bid_price"`
	Bids            [][]float64   `json:"bids" mapstructure:"bids"`
	ChangeID        int64         `json:"change_id" mapstructure:"change_id"`
	CurrentFunding  float64       `json:"current_funding" mapstructure:"current_funding"`
	Funding8h       float64       `json:"funding_8h" mapstructure:"funding_8h"`
	IndexPrice      float64       `json:"index_price" mapstructure:"index_price"`
	InstrumentName  string        `json:"instrument_name" mapstructure:"instrument_name"`
	LastPrice       float64       `json:"last_price" mapstructure:"last_price"`
	MarkPrice       float64       `json:"mark_price" mapstructure:"mark_price"`
	MaxPrice        float64       `json:"max_price" mapstructure:"max_price"`
	MinPrice        float64       `json:"min_price" mapstructure:"min_price"`
	OpenInterest    float64       `json:"open_interest" mapstructure:"open_interest"`
	SettlementPrice float64       `json:"settlement_price" mapstructure:"settlement_price"`
	State           string        `json:"state" mapstructure:"state"`
	Stats           struct {
		High   float64 `json:"high" mapstructure:"high"`
		Low    float64 `json:"low" mapstructure:"low"`
		Volume float64 `json:"volume" mapstructure:"volume"`
	} `json:"stats" mapstructure:"stats"`
	Timestamp int64 `json:"timestamp" mapstructure:"timestamp"`
}

type GetTimeRequest

type GetTimeRequest struct{}

type GetTimeResponse

type GetTimeResponse string

type GetTradeVolumesRequest

type GetTradeVolumesRequest string

type GetTradeVolumesResponse

type GetTradeVolumesResponse []struct {
	CallsVolume   int64   `json:"calls_volume" mapstructure:"calls_volume"`
	CurrencyPair  string  `json:"currency_pair" mapstructure:"currency_pair"`
	FuturesVolume float64 `json:"futures_volume" mapstructure:"futures_volume"`
	PutsVolume    int64   `json:"puts_volume" mapstructure:"puts_volume"`
}

type HelloRequest

type HelloRequest struct {
	ClientName    string `json:"client_name" mapstructure:"client_name"`
	ClientVersion string `json:"client_version" mapstructure:"client_version"`
}

type HelloResponse

type HelloResponse struct {
	Version string `json:"version" mapstructure:"version"`
}

type SetHeartbeatRequest

type SetHeartbeatRequest struct {
	Interval int64 `json:"interval" mapstructure:"interval"`
}

type SetHeartbeatResponse

type SetHeartbeatResponse string

type SubscribeRequest

type SubscribeRequest struct {
	Channels []string `json:"channels" mapstructure:"channels"`
}

type SubscribeResponse

type SubscribeResponse []string

type TestRequest

type TestRequest struct{}

type TestResponse

type TestResponse struct {
	Version string `json:"version" mapstructure:"version"`
}

type TickerRequest

type TickerRequest struct {
	InstrumentName string `json:"instrument_name" mapstructure:"instrument_name"`
}

type TickerResponse

type TickerResponse struct {
	BestAskAmount   int64   `json:"best_ask_amount" mapstructure:"best_ask_amount"`
	BestAskPrice    float64 `json:"best_ask_price" mapstructure:"best_ask_price"`
	BestBidAmount   int64   `json:"best_bid_amount" mapstructure:"best_bid_amount"`
	BestBidPrice    float64 `json:"best_bid_price" mapstructure:"best_bid_price"`
	CurrentFunding  int64   `json:"current_funding" mapstructure:"current_funding"`
	Funding8h       float64 `json:"funding_8h" mapstructure:"funding_8h"`
	IndexPrice      float64 `json:"index_price" mapstructure:"index_price"`
	InstrumentName  string  `json:"instrument_name" mapstructure:"instrument_name"`
	LastPrice       float64 `json:"last_price" mapstructure:"last_price"`
	MarkPrice       float64 `json:"mark_price" mapstructure:"mark_price"`
	MaxPrice        float64 `json:"max_price" mapstructure:"max_price"`
	MinPrice        float64 `json:"min_price" mapstructure:"min_price"`
	OpenInterest    float64 `json:"open_interest" mapstructure:"open_interest"`
	SettlementPrice float64 `json:"settlement_price" mapstructure:"settlement_price"`
	State           string  `json:"state" mapstructure:"state"`
	Stats           struct {
		High   float64 `json:"high" mapstructure:"high"`
		Low    int64   `json:"low" mapstructure:"low"`
		Volume float64 `json:"volume" mapstructure:"volume"`
	} `json:"stats" mapstructure:"stats"`
	Timestamp int64 `json:"timestamp" mapstructure:"timestamp"`
}

type UnsubscribeRequest

type UnsubscribeRequest struct {
	Channels []string `json:"channels" mapstructure:"channels"`
}

type UnsubscribeResponse

type UnsubscribeResponse []string

Source Files

Jump to

Keyboard shortcuts

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