Skip to content

Commit

Permalink
add func: bnc.User.CloseFuturesOrder
Browse files Browse the repository at this point in the history
  • Loading branch information
dwdwow committed Mar 6, 2024
1 parent cf3d298 commit 7d05ffa
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bnc/user.go
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,10 @@ func (u *User) QueryFuturesOrder(symbol string, orderId int64, cltOrdId string,
return cex.Request(u, FuturesQueryOrderConfig, FuturesQueryOrCancelOrderParams{Symbol: symbol, OrderId: orderId, OrigClientOrderId: cltOrdId}, opts...)
}

func (u *User) CloseFuturesOrder(symbol string, opts ...cex.CltOpt) (*resty.Response, FuturesOrder, cex.RequestError) {
return cex.Request(u, FuturesNewOrderConfig, FuturesNewOrderParams{Symbol: symbol, PositionSide: u.cfg.fuPosSide, ClosePosition: true}, opts...)
}

// ------------------------------------------------------------
// Futures API
// ============================================================
Expand Down

0 comments on commit 7d05ffa

Please sign in to comment.