(self, info: dict, market: Market = None)
| 9058 | return self.parse_long_short_ratio_history(data, market) |
| 9059 | |
| 9060 | def parse_long_short_ratio(self, info: dict, market: Market = None) -> LongShortRatio: |
| 9061 | # |
| 9062 | # { |
| 9063 | # "symbol": "BTCUSDT", |
| 9064 | # "buyRatio": "0.5707", |
| 9065 | # "sellRatio": "0.4293", |
| 9066 | # "timestamp": "1729123200000" |
| 9067 | # } |
| 9068 | # |
| 9069 | marketId = self.safe_string(info, 'symbol') |
| 9070 | timestamp = self.safe_integer_omit_zero(info, 'timestamp') |
| 9071 | longString = self.safe_string(info, 'buyRatio') |
| 9072 | shortString = self.safe_string(info, 'sellRatio') |
| 9073 | return { |
| 9074 | 'info': info, |
| 9075 | 'symbol': self.safe_symbol(marketId, market, None, 'contract'), |
| 9076 | 'timestamp': timestamp, |
| 9077 | 'datetime': self.iso8601(timestamp), |
| 9078 | 'timeframe': None, |
| 9079 | 'longShortRatio': self.parse_to_numeric(Precise.string_div(longString, shortString)), |
| 9080 | } |
| 9081 | |
| 9082 | def fetch_positions_adl_rank(self, symbols: Strings = None, params={}) -> List[ADL]: |
| 9083 | """ |
nothing calls this directly
no test coverage detected