mirror of
https://github.com/freqtrade/freqtrade.git
synced 2026-02-03 21:00:25 +00:00
Provide strategy timeframe via API
This commit is contained in:
@@ -471,6 +471,7 @@ class FreqAIModelListResponse(BaseModel):
|
||||
class StrategyResponse(BaseModel):
|
||||
strategy: str
|
||||
code: str
|
||||
timeframe: Optional[str]
|
||||
|
||||
|
||||
class AvailablePairs(BaseModel):
|
||||
|
||||
@@ -350,6 +350,7 @@ def get_strategy(strategy: str, config=Depends(get_config)):
|
||||
return {
|
||||
'strategy': strategy_obj.get_strategy_name(),
|
||||
'code': strategy_obj.__source__,
|
||||
'timeframe': getattr(strategy_obj, 'timeframe', None),
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user