Skip to content
Back to search

freqtrade-mcp

An MCP server that integrates with the Freqtrade cryptocurrency trading bot.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/kukapay--freqtrade-mcp/badge.svg)](/listings/kukapay--freqtrade-mcp)

HTML

<a href="/listings/kukapay--freqtrade-mcp"><img src="/api/listings/kukapay--freqtrade-mcp/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Prerequisites

- **Python 3.13+**: Ensure Python is installed on your system. - **Freqtrade**: A running Freqtrade instance with the REST API enabled (see [Freqtrade Docs](https://www.freqtrade.io/en/stable/rest-api/)). - **Git**: For cloning the repository.

Steps

1. **Clone the Repository**:

   git clone https://github.com/kukapay/freqtrade-mcp.git
   cd freqtrade-mcp

2. **Install Dependencies**: Using `pip`:

   pip install freqtrade-client mcp[cli]

Or with `uv` (optional):

   uv add freqtrade-client "mcp[cli]"

3. **Client Configuration**:

``` "mcpServers": { "freqtrade-mcp": { "command": "uv", "args": [ "--directory", "/your/path/to/freqtrade-mcp", "run", "__main__.py" ], "env": { "FREQTRADE_API_URL": "http://127.0.0.1:8080", "FREQTRADE_USERNAME": "your_username", "FREQTRADE_PASSWORD": "your_password" } } } ```

4. **Freqtrade Configuration**:

Enable the rest API by adding the api_server section to your configuration and setting api_server.enabled to true.

Sample configuration: ``` "api_server": { "enabled": true, "listen_ip_address": "127.0.0.1", "listen_port": 8080, "verbosity": "error", "enable_openapi": false, "jwt_secret_key": "somethingrandom", "CORS_origins": [], "username": "Freqtrader", "password": "SuperSecret1!", "ws_token": "sercet_Ws_t0ken" }, ```

Check the document [here](https://www.freqtrade.io/en/stable/rest-api/#configuration).

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 191 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. # Freqtrade-MCP
  2. An MCP server that integrates with the [Freqtrade](https://www.freqtrade.io/) cryptocurrency trading bot via its REST API, enabling seamless AI agent interaction for automated trading operation.
  3. For more crypto-related MCP servers, see the [Kukapay MCP servers](https://github.com/kukapay/kukapay-mcp-servers).
  4. ![GitHub License](https://img.shields.io/github/license/kukapay/freqtrade-mcp)
  5. ![Python Version](https://img.shields.io/badge/python-3.13+-blue)
  6. ![Status](https://img.shields.io/badge/status-active-brightgreen.svg)
  7. ## Installation
  8. ### Prerequisites
  9. - **Python 3.13+**: Ensure Python is installed on your system.
  10. - **Freqtrade**: A running Freqtrade instance with the REST API enabled (see [Freqtrade Docs](https://www.freqtrade.io/en/stable/rest-api/)).
  11. - **Git**: For cloning the repository.
  12. ### Steps
  13. 1. **Clone the Repository**:
  14. ```bash
  15. git clone https://github.com/kukapay/freqtrade-mcp.git
  16. cd freqtrade-mcp
  17. ```
  18. 2. **Install Dependencies**:
  19. Using `pip`:
  20. ```bash
  21. pip install freqtrade-client mcp[cli]
  22. ```
  23. Or with `uv` (optional):
  24. ```bash
  25. uv add freqtrade-client "mcp[cli]"
  26. ```
  27. 3. **Client Configuration**:
  28. ```
  29. "mcpServers": {
  30. "freqtrade-mcp": {
  31. "command": "uv",
  32. "args": [
  33. "--directory", "/your/path/to/freqtrade-mcp",
  34. "run",
  35. "__main__.py"
  36. ],
  37. "env": {
  38. "FREQTRADE_API_URL": "http://127.0.0.1:8080",
  39. "FREQTRADE_USERNAME": "your_username",
  40. "FREQTRADE_PASSWORD": "your_password"
  41. }
  42. }
  43. }
  44. ```
  45. 4. **Freqtrade Configuration**:
  46. Enable the rest API by adding the api_server section to your configuration and setting api_server.enabled to true.
  47. Sample configuration:
  48. ```
  49. "api_server": {
  50. "enabled": true,
  51. "listen_ip_address": "127.0.0.1",
  52. "listen_port": 8080,
  53. "verbosity": "error",
  54. "enable_openapi": false,
  55. "jwt_secret_key": "somethingrandom",
  56. "CORS_origins": [],
  57. "username": "Freqtrader",
  58. "password": "SuperSecret1!",
  59. "ws_token": "sercet_Ws_t0ken"
  60. },
  61. ```
  62. Check the document [here](https://www.freqtrade.io/en/stable/rest-api/#configuration).
  63. ## Usage
  64. ### Available Tools
  65. The server exposes the following Freqtrade API endpoints as MCP tools:
  66. | Tool | Description | Parameters |
  67. |-----------------------|--------------------------------------|-------------------------------------|
  68. | `fetch_market_data` | Fetch OHLCV data for a pair | `pair: str`, `timeframe: str` |
  69. | `fetch_bot_status` | Get open trade status | None |
  70. | `fetch_profit` | Get profit summary | None |
  71. | `fetch_balance` | Get account balance | None |
  72. | `fetch_performance` | Get performance metrics | None |
  73. | `fetch_whitelist` | Get whitelist of pairs | None |
  74. | `fetch_blacklist` | Get blacklist of pairs | None |
  75. | `fetch_trades` | Get trade history | None |
  76. | `fetch_config` | Get bot configuration | None |
  77. | `fetch_locks` | Get trade locks | None |
  78. | `place_trade` | Place a buy/sell trade | `pair: str`, `side: str`, `stake_amount: float` |
  79. | `start_bot` | Start the bot | None |
  80. | `stop_bot` | Stop the bot | None |
  81. | `reload_config` | Reload bot configuration | None |
  82. | `add_blacklist` | Add pair to blacklist | `pair: str` |
  83. | `delete_blacklist` | Remove pair from blacklist | `pair: str` |
  84. | `delete_lock` | Delete a trade lock | `lock_id: int` |
  85. ### Example Prompts
  86. 1. **Fetch Market Data**:
  87. - "Show me the hourly price data for BTC/USDT."
  88. - "What’s the 5-minute chart for ETH/BTC like?"
  89. - "Give me the latest candlestick data for XRP/USDT over the past hour."
  90. 2. **Fetch Bot Status**:
  91. - "What’s the current status of my open trades?"
  92. - "Are there any active trades right now?"
  93. - "Tell me about the bot’s trading activity at the moment."
  94. 3. **Fetch Profit**:
  95. - "How much profit have I made so far?"
  96. - "What’s the total profit summary for the bot?"
  97. - "Can you show me my trading gains?"
  98. 4. **Fetch Balance**:
  99. - "What’s my account balance?"
  100. - "How much money do I have in the trading account?"
  101. - "Tell me the current balance of my Freqtrade wallet."
  102. 5. **Fetch Performance**:
  103. - "How well has the bot been performing?"
  104. - "What are the performance metrics for my trades?"
  105. - "Show me the trading stats."
  106. 6. **Fetch Whitelist**:
  107. - "Which pairs are on the whitelist?"
  108. - "What trading pairs is the bot allowed to use?"
  109. - "List the whitelisted pairs for me."
  110. 7. **Fetch Blacklist**:
  111. - "Which pairs are blacklisted?"
  112. - "What trading pairs are blocked right now?"
  113. - "Tell me about the blacklist."
  114. 8. **Fetch Trades**:
  115. - "What’s the history of my closed trades?"
  116. - "Show me all the trades the bot has completed."
  117. - "Can you list my past trades?"
  118. 9. **Fetch Config**:
  119. - "What’s the current bot configuration?"
  120. - "Show me the settings the bot is using."
  121. - "Tell me about the Freqtrade config."
  122. 10. **Fetch Locks**:
  123. - "Are there any trade locks active?"
  124. - "What locks are currently in place?"
  125. - "Show me the list of trading locks."
  126. 11. **Place Trade**:
  127. - "Buy 0.01 BTC/USDT right now."
  128. - "Sell 0.05 ETH/USDT immediately."
  129. - "Place a buy order for 0.1 XRP/USDT."
  130. 12. **Start Bot**:
  131. - "Start the trading bot."
  132. - "Turn on the Freqtrade bot."
  133. - "Get the bot running now."
  134. 13. **Stop Bot**:
  135. - "Stop the trading bot."
  136. - "Shut down the Freqtrade bot."
  137. - "Pause the bot’s trading."
  138. 14. **Reload Config**:
  139. - "Reload the bot’s configuration."
  140. - "Update the bot settings."
  141. - "Refresh the Freqtrade config."
  142. 15. **Add Blacklist**:
  143. - "Blacklist ETH/USDT."
  144. - "Add BTC/ETH to the blacklist."
  145. - "Block trading for XRP/USDT."
  146. 16. **Delete Blacklist**:
  147. - "Remove ETH/USDT from the blacklist."
  148. - "Unblock BTC/ETH for trading."
  149. - "Take XRP/USDT off the blacklist."
  150. 17. **Delete Lock**:
  151. - "Delete the trade lock with ID 123."
  152. - "Remove lock number 45."
  153. - "Unlock the trade with ID 7."
  154. ## License
  155. This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.