FreqtradeClient#

API documentation for tradeexecutor.strategy.freqtrade.freqtrade_client.FreqtradeClient Python class in Trading Strategy framework.

class FreqtradeClient[source]#

Bases: object

__init__(api_url, api_username, api_password, timeout=5.0)[source]#
Parameters:
  • api_url (str) –

  • api_username (str) –

  • api_password (str) –

  • timeout (float) –

Methods

__init__(api_url, api_username, api_password)

get_balance()

Query /api/v1/balance endpoint.

get_performance()

Query /api/v1/performance for trade performance.

get_status()

Query /api/v1/status for bot and trade status.

__init__(api_url, api_username, api_password, timeout=5.0)[source]#
Parameters:
  • api_url (str) –

  • api_username (str) –

  • api_password (str) –

  • timeout (float) –

get_balance()[source]#

Query /api/v1/balance endpoint.

Returns:

Dict with keys: total, free, used (amounts in reserve currency)

Raises:

requests.RequestException: If API call fails

Return type:

dict

get_status()[source]#

Query /api/v1/status for bot and trade status.

Returns:

Dict with current bot status and open trades

Raises:

requests.RequestException: If API call fails

Return type:

dict

get_performance()[source]#

Query /api/v1/performance for trade performance.

Returns:

Dict with per-pair trade performance metrics

Raises:

requests.RequestException: If API call fails

Return type:

dict