Skip to content

Commit 5905362

Browse files
authored
fix some problems: (#590)
* fix some problems:1.fix the path of asset_index_service.go and constituents_service.go. 2.fix struct DeliveryPrice. 3.remove redundant funding_rate_history.go * remove responding interface in client.go
1 parent 91b5816 commit 5905362

6 files changed

+4
-150
lines changed

v2/futures/asset_index_service.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ func (s *AssetIndexService) Symbol(symbol string) *AssetIndexService {
3333
func (s *AssetIndexService) Do(ctx context.Context, opts ...RequestOption) (res []*AssetIndex, err error) {
3434
r := &request{
3535
method: http.MethodGet,
36-
endpoint: "/futures/v1/assetIndex",
36+
endpoint: "/fapi/v1/assetIndex",
3737
}
3838
if s.symbol != nil {
3939
r.setParam("symbol", *s.symbol)

v2/futures/client.go

-5
Original file line numberDiff line numberDiff line change
@@ -556,11 +556,6 @@ func (c *Client) NewFundingRateService() *FundingRateService {
556556
return &FundingRateService{c: c}
557557
}
558558

559-
// NewFundingRateHistoryService init funding rate history service
560-
func (c *Client) NewFundingRateHistoryService() *FundingRateHistoryService {
561-
return &FundingRateHistoryService{c: c}
562-
}
563-
564559
// NewFundingRateInfoService init funding rate info service
565560
func (c *Client) NewFundingRateInfoService() *FundingRateInfoService {
566561
return &FundingRateInfoService{c: c}

v2/futures/constituents_service.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ func (s *ConstituentsService) Symbol(symbol string) *ConstituentsService {
3030
func (s *ConstituentsService) Do(ctx context.Context, opts ...RequestOption) (res *ConstituentsServiceRsp, err error) {
3131
r := &request{
3232
method: http.MethodGet,
33-
endpoint: "/futures/v1/assetIndex",
33+
endpoint: "/fapi/v1/constituents",
3434
}
3535
r.setParam("symbol", s.symbol)
3636

v2/futures/data_service.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ type DeliveryPriceService struct {
1212
}
1313

1414
type DeliveryPrice struct {
15-
DeliveryTime uint64 `json:"DeliveryTime"` // deliveryTime
16-
DeliveryPrice float64 `json:"DeliveryPrice"` // deliveryPrice
15+
DeliveryTime uint64 `json:"deliveryTime"` // deliveryTime
16+
DeliveryPrice float64 `json:"deliveryPrice"` // deliveryPrice
1717
}
1818

1919
func (s *DeliveryPriceService) Pair(pair string) *DeliveryPriceService {

v2/futures/funding_rate_history.go

-82
This file was deleted.

v2/futures/funding_rate_history_test.go

-59
This file was deleted.

0 commit comments

Comments
 (0)