mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-25 16:25:16 +00:00
maxapi: replace client field type with interface
This commit is contained in:
parent
c5e93dba00
commit
6f35aa0f20
|
@ -11,7 +11,7 @@ import (
|
|||
)
|
||||
|
||||
type AccountService struct {
|
||||
client *RestClient
|
||||
client requestgen.AuthenticatedAPIClient
|
||||
}
|
||||
|
||||
// Account is for max rest api v2, Balance and Type will be conflict with types.PrivateBalanceUpdate
|
||||
|
|
|
@ -4,6 +4,8 @@ package max
|
|||
//go:generate -command PostRequest requestgen -method POST
|
||||
|
||||
import (
|
||||
"github.com/c9s/requestgen"
|
||||
|
||||
"github.com/c9s/bbgo/pkg/fixedpoint"
|
||||
"github.com/c9s/bbgo/pkg/types"
|
||||
)
|
||||
|
@ -57,7 +59,7 @@ type QueryOrderOptions struct {
|
|||
|
||||
// OrderService manages the Order endpoint.
|
||||
type OrderService struct {
|
||||
client *RestClient
|
||||
client requestgen.AuthenticatedAPIClient
|
||||
}
|
||||
|
||||
type SubmitOrder struct {
|
||||
|
|
|
@ -5,6 +5,8 @@ package v3
|
|||
//go:generate -command DeleteRequest requestgen -method DELETE
|
||||
|
||||
import (
|
||||
"github.com/c9s/requestgen"
|
||||
|
||||
maxapi "github.com/c9s/bbgo/pkg/exchange/max/maxapi"
|
||||
)
|
||||
|
||||
|
@ -18,5 +20,5 @@ type Account = maxapi.Account
|
|||
|
||||
// OrderService manages the Order endpoint.
|
||||
type OrderService struct {
|
||||
Client *maxapi.RestClient
|
||||
Client requestgen.AuthenticatedAPIClient
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user