MCPcopy Create free account
hub / github.com/ccxt/ccxt / parse_order_status

Method parse_order_status

python/ccxt/async_support/bybit.py:3658–3684  ·  view source on GitHub ↗
(self, status: Str)

Source from the content-addressed store, hash-verified

3656 return self.parse_balance(response)
3657
3658 def parse_order_status(self, status: Str):
3659 statuses = {
3660 # v3 spot
3661 'NEW': 'open',
3662 'PARTIALLY_FILLED': 'open',
3663 'FILLED': 'closed',
3664 'CANCELED': 'canceled',
3665 'PENDING_CANCEL': 'open',
3666 'PENDING_NEW': 'open',
3667 'REJECTED': 'rejected',
3668 'PARTIALLY_FILLED_CANCELLED': 'closed', # context: https://github.com/ccxt/ccxt/issues/18685
3669 # v3 contract / unified margin / unified account
3670 'Created': 'open',
3671 'New': 'open',
3672 'Rejected': 'rejected', # order is triggered but failed upon being placed
3673 'PartiallyFilled': 'open',
3674 'PartiallyFilledCanceled': 'closed', # context: https://github.com/ccxt/ccxt/issues/18685
3675 'Filled': 'closed',
3676 'PendingCancel': 'open',
3677 'Cancelled': 'canceled',
3678 # below self line the status only pertains to conditional orders
3679 'Untriggered': 'open',
3680 'Deactivated': 'canceled',
3681 'Triggered': 'open',
3682 'Active': 'open',
3683 }
3684 return self.safe_string(statuses, status, status)
3685
3686 def parse_time_in_force(self, timeInForce: Str):
3687 timeInForces = {

Callers 1

parse_orderMethod · 0.95

Calls 1

safe_stringMethod · 0.80

Tested by

no test coverage detected