fix(TSL): Enable TSL by default in MCP tool
Changed is_tsl_enabled default from False to True in: - Tool schema definition - Payload construction (arguments.get default) Fixes issue where MCP tool was overriding conductor API schema default. Requires Claude Code restart to reload MCP tools. Related: eToroGridbot commit 2d91848
This commit is contained in:
Binary file not shown.
@@ -266,7 +266,7 @@ async def list_tools() -> list[Tool]:
|
||||
"take_profit_pct": {"type": "number", "description": "Take profit percentage (e.g., 10 for 10%)"},
|
||||
"stop_loss_pct": {"type": "number", "description": "Stop loss percentage (e.g., 5 for 5%)"},
|
||||
"dry_run": {"type": "boolean", "default": False, "description": "Validate only, do not execute"},
|
||||
"is_tsl_enabled": {"type": "boolean", "default": False, "description": "Enable trailing stop loss (eToro native feature)"},
|
||||
"is_tsl_enabled": {"type": "boolean", "default": True, "description": "Enable trailing stop loss (eToro native feature)"},
|
||||
},
|
||||
"required": ["symbol", "action", "amount"],
|
||||
},
|
||||
@@ -535,7 +535,7 @@ async def call_tool(name: str, arguments: dict[str, Any]) -> list[TextContent]:
|
||||
"take_profit_pct": arguments.get("take_profit_pct", 10),
|
||||
"stop_loss_pct": arguments.get("stop_loss_pct", 5),
|
||||
"dry_run": arguments.get("dry_run", False),
|
||||
"is_tsl_enabled": arguments.get("is_tsl_enabled", False),
|
||||
"is_tsl_enabled": arguments.get("is_tsl_enabled", True),
|
||||
}
|
||||
if arguments.get("limit_price"):
|
||||
payload["limit_price"] = arguments["limit_price"]
|
||||
|
||||
Reference in New Issue
Block a user