2025-12-29 03:06:49 +08:00
|
|
|
"""
|
2026-01-13 04:01:42 +08:00
|
|
|
API Routes Module
|
2025-12-29 03:06:49 +08:00
|
|
|
"""
|
|
|
|
|
from flask import Flask
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def register_routes(app: Flask):
|
2026-01-13 04:01:42 +08:00
|
|
|
"""Register all API route blueprints"""
|
2025-12-29 03:06:49 +08:00
|
|
|
from app.routes.kline import kline_bp
|
|
|
|
|
from app.routes.backtest import backtest_bp
|
|
|
|
|
from app.routes.health import health_bp
|
|
|
|
|
from app.routes.market import market_bp
|
|
|
|
|
from app.routes.strategy import strategy_bp
|
|
|
|
|
from app.routes.credentials import credentials_bp
|
|
|
|
|
from app.routes.auth import auth_bp
|
|
|
|
|
from app.routes.ai_chat import ai_chat_bp
|
|
|
|
|
from app.routes.indicator import indicator_bp
|
|
|
|
|
from app.routes.dashboard import dashboard_bp
|
2025-12-29 19:05:17 +08:00
|
|
|
from app.routes.settings import settings_bp
|
2026-01-12 22:36:10 +08:00
|
|
|
from app.routes.portfolio import portfolio_bp
|
2026-01-13 02:35:48 +08:00
|
|
|
from app.routes.ibkr import ibkr_bp
|
2026-01-13 04:01:42 +08:00
|
|
|
from app.routes.mt5 import mt5_bp
|
2026-01-14 05:29:55 +08:00
|
|
|
from app.routes.user import user_bp
|
2026-01-24 23:26:26 +08:00
|
|
|
from app.routes.global_market import global_market_bp
|
2026-01-31 02:59:49 +08:00
|
|
|
from app.routes.community import community_bp
|
|
|
|
|
from app.routes.fast_analysis import fast_analysis_bp
|
2026-02-27 01:57:04 +08:00
|
|
|
from app.routes.billing import billing_bp
|
2026-02-27 19:57:23 +08:00
|
|
|
from app.routes.quick_trade import quick_trade_bp
|
2026-03-01 03:42:10 +08:00
|
|
|
from app.routes.polymarket import polymarket_bp
|
2025-12-29 03:06:49 +08:00
|
|
|
|
|
|
|
|
app.register_blueprint(health_bp)
|
2026-01-14 20:42:10 +08:00
|
|
|
app.register_blueprint(auth_bp, url_prefix='/api/auth') # Auth routes
|
2026-01-14 05:29:55 +08:00
|
|
|
app.register_blueprint(user_bp, url_prefix='/api/users') # User management
|
2025-12-29 03:06:49 +08:00
|
|
|
app.register_blueprint(kline_bp, url_prefix='/api/indicator')
|
|
|
|
|
app.register_blueprint(backtest_bp, url_prefix='/api/indicator')
|
|
|
|
|
app.register_blueprint(market_bp, url_prefix='/api/market')
|
|
|
|
|
app.register_blueprint(ai_chat_bp, url_prefix='/api/ai')
|
|
|
|
|
app.register_blueprint(indicator_bp, url_prefix='/api/indicator')
|
|
|
|
|
app.register_blueprint(strategy_bp, url_prefix='/api')
|
|
|
|
|
app.register_blueprint(credentials_bp, url_prefix='/api/credentials')
|
|
|
|
|
app.register_blueprint(dashboard_bp, url_prefix='/api/dashboard')
|
2025-12-29 19:05:17 +08:00
|
|
|
app.register_blueprint(settings_bp, url_prefix='/api/settings')
|
2026-01-12 22:36:10 +08:00
|
|
|
app.register_blueprint(portfolio_bp, url_prefix='/api/portfolio')
|
2026-01-13 02:35:48 +08:00
|
|
|
app.register_blueprint(ibkr_bp, url_prefix='/api/ibkr')
|
2026-01-13 04:01:42 +08:00
|
|
|
app.register_blueprint(mt5_bp, url_prefix='/api/mt5')
|
2026-01-31 02:59:49 +08:00
|
|
|
app.register_blueprint(global_market_bp, url_prefix='/api/global-market')
|
|
|
|
|
app.register_blueprint(community_bp, url_prefix='/api/community')
|
2026-02-27 01:57:04 +08:00
|
|
|
app.register_blueprint(fast_analysis_bp, url_prefix='/api/fast-analysis')
|
2026-02-27 19:57:23 +08:00
|
|
|
app.register_blueprint(billing_bp, url_prefix='/api/billing')
|
2026-03-01 03:42:10 +08:00
|
|
|
app.register_blueprint(quick_trade_bp, url_prefix='/api/quick-trade')
|
|
|
|
|
app.register_blueprint(polymarket_bp, url_prefix='/api/polymarket')
|