forked from blankly-finance/blankly
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add functionality to binance futures exchange
- Loading branch information
1 parent
7197194
commit 59de43f
Showing
17 changed files
with
499 additions
and
183 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
import enum | ||
|
||
|
||
class MarginType(str, enum.Enum): | ||
CROSSED = 'crossed' | ||
ISOLATED = 'isolated' | ||
|
||
|
||
class Side(str, enum.Enum): | ||
BUY = 'buy' | ||
SELL = 'sell' | ||
|
||
|
||
class PositionMode(str, enum.Enum): | ||
BOTH = 'both' | ||
LONG = 'long' | ||
SHORT = 'short' | ||
|
||
|
||
class TimeInForce(str, enum.Enum): | ||
GTC = 'GTC' # Good Till Cancelled | ||
FOK = 'FOK' # Fill or Kill | ||
IOC = 'IOC' # Immediate or Cancel | ||
|
||
|
||
class HedgeMode(str, enum.Enum): | ||
HEDGE = 'hedge' | ||
ONEWAY = 'oneway' | ||
|
||
|
||
class OrderStatus(str, enum.Enum): | ||
NEW = 'new' | ||
PARTIALLY_FILLED = 'partially_filled' | ||
FILLED = 'filled' | ||
CANCELED = 'canceled' | ||
EXPIRED = 'expired' | ||
|
||
|
||
class OrderType(str, enum.Enum): | ||
MARKET = 'market' | ||
LIMIT = 'limit' | ||
STOP = 'stop' | ||
TAKE_PROFIT = 'take_profit' | ||
LIQUIDATION = 'liquidation' | ||
|
||
|
||
class ContractType(str, enum.Enum): | ||
PERPETUAL = 'perpetual' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.