Add quote currency to entry/exit msgs

This commit is contained in:
Matthias 2024-01-06 13:11:45 +01:00
parent 079330ac64
commit 20b2f25067
2 changed files with 5 additions and 0 deletions

View File

@ -1022,6 +1022,7 @@ class FreqtradeBot(LoggingMixin):
'stake_amount': trade.stake_amount,
'stake_currency': self.config['stake_currency'],
'base_currency': self.exchange.get_pair_base_currency(trade.pair),
'quote_currency': self.exchange.get_pair_quote_currency(trade.pair),
'fiat_currency': self.config.get('fiat_display_currency', None),
'amount': order.safe_amount_after_fee if fill else (order.amount or trade.amount),
'open_date': trade.open_date_utc or datetime.now(timezone.utc),
@ -1055,6 +1056,7 @@ class FreqtradeBot(LoggingMixin):
'open_rate': trade.open_rate,
'stake_currency': self.config['stake_currency'],
'base_currency': self.exchange.get_pair_base_currency(trade.pair),
'quote_currency': self.exchange.get_pair_quote_currency(trade.pair),
'fiat_currency': self.config.get('fiat_display_currency', None),
'amount': trade.amount,
'open_date': trade.open_date,
@ -1814,6 +1816,7 @@ class FreqtradeBot(LoggingMixin):
'stake_amount': trade.stake_amount,
'stake_currency': self.config['stake_currency'],
'base_currency': self.exchange.get_pair_base_currency(trade.pair),
'quote_currency': self.exchange.get_pair_quote_currency(trade.pair),
'fiat_currency': self.config.get('fiat_display_currency'),
'sub_trade': sub_trade,
'cumulative_profit': trade.realized_profit,
@ -1865,6 +1868,7 @@ class FreqtradeBot(LoggingMixin):
'close_date': trade.close_date or datetime.now(timezone.utc),
'stake_currency': self.config['stake_currency'],
'base_currency': self.exchange.get_pair_base_currency(trade.pair),
'quote_currency': self.exchange.get_pair_quote_currency(trade.pair),
'fiat_currency': self.config.get('fiat_display_currency', None),
'reason': reason,
'sub_trade': sub_trade,

View File

@ -51,6 +51,7 @@ class __RPCEntryExitMsgBase(RPCSendMsgBase):
exchange: str
pair: str
base_currency: str
quote_currency: str
leverage: Optional[float]
direction: str
limit: float