{"components":{"schemas":{"AccountCreate":{"properties":{"account_type":{"type":["string","null"]},"api_key":{"type":["string","null"]},"base_url":{"type":["string","null"]},"initial_capital":{"format":"double","type":["number","null"]},"model":{"type":["string","null"]},"name":{"type":"string"}},"required":["name"],"type":"object"},"AccountOut":{"properties":{"account_type":{"type":"string"},"avatar_preset_id":{"format":"int32","type":["integer","null"]},"base_url":{"type":["string","null"]},"current_cash":{"format":"double","type":"number"},"default_leverage":{"format":"int32","type":["integer","null"]},"frozen_cash":{"format":"double","type":"number"},"hyperliquid_enabled":{"type":"boolean"},"hyperliquid_environment":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"initial_capital":{"format":"double","type":"number"},"is_active":{"type":"boolean"},"max_leverage":{"format":"int32","type":["integer","null"]},"model":{"type":["string","null"]},"name":{"type":"string"},"show_on_dashboard":{"type":"boolean"},"user_id":{"format":"int32","type":"integer"}},"required":["id","user_id","name","initial_capital","current_cash","frozen_cash","account_type","is_active","show_on_dashboard","hyperliquid_enabled"],"type":"object"},"AccountOverview":{"properties":{"account":{"$ref":"#/components/schemas/AccountOut"},"positions_value":{"format":"double","type":"number"},"total_assets":{"format":"double","type":"number"}},"required":["account","total_assets","positions_value"],"type":"object"},"AccountSnapshotResponse":{"description":"Account snapshot wrapper mirroring the persisted\n`hyperliquid_account_snapshots` / `binance_account_snapshots` row shape.","properties":{"account_id":{"format":"int32","type":"integer"},"balance_available":{"format":"double","type":["number","null"]},"balance_total":{"format":"double","type":["number","null"]},"environment":{"type":"string"},"id":{"format":"int32","type":"integer"},"margin_used":{"format":"double","type":["number","null"]},"taken_at":{"type":["string","null"]},"unrealized_pnl":{"format":"double","type":["number","null"]}},"required":["id","account_id","environment"],"type":"object"},"AccountUpdate":{"properties":{"api_key":{"type":["string","null"]},"base_url":{"type":["string","null"]},"model":{"type":["string","null"]},"name":{"type":["string","null"]}},"type":"object"},"ActionSummaryResponse":{"description":"Action-summary row.","properties":{"account_id":{"format":"int32","type":"integer"},"exchange":{"type":"string"},"failed":{"format":"int64","type":"integer"},"successful":{"format":"int64","type":"integer"},"total_actions":{"format":"int64","type":"integer"}},"required":["exchange","account_id","total_actions","successful","failed"],"type":"object"},"AiAttributionChatRequest":{"properties":{"account_id":{"format":"int32","type":["integer","null"]},"conversation_id":{"format":"int32","type":["integer","null"]},"message":{"type":"string"}},"required":["message"],"type":"object"},"AiStreamChunk":{"description":"Individual streaming chunk delivered via polling.","properties":{"content":{"type":["string","null"]},"index":{"minimum":0,"type":"integer"},"kind":{"type":"string"},"metadata":{"type":"object"}},"required":["index","kind","metadata"],"type":"object"},"AiStreamChunksResponse":{"description":"`GET /api/ai-stream/{task_id}/chunks` response.","properties":{"chunks":{"items":{"$ref":"#/components/schemas/AiStreamChunk"},"type":"array"},"is_done":{"type":"boolean"},"next_cursor":{"minimum":0,"type":"integer"},"status":{"type":"string"},"task_id":{"type":"string"}},"required":["task_id","chunks","next_cursor","is_done","status"],"type":"object"},"AiStreamTaskStatus":{"description":"AI stream task status.","properties":{"error":{"type":["string","null"]},"is_done":{"type":"boolean"},"status":{"type":"string"},"task_id":{"type":"string"},"total_chunks":{"minimum":0,"type":"integer"}},"required":["task_id","status","total_chunks","is_done"],"type":"object"},"AnalyticsGroupItem":{"description":"Generic \"split by dimension\" row shared across the strategy / account /\nsymbol / operation / trigger / factor breakdowns.","properties":{"commission":{"format":"double","type":["number","null"]},"extra":{"type":"object"},"key":{"type":"string"},"pnl":{"format":"double","type":["number","null"]},"trade_count":{"format":"int64","type":"integer"},"win_rate":{"format":"double","type":["number","null"]}},"required":["key","trade_count","extra"],"type":"object"},"AnalyticsGroupResponse":{"description":"Wrapper for grouped analytics (strategy/account/symbol/operation/trigger/factor).","properties":{"dimension":{"type":"string"},"filters":{"type":"object"},"items":{"items":{"$ref":"#/components/schemas/AnalyticsGroupItem"},"type":"array"}},"required":["dimension","items","filters"],"type":"object"},"AnalyticsSummaryResponse":{"description":"Portfolio-wide rollup returned by `GET /api/analytics/summary`.","properties":{"accounts":{"format":"int64","type":["integer","null"]},"filters":{"type":"object"},"symbols":{"format":"int64","type":["integer","null"]},"total_commission":{"format":"double","type":"number"},"total_pnl":{"format":"double","type":["number","null"]},"total_trades":{"format":"int64","type":"integer"},"win_rate":{"format":"double","type":["number","null"]}},"required":["total_trades","total_commission","filters"],"type":"object"},"AnalyticsTradeItem":{"description":"Individual trade as rendered in the analytics trade list.","properties":{"account_id":{"format":"int32","type":"integer"},"commission":{"format":"double","type":"number"},"id":{"format":"int32","type":"integer"},"name":{"type":["string","null"]},"price":{"format":"double","type":"number"},"quantity":{"format":"double","type":"number"},"side":{"type":"string"},"symbol":{"type":"string"},"trade_time":{"type":["string","null"]}},"required":["id","account_id","symbol","side","price","quantity","commission"],"type":"object"},"AnalyticsTradesListResponse":{"description":"`GET /api/analytics/trades` response.","properties":{"dimension":{"type":"string"},"filters":{"type":"object"},"items":{"items":{"$ref":"#/components/schemas/AnalyticsTradeItem"},"type":"array"},"limit":{"format":"int64","type":"integer"},"tag_filter":{"type":["string","null"]}},"required":["dimension","items","limit","filters"],"type":"object"},"AttributionChatRequest":{"description":"AI attribution chat submit request.","properties":{"conversation_id":{"format":"int64","type":["integer","null"]},"filters":{"type":"object"},"message":{"type":"string"}},"required":["message","filters"],"type":"object"},"AttributionConversation":{"description":"AI attribution conversation summary.","properties":{"created_at":{"type":["string","null"]},"id":{"format":"int64","type":"integer"},"title":{"type":["string","null"]},"updated_at":{"type":["string","null"]}},"required":["id"],"type":"object"},"AttributionConversationsResponse":{"description":"AI attribution conversation list.","properties":{"conversations":{"items":{"$ref":"#/components/schemas/AttributionConversation"},"type":"array"}},"required":["conversations"],"type":"object"},"BackfillStartResponse":{"description":"`POST /api/system/{binance,hyperliquid}-backfill` response.","properties":{"exchange":{"type":"string"},"started_at":{"type":["string","null"]},"status":{"type":"string"},"task_id":{"type":"string"}},"required":["task_id","status","exchange"],"type":"object"},"BackfillStatusResponse":{"description":"Backfill progress.","properties":{"exchange":{"type":"string"},"progress":{"format":"double","type":["number","null"]},"rows_written":{"format":"int64","type":["integer","null"]},"status":{"type":"string"},"task_id":{"type":["string","null"]},"updated_at":{"type":["string","null"]}},"required":["status","exchange"],"type":"object"},"BackfillTaskOut":{"description":"Backfill task descriptor.","properties":{"environment":{"type":"string"},"exchange":{"type":"string"},"finished_at":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"period":{"type":["string","null"]},"rows_written":{"format":"int64","type":["integer","null"]},"started_at":{"type":["string","null"]},"status":{"type":"string"},"symbol":{"type":["string","null"]}},"required":["id","exchange","environment","status"],"type":"object"},"BackfillTasksResponse":{"description":"Backfill task listing.","properties":{"tasks":{"items":{"$ref":"#/components/schemas/BackfillTaskOut"},"type":"array"}},"required":["tasks"],"type":"object"},"BacktestDetailResponse":{"description":"Backtest detail payload.","properties":{"backtest":{"$ref":"#/components/schemas/BacktestOut"},"metrics":{"type":"object"},"trades":{"items":{"type":"object"},"type":"array"}},"required":["backtest","metrics","trades"],"type":"object"},"BacktestMarker":{"description":"Chart marker shape.","properties":{"price":{"format":"double","type":["number","null"]},"side":{"type":["string","null"]},"symbol":{"type":"string"},"timestamp":{"format":"int64","type":"integer"}},"required":["timestamp","symbol"],"type":"object"},"BacktestMarkersResponse":{"description":"Chart marker list.","properties":{"markers":{"items":{"$ref":"#/components/schemas/BacktestMarker"},"type":"array"}},"required":["markers"],"type":"object"},"BacktestOut":{"description":"Backtest result row.","properties":{"account_id":{"format":"int32","type":["integer","null"]},"finished_at":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"program_id":{"format":"int32","type":["integer","null"]},"started_at":{"type":["string","null"]},"status":{"type":"string"},"total_pnl":{"format":"double","type":["number","null"]},"total_trades":{"format":"int64","type":["integer","null"]},"win_rate":{"format":"double","type":["number","null"]}},"required":["id","status"],"type":"object"},"BacktestTrigger":{"description":"Trigger marker on a chart.","properties":{"kind":{"type":"string"},"payload":{"type":"object"},"reason":{"type":["string","null"]},"symbol":{"type":"string"},"timestamp":{"format":"int64","type":"integer"}},"required":["timestamp","symbol","kind","payload"],"type":"object"},"BacktestTriggersResponse":{"description":"Trigger listing.","properties":{"triggers":{"items":{"$ref":"#/components/schemas/BacktestTrigger"},"type":"array"}},"required":["triggers"],"type":"object"},"BacktestsListResponse":{"description":"Backtest list.","properties":{"backtests":{"items":{"$ref":"#/components/schemas/BacktestOut"},"type":"array"}},"required":["backtests"],"type":"object"},"BotConfigOut":{"description":"Bot config entry.","properties":{"bot_type":{"type":"string"},"chat_id":{"type":["string","null"]},"created_at":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"is_active":{"type":"boolean"}},"required":["id","bot_type","is_active"],"type":"object"},"BotConfigsResponse":{"description":"Listing wrapper for bot configs.","properties":{"bots":{"items":{"$ref":"#/components/schemas/BotConfigOut"},"type":"array"}},"required":["bots"],"type":"object"},"ChatMessage":{"description":"Individual chat message.","properties":{"content":{"type":"string"},"created_at":{"type":["string","null"]},"id":{"format":"int64","type":"integer"},"metadata":{"type":"object"},"role":{"type":"string"}},"required":["id","role","content","metadata"],"type":"object"},"CollectionDaysResponse":{"description":"Collection-days envelope.","properties":{"collection_days":{"format":"int32","type":"integer"},"exchange":{"type":"string"}},"required":["exchange","collection_days"],"type":"object"},"ConfigValueRequest":{"properties":{"value":{"type":"string"}},"required":["value"],"type":"object"},"ConfirmToolRequest":{"properties":{"confirmation_id":{"type":"string"},"confirmed":{"type":"boolean"},"task_id":{"type":"string"}},"required":["task_id","confirmation_id","confirmed"],"type":"object"},"ConversationSummary":{"description":"Conversation list item.","properties":{"created_at":{"type":["string","null"]},"id":{"format":"int64","type":"integer"},"message_count":{"format":"int64","type":["integer","null"]},"title":{"type":["string","null"]},"updated_at":{"type":["string","null"]}},"required":["id"],"type":"object"},"ConversationsListResponse":{"description":"Wrapper for conversation listings.","properties":{"conversations":{"items":{"$ref":"#/components/schemas/ConversationSummary"},"type":"array"}},"required":["conversations"],"type":"object"},"CountResponse":{"description":"`{ \"count\": N }` response.","properties":{"count":{"format":"int64","type":"integer"}},"required":["count"],"type":"object"},"CoverageResponse":{"description":"Coverage listing.","properties":{"coverage":{"items":{"$ref":"#/components/schemas/CoverageRow"},"type":"array"}},"required":["coverage"],"type":"object"},"CoverageRow":{"description":"K-line coverage metrics.","properties":{"environment":{"type":"string"},"exchange":{"type":"string"},"newest":{"type":["string","null"]},"oldest":{"type":["string","null"]},"period":{"type":"string"},"symbol":{"type":"string"},"total_candles":{"format":"int64","type":["integer","null"]}},"required":["symbol","period","exchange","environment"],"type":"object"},"CreateBackfillRequest":{"description":"Create backfill request.","properties":{"end":{"type":["string","null"]},"environment":{"type":["string","null"]},"exchange":{"type":"string"},"period":{"type":["string","null"]},"start":{"type":["string","null"]},"symbol":{"type":"string"}},"required":["symbol","exchange"],"type":"object"},"DashboardVisibilityItem":{"properties":{"account_id":{"format":"int32","type":"integer"},"show_on_dashboard":{"type":"boolean"}},"required":["account_id","show_on_dashboard"],"type":"object"},"DashboardVisibilityUpdate":{"properties":{"updates":{"items":{"$ref":"#/components/schemas/DashboardVisibilityItem"},"type":"array"}},"required":["updates"],"type":"object"},"DataCoverageResponse":{"description":"`GET /api/system/data-coverage` response.","properties":{"coverage":{"items":{"type":"object"},"type":"array"}},"required":["coverage"],"type":"object"},"DataGap":{"description":"Data-gap detection result.","properties":{"exchange":{"type":"string"},"gap_end":{"type":"string"},"gap_start":{"type":"string"},"period":{"type":"string"},"symbol":{"type":"string"}},"required":["symbol","exchange","period","gap_start","gap_end"],"type":"object"},"DataGapsResponse":{"description":"Data gap listing.","properties":{"gaps":{"items":{"$ref":"#/components/schemas/DataGap"},"type":"array"}},"required":["gaps"],"type":"object"},"DeletedResponse":{"description":"`{ \"deleted\": N }` response for bulk delete endpoints.","properties":{"deleted":{"format":"int64","type":"integer"}},"required":["deleted"],"type":"object"},"DevGuideResponse":{"description":"Program-level developer guide (Markdown).","properties":{"language":{"type":"string"},"markdown":{"type":"string"}},"required":["markdown","language"],"type":"object"},"DynamicJson":{"description":"Generic free-form JSON object used as a fallback response schema for\nendpoints whose payload is large, deeply nested, or best documented via\ntheir narrative description rather than a fixed Rust type.\n\nNamed so it shows up as a proper `$ref` in the generated spec instead of\na bare `serde_json::Value`; clients that want stricter typing should\nreach for the domain-specific DTOs declared alongside the relevant\nhandler.","type":"object"},"DynamicListResponse":{"description":"`{ \"items\": [...] }` wrapper used by a handful of list endpoints that\ndon't have a more specific typed item shape yet.","examples":[{"items":[]}],"properties":{"items":{"items":{"type":"object"},"type":"array"}},"required":["items"],"type":"object"},"EnabledFlagResponse":{"description":"Simple `{ \"enabled\": bool }` toggle response.","properties":{"enabled":{"type":"boolean"},"message":{"type":["string","null"]}},"required":["enabled"],"type":"object"},"ErrorResponse":{"description":"Canonical error envelope returned by every failing endpoint.\n\nThe shape mirrors what `crate::error::AppError` serialises to; documenting\nit here lets every handler reuse the same schema reference instead of\nredeclaring a bespoke error body per route.","properties":{"code":{"description":"Short machine-readable error code, e.g. `bad_request`, `not_found`,\n`unauthorized`, `conflict`, `internal`.","examples":["bad_request"],"type":"string"},"details":{"description":"Optional structured details (validation errors, upstream payload,\netc.). Free-form JSON; clients should treat fields as optional.","type":"object"},"message":{"description":"Human-readable description of what went wrong.","examples":["session_token is required"],"type":"string"}},"required":["code","message","details"],"type":"object"},"ExchangeBalanceResponse":{"description":"Exchange balance snapshot.","properties":{"available":{"examples":[9876.54],"format":"double","type":"number"},"environment":{"examples":["mainnet"],"type":"string"},"exchange":{"examples":["hyperliquid"],"type":"string"},"margin_used":{"examples":[1500.0],"format":"double","type":["number","null"]},"total_equity":{"examples":[12345.67],"format":"double","type":"number"},"unrealized_pnl":{"examples":[0.05],"format":"double","type":["number","null"]}},"required":["exchange","environment","total_equity","available"],"type":"object"},"ExchangeConfigRequest":{"properties":{"selected_exchange":{"type":"string"}},"required":["selected_exchange"],"type":"object"},"ExchangeConfigResponse":{"properties":{"selected_exchange":{"type":"string"}},"required":["selected_exchange"],"type":"object"},"ExchangeHealthResponse":{"description":"Health check for an exchange integration.","properties":{"details":{"type":["string","null"]},"environment":{"type":"string"},"exchange":{"type":"string"},"latency_ms":{"format":"double","type":["number","null"]},"status":{"examples":["ok"],"type":"string"}},"required":["exchange","environment","status"],"type":"object"},"ExchangePosition":{"description":"Single open/closed position as surfaced by the exchange read APIs.","properties":{"entry_price":{"examples":[45000.0],"format":"double","type":["number","null"]},"leverage":{"examples":[10],"format":"int32","type":["integer","null"]},"liquidation_price":{"format":"double","type":["number","null"]},"mark_price":{"examples":[46200.0],"format":"double","type":["number","null"]},"side":{"examples":["long"],"type":"string"},"size":{"examples":[0.25],"format":"double","type":"number"},"symbol":{"type":"string"},"unrealized_pnl":{"examples":[300.0],"format":"double","type":["number","null"]}},"required":["symbol","side","size"],"type":"object"},"ExchangePositionsResponse":{"description":"Response wrapping positions plus totals.","properties":{"positions":{"items":{"$ref":"#/components/schemas/ExchangePosition"},"type":"array"},"total_count":{"format":"int64","type":"integer"},"total_unrealized_pnl":{"format":"double","type":["number","null"]}},"required":["positions","total_count"],"type":"object"},"ExchangeTransferRequest":{"description":"Transfer / approval request body shared across exchange actions.","properties":{"amount":{"format":"double","type":"number"},"asset":{"type":["string","null"]},"destination":{"type":"string"}},"required":["destination","amount"],"type":"object"},"FactorDefinition":{"description":"Factor catalogue entry.","properties":{"category":{"type":["string","null"]},"description":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"name":{"type":"string"},"source":{"type":["string","null"]}},"required":["id","name"],"type":"object"},"FactorEffectivenessResponse":{"description":"Factor effectiveness listing.","properties":{"items":{"items":{"$ref":"#/components/schemas/FactorEffectivenessRow"},"type":"array"},"total":{"format":"int64","type":"integer"}},"required":["items","total"],"type":"object"},"FactorEffectivenessRow":{"description":"Factor effectiveness row.","properties":{"computed_at":{"type":["string","null"]},"factor_name":{"type":"string"},"sample_size":{"format":"int64","type":["integer","null"]},"score":{"format":"double","type":["number","null"]},"symbol":{"type":"string"},"window":{"type":["string","null"]}},"required":["symbol","factor_name"],"type":"object"},"FactorExpressionRequest":{"description":"Factor expression evaluation request.","properties":{"context":{"type":"object"},"expression":{"type":"string"},"symbol":{"type":["string","null"]}},"required":["expression","context"],"type":"object"},"FactorExpressionResult":{"description":"Factor expression evaluation result.","properties":{"errors":{"items":{"type":"string"},"type":["array","null"]},"valid":{"type":"boolean"},"value":{"format":"double","type":["number","null"]}},"required":["valid"],"type":"object"},"FactorsListResponse":{"description":"Factor catalogue listing.","properties":{"factors":{"items":{"$ref":"#/components/schemas/FactorDefinition"},"type":"array"}},"required":["factors"],"type":"object"},"HealthResponse":{"description":"Liveness probe response.","properties":{"status":{"examples":["ok"],"type":"string"}},"required":["status"],"type":"object"},"IdResponse":{"description":"`{ \"id\": 42 }` style response from create endpoints.","properties":{"id":{"format":"int64","type":"integer"}},"required":["id"],"type":"object"},"IdsResponse":{"description":"`{ \"ids\": [1, 2, 3] }` style response from bulk endpoints.","properties":{"ids":{"items":{"format":"int64","type":"integer"},"type":"array"}},"required":["ids"],"type":"object"},"IndicatorDefinition":{"description":"Indicator catalogue entry.","properties":{"description":{"type":["string","null"]},"id":{"type":"string"},"name":{"type":"string"},"params":{"items":{"type":"string"},"type":["array","null"]}},"required":["id","name"],"type":"object"},"IndicatorsListResponse":{"description":"Indicator catalogue.","properties":{"indicators":{"items":{"$ref":"#/components/schemas/IndicatorDefinition"},"type":"array"}},"required":["indicators"],"type":"object"},"InsightTaskResponse":{"description":"Async insight task response.","properties":{"status":{"type":"string"},"task_id":{"type":"string"}},"required":["task_id","status"],"type":"object"},"KlineAnalysisDetail":{"description":"Kline analysis detail.","properties":{"body":{"type":"object"},"created_at":{"type":["string","null"]},"id":{"format":"int64","type":"integer"},"period":{"type":["string","null"]},"summary":{"type":["string","null"]},"symbol":{"type":"string"}},"required":["id","symbol","body"],"type":"object"},"KlineAnalysisHistoryResponse":{"description":"Kline analysis history list.","properties":{"analyses":{"items":{"$ref":"#/components/schemas/KlineAnalysisSummary"},"type":"array"}},"required":["analyses"],"type":"object"},"KlineAnalysisSummary":{"description":"Kline AI analysis result summary.","properties":{"created_at":{"type":["string","null"]},"id":{"format":"int64","type":"integer"},"period":{"type":["string","null"]},"summary":{"type":["string","null"]},"symbol":{"type":"string"}},"required":["id","symbol"],"type":"object"},"KlineCandle":{"description":"Single k-line candle, flexible shape.","properties":{"close":{"format":"double","type":"number"},"high":{"format":"double","type":"number"},"low":{"format":"double","type":"number"},"open":{"format":"double","type":"number"},"timestamp":{"format":"int64","type":"integer"},"volume":{"format":"double","type":["number","null"]}},"required":["timestamp","open","high","low","close"],"type":"object"},"KlineIndicatorsResponse":{"description":"K-line with indicators (payload is flexible).","properties":{"candles":{"items":{"$ref":"#/components/schemas/KlineCandle"},"type":"array"},"indicators":{"type":"object"},"period":{"type":"string"},"symbol":{"type":"string"}},"required":["symbol","period","candles","indicators"],"type":"object"},"KlineResponse":{"description":"K-line response.","properties":{"candles":{"items":{"$ref":"#/components/schemas/KlineCandle"},"type":"array"},"period":{"type":"string"},"symbol":{"type":"string"}},"required":["symbol","period","candles"],"type":"object"},"LogCategoriesResponse":{"description":"`GET /api/system-logs/categories`.","properties":{"categories":{"items":{"type":"string"},"type":"array"}},"required":["categories"],"type":"object"},"LogStatsResponse":{"description":"`GET /api/system-logs/stats`.","properties":{"by_category":{"type":"object"},"by_level":{"type":"object"},"total":{"format":"int64","type":"integer"}},"required":["total","by_level","by_category"],"type":"object"},"MarketFlowIndicatorRow":{"description":"Market-flow indicators row.","properties":{"exchange":{"type":"string"},"indicators":{"type":"object"},"symbol":{"type":"string"}},"required":["symbol","exchange","indicators"],"type":"object"},"MarketFlowIndicatorsResponse":{"description":"Market-flow indicators payload.","properties":{"rows":{"items":{"$ref":"#/components/schemas/MarketFlowIndicatorRow"},"type":"array"}},"required":["rows"],"type":"object"},"MarketRegimeBatchResponse":{"description":"Batch regime response.","properties":{"items":{"items":{"$ref":"#/components/schemas/MarketRegimeResponse"},"type":"array"}},"required":["items"],"type":"object"},"MarketRegimeConfigOut":{"description":"Regime configuration row.","properties":{"config":{"type":"object"},"id":{"format":"int32","type":"integer"},"symbol":{"type":"string"}},"required":["id","symbol","config"],"type":"object"},"MarketRegimeConfigsResponse":{"description":"Regime configs listing.","properties":{"configs":{"items":{"$ref":"#/components/schemas/MarketRegimeConfigOut"},"type":"array"}},"required":["configs"],"type":"object"},"MarketRegimeResponse":{"description":"Market regime label for one symbol.","properties":{"confidence":{"format":"double","type":["number","null"]},"regime":{"type":"string"},"symbol":{"type":"string"},"updated_at":{"type":["string","null"]}},"required":["symbol","regime"],"type":"object"},"MarketStatusResponse":{"description":"Market status envelope.","properties":{"details":{"type":["string","null"]},"exchanges_total":{"format":"int64","type":"integer"},"exchanges_up":{"format":"int64","type":"integer"},"status":{"type":"string"}},"required":["status","exchanges_up","exchanges_total"],"type":"object"},"MemoriesListResponse":{"description":"Memories listing.","properties":{"memories":{"items":{"$ref":"#/components/schemas/MemoryOut"},"type":"array"}},"required":["memories"],"type":"object"},"MemoryOut":{"description":"Persisted long-term memory.","properties":{"content":{"type":"string"},"created_at":{"type":["string","null"]},"id":{"format":"int64","type":"integer"},"source":{"type":["string","null"]}},"required":["id","content"],"type":"object"},"MessagesListResponse":{"description":"Wrapper for conversation message feed.","properties":{"messages":{"items":{"$ref":"#/components/schemas/ChatMessage"},"type":"array"},"total":{"format":"int64","type":"integer"}},"required":["messages","total"],"type":"object"},"MultiplePricesRequest":{"description":"Batch `POST /api/market/prices` payload.","properties":{"exchange":{"type":["string","null"]},"symbols":{"items":{"type":"string"},"type":"array"}},"required":["symbols"],"type":"object"},"MultiplePricesResponse":{"description":"Batch price response.","properties":{"prices":{"type":"object"}},"required":["prices"],"type":"object"},"NewsArticleOut":{"description":"News article.","properties":{"id":{"format":"int64","type":"integer"},"published_at":{"type":["string","null"]},"sentiment":{"type":["string","null"]},"source":{"type":["string","null"]},"symbols":{"items":{"type":"string"},"type":["array","null"]},"title":{"type":"string"},"url":{"type":["string","null"]}},"required":["id","title"],"type":"object"},"NewsListResponse":{"description":"News listing.","properties":{"articles":{"items":{"$ref":"#/components/schemas/NewsArticleOut"},"type":"array"}},"required":["articles"],"type":"object"},"NewsSourceOut":{"description":"News source configuration.","properties":{"enabled":{"type":"boolean"},"id":{"format":"int32","type":"integer"},"name":{"type":"string"},"url":{"type":"string"}},"required":["id","name","url","enabled"],"type":"object"},"NewsSourcesResponse":{"description":"News sources listing.","properties":{"sources":{"items":{"$ref":"#/components/schemas/NewsSourceOut"},"type":"array"}},"required":["sources"],"type":"object"},"NewsStatsResponse":{"description":"News stats snapshot.","properties":{"articles_today":{"format":"int64","type":["integer","null"]},"total_articles":{"format":"int64","type":"integer"},"total_sources":{"format":"int64","type":"integer"}},"required":["total_articles","total_sources"],"type":"object"},"NotificationConfigResponse":{"description":"Notification config payload (free-form for forward compatibility).","properties":{"config":{"type":"object"}},"required":["config"],"type":"object"},"OrderCreateRequest":{"properties":{"account_id":{"format":"int32","type":"integer"},"market":{"type":["string","null"]},"name":{"type":"string"},"order_type":{"type":"string"},"password":{"type":["string","null"]},"price":{"format":"double","type":["number","null"]},"quantity":{"format":"double","type":"number"},"session_token":{"type":["string","null"]},"side":{"type":"string"},"symbol":{"type":"string"},"username":{"type":["string","null"]}},"required":["account_id","symbol","name","side","order_type","quantity"],"type":"object"},"OrderExecutionResult":{"properties":{"executed":{"type":"boolean"},"message":{"type":"string"},"order_id":{"format":"int32","type":"integer"}},"required":["order_id","executed","message"],"type":"object"},"OrderOut":{"properties":{"account_id":{"format":"int32","type":"integer"},"filled_quantity":{"format":"double","type":"number"},"id":{"format":"int32","type":"integer"},"market":{"type":"string"},"name":{"type":"string"},"order_no":{"type":"string"},"order_type":{"type":"string"},"price":{"format":"double","type":["number","null"]},"quantity":{"format":"double","type":"number"},"side":{"type":"string"},"status":{"type":"string"},"symbol":{"type":"string"}},"required":["id","order_no","account_id","symbol","name","market","side","order_type","quantity","filled_quantity","status"],"type":"object"},"OrderProcessingResult":{"properties":{"executed_count":{"format":"int32","type":"integer"},"message":{"type":"string"},"total_checked":{"format":"int32","type":"integer"}},"required":["executed_count","total_checked","message"],"type":"object"},"PositionOut":{"properties":{"account_id":{"format":"int32","type":"integer"},"available_quantity":{"format":"double","type":"number"},"avg_cost":{"format":"double","type":"number"},"id":{"format":"int32","type":"integer"},"market":{"type":"string"},"name":{"type":"string"},"quantity":{"format":"double","type":"number"},"symbol":{"type":"string"}},"required":["id","account_id","symbol","name","market","quantity","available_quantity","avg_cost"],"type":"object"},"PreferencesRequest":{"description":"Preferences payload; free-form JSON body for forward-compat.","properties":{"preferences":{"type":"object"}},"required":["preferences"],"type":"object"},"PriceResponse":{"description":"Latest spot/perp price.","properties":{"as_of":{"type":["string","null"]},"price":{"format":"double","type":"number"},"symbol":{"type":"string"}},"required":["symbol","price"],"type":"object"},"ProfileResponse":{"description":"User's stored HyperAI profile + preferences.","properties":{"llm_model":{"type":["string","null"]},"llm_provider":{"type":["string","null"]},"onboarding_completed":{"type":"boolean"},"preferences":{}},"required":["onboarding_completed"],"type":"object"},"ProgramAnalyticsResponse":{"description":"Wrapper for program-level analytics endpoints.","properties":{"dimension":{"type":"string"},"filters":{"type":"object"},"items":{"items":{"$ref":"#/components/schemas/ProgramSummaryRow"},"type":"array"}},"required":["dimension","items","filters"],"type":"object"},"ProgramBindingOut":{"description":"Program binding linking a program to an AI trader account.","properties":{"account_id":{"format":"int32","type":"integer"},"enabled":{"type":"boolean"},"id":{"format":"int32","type":"integer"},"program_id":{"format":"int32","type":"integer"},"trigger_config":{"type":"object"}},"required":["id","program_id","account_id","enabled","trigger_config"],"type":"object"},"ProgramBindingsResponse":{"description":"Program bindings listing.","properties":{"bindings":{"items":{"$ref":"#/components/schemas/ProgramBindingOut"},"type":"array"}},"required":["bindings"],"type":"object"},"ProgramCreate":{"description":"Program create/update body.","properties":{"code":{"type":"string"},"description":{"type":["string","null"]},"language":{"type":["string","null"]},"name":{"type":"string"}},"required":["name","code"],"type":"object"},"ProgramExecution":{"description":"Program execution snapshot.","properties":{"account_id":{"format":"int32","type":["integer","null"]},"finished_at":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"program_id":{"format":"int32","type":"integer"},"result_summary":{"type":["string","null"]},"started_at":{"type":["string","null"]},"status":{"type":"string"},"symbol":{"type":["string","null"]}},"required":["id","program_id","status"],"type":"object"},"ProgramExecutionsResponse":{"description":"Program execution listing.","properties":{"executions":{"items":{"$ref":"#/components/schemas/ProgramExecution"},"type":"array"}},"required":["executions"],"type":"object"},"ProgramOut":{"description":"Trading program listing entry.","properties":{"created_at":{"type":["string","null"]},"description":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"language":{"type":"string"},"name":{"type":"string"},"updated_at":{"type":["string","null"]}},"required":["id","name","language"],"type":"object"},"ProgramSummaryRow":{"description":"Program-centric summary row used by `program_summary` et al.","properties":{"program_id":{"format":"int32","type":"integer"},"program_name":{"type":["string","null"]},"symbols_traded":{"format":"int64","type":["integer","null"]},"total_pnl":{"format":"double","type":["number","null"]},"total_trades":{"format":"int64","type":"integer"},"win_rate":{"format":"double","type":["number","null"]}},"required":["program_id","total_trades"],"type":"object"},"ProgramValidationResponse":{"description":"Program validation result.","properties":{"errors":{"items":{"type":"string"},"type":"array"},"valid":{"type":"boolean"},"warnings":{"items":{"type":"string"},"type":"array"}},"required":["valid","errors","warnings"],"type":"object"},"ProgramsListResponse":{"description":"Program listing.","properties":{"programs":{"items":{"$ref":"#/components/schemas/ProgramOut"},"type":"array"}},"required":["programs"],"type":"object"},"PromptBacktestResultRow":{"description":"Prompt backtest result row.","properties":{"id":{"format":"int32","type":"integer"},"outcome":{"type":["string","null"]},"payload":{"type":"object"},"symbol":{"type":["string","null"]},"task_id":{"format":"int32","type":"integer"}},"required":["id","task_id","payload"],"type":"object"},"PromptBacktestResultsResponse":{"description":"Prompt backtest results listing.","properties":{"results":{"items":{"$ref":"#/components/schemas/PromptBacktestResultRow"},"type":"array"},"total":{"format":"int64","type":"integer"}},"required":["results","total"],"type":"object"},"PromptBacktestTaskOut":{"description":"Prompt backtest task row.","properties":{"account_id":{"format":"int32","type":["integer","null"]},"finished_at":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"progress":{"format":"double","type":["number","null"]},"sample_count":{"format":"int64","type":["integer","null"]},"started_at":{"type":["string","null"]},"status":{"type":"string"}},"required":["id","status"],"type":"object"},"PromptBacktestTasksResponse":{"description":"Prompt backtest tasks listing.","properties":{"tasks":{"items":{"$ref":"#/components/schemas/PromptBacktestTaskOut"},"type":"array"}},"required":["tasks"],"type":"object"},"PromptBindingOut":{"properties":{"account_id":{"format":"int32","type":"integer"},"id":{"format":"int32","type":"integer"},"prompt_template_id":{"format":"int32","type":"integer"},"updated_by":{"type":["string","null"]}},"required":["id","account_id","prompt_template_id"],"type":"object"},"PromptBindingUpsert":{"properties":{"account_id":{"format":"int32","type":"integer"},"prompt_template_id":{"format":"int32","type":"integer"}},"required":["account_id","prompt_template_id"],"type":"object"},"PromptListResponse":{"properties":{"bindings":{"items":{"$ref":"#/components/schemas/PromptBindingOut"},"type":"array"},"templates":{"items":{"$ref":"#/components/schemas/PromptTemplateOut"},"type":"array"}},"required":["templates","bindings"],"type":"object"},"PromptTemplateCreate":{"properties":{"created_by":{"type":["string","null"]},"description":{"type":["string","null"]},"name":{"type":"string"},"template_text":{"type":["string","null"]}},"required":["name"],"type":"object"},"PromptTemplateOut":{"properties":{"created_at":{"type":["string","null"]},"created_by":{"type":"string"},"description":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"is_deleted":{"type":"boolean"},"is_system":{"type":"boolean"},"key":{"type":"string"},"name":{"type":"string"},"system_template_text":{"type":"string"},"template_text":{"type":"string"},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]}},"required":["id","key","name","template_text","system_template_text","is_system","is_deleted","created_by"],"type":"object"},"PromptTemplateUpdateRequest":{"properties":{"description":{"type":["string","null"]},"template_text":{"type":"string"},"updated_by":{"type":["string","null"]}},"required":["template_text"],"type":"object"},"ProviderInfo":{"description":"Available LLM provider slot.","properties":{"base_url":{"type":["string","null"]},"id":{"type":"string"},"models":{"items":{"type":"string"},"type":"array"},"name":{"type":"string"},"requires_api_key":{"type":"boolean"}},"required":["id","name","models","requires_api_key"],"type":"object"},"ProvidersListResponse":{"description":"Provider catalogue.","properties":{"providers":{"items":{"$ref":"#/components/schemas/ProviderInfo"},"type":"array"}},"required":["providers"],"type":"object"},"RankingResponse":{"description":"Ranking listing response.","properties":{"computed_at":{"type":["string","null"]},"rows":{"items":{"$ref":"#/components/schemas/RankingRow"},"type":"array"}},"required":["rows"],"type":"object"},"RankingRow":{"description":"Ranking table row.","properties":{"factors":{"type":"object"},"rank":{"format":"int32","type":"integer"},"score":{"format":"double","type":"number"},"symbol":{"type":"string"}},"required":["symbol","rank","score","factors"],"type":"object"},"RateLimitResponse":{"description":"Market rate-limit / API health summary.","properties":{"environment":{"type":"string"},"exchange":{"type":"string"},"requests_remaining":{"format":"int64","type":["integer","null"]},"reset_at":{"type":["string","null"]},"window_seconds":{"format":"int64","type":["integer","null"]}},"required":["exchange","environment"],"type":"object"},"RetentionDaysOut":{"description":"Retention days envelope.","properties":{"exchange":{"type":"string"},"retention_days":{"format":"int32","type":"integer"}},"required":["exchange","retention_days"],"type":"object"},"RetentionDaysRequest":{"properties":{"days":{"format":"int32","type":"integer"},"exchange":{"type":["string","null"]}},"required":["days"],"type":"object"},"RetentionDaysResponse":{"properties":{"days":{"format":"int32","type":"integer"},"exchange":{"type":"string"}},"required":["days","exchange"],"type":"object"},"SamplingConfigOut":{"properties":{"sampling_depth":{"format":"int32","type":"integer"},"sampling_interval":{"format":"int32","type":"integer"}},"required":["sampling_interval","sampling_depth"],"type":"object"},"SamplingConfigUpdate":{"properties":{"sampling_depth":{"format":"int32","type":["integer","null"]},"sampling_interval":{"format":"int32","type":["integer","null"]}},"type":"object"},"SamplingPoolDetail":{"description":"Sampling pool detailed entry.","properties":{"extra":{"type":"object"},"last_sampled_at":{"type":["string","null"]},"pool_id":{"format":"int32","type":"integer"},"symbols":{"items":{"type":"string"},"type":"array"}},"required":["pool_id","symbols","extra"],"type":"object"},"SamplingPoolListResponse":{"description":"Sampling pool listing.","properties":{"pools":{"items":{"$ref":"#/components/schemas/SamplingPoolStatus"},"type":"array"}},"required":["pools"],"type":"object"},"SamplingPoolStatus":{"description":"Sampling pool status.","properties":{"last_sampled_at":{"type":["string","null"]},"pool_id":{"format":"int32","type":"integer"},"symbol_count":{"format":"int64","type":"integer"}},"required":["pool_id","symbol_count"],"type":"object"},"SaveLlmConfigRequest":{"description":"LLM config persistence payload.","properties":{"api_key":{"type":"string"},"base_url":{"type":["string","null"]},"model":{"examples":["gpt-4o"],"type":"string"},"provider":{"examples":["openai"],"type":"string"}},"required":["provider","model","api_key"],"type":"object"},"SignalBacktestResponse":{"description":"Signal backtest result row.","properties":{"payload":{"type":"object"},"pool_id":{"format":"int32","type":["integer","null"]},"signal_id":{"format":"int32","type":["integer","null"]},"total_triggers":{"format":"int64","type":"integer"},"win_rate":{"format":"double","type":["number","null"]}},"required":["total_triggers","payload"],"type":"object"},"SignalCompositeCondition":{"properties":{"conditions":{"items":{"$ref":"#/components/schemas/SignalCondition"},"type":"array"},"logic":{"type":"string"}},"required":["logic","conditions"],"type":"object"},"SignalCondition":{"properties":{"metric":{"type":"string"},"operator":{"type":"string"},"threshold":{"format":"double","type":"number"},"time_window":{"type":"string"}},"required":["metric","operator","threshold","time_window"],"type":"object"},"SignalDefinitionCreate":{"properties":{"description":{"type":["string","null"]},"enabled":{"type":["boolean","null"]},"exchange":{"type":["string","null"]},"signal_name":{"type":"string"},"trigger_condition":{}},"required":["signal_name","trigger_condition"],"type":"object"},"SignalDefinitionResponse":{"properties":{"created_at":{"type":["string","null"]},"description":{"type":["string","null"]},"enabled":{"type":["boolean","null"]},"exchange":{"type":"string"},"id":{"format":"int32","type":"integer"},"signal_name":{"type":"string"},"trigger_condition":{},"updated_at":{"type":["string","null"]}},"required":["id","signal_name","trigger_condition","exchange"],"type":"object"},"SignalDefinitionUpdate":{"properties":{"description":{"type":["string","null"]},"enabled":{"type":["boolean","null"]},"exchange":{"type":["string","null"]},"signal_name":{"type":["string","null"]},"trigger_condition":{}},"type":"object"},"SignalListResponse":{"properties":{"pools":{"items":{"$ref":"#/components/schemas/SignalPoolResponse"},"type":"array"},"signals":{"items":{"$ref":"#/components/schemas/SignalDefinitionResponse"},"type":"array"}},"required":["signals","pools"],"type":"object"},"SignalPoolCreate":{"properties":{"enabled":{"type":["boolean","null"]},"exchange":{"type":["string","null"]},"logic":{"type":["string","null"]},"pool_name":{"type":"string"},"signal_ids":{"items":{"format":"int32","type":"integer"},"type":"array"},"source_config":{},"source_type":{"type":["string","null"]},"symbols":{"items":{"type":"string"},"type":"array"}},"required":["pool_name","signal_ids","symbols"],"type":"object"},"SignalPoolResponse":{"properties":{"created_at":{"type":["string","null"]},"enabled":{"type":["boolean","null"]},"exchange":{"type":"string"},"id":{"format":"int32","type":"integer"},"logic":{"type":["string","null"]},"pool_name":{"type":"string"},"signal_ids":{},"source_config":{},"source_type":{"type":"string"},"symbols":{}},"required":["id","pool_name","signal_ids","symbols","exchange","source_type","source_config"],"type":"object"},"SignalPoolUpdate":{"properties":{"enabled":{"type":["boolean","null"]},"exchange":{"type":["string","null"]},"logic":{"type":["string","null"]},"pool_name":{"type":["string","null"]},"signal_ids":{"items":{"format":"int32","type":"integer"},"type":["array","null"]},"source_config":{},"source_type":{"type":["string","null"]},"symbols":{"items":{"type":"string"},"type":["array","null"]}},"type":"object"},"SignalStateOut":{"description":"Signal trigger log wrapper.","properties":{"is_active":{"type":"boolean"},"last_checked_at":{"type":["string","null"]},"last_value":{"type":"object"},"signal_id":{"format":"int32","type":"integer"},"symbol":{"type":"string"}},"required":["signal_id","symbol","is_active","last_value"],"type":"object"},"SignalStatesResponse":{"description":"Signal states listing.","properties":{"states":{"items":{"$ref":"#/components/schemas/SignalStateOut"},"type":"array"}},"required":["states"],"type":"object"},"SignalTriggerLogResponse":{"properties":{"id":{"format":"int32","type":"integer"},"market_regime":{},"pool_id":{"format":"int32","type":["integer","null"]},"signal_id":{"format":"int32","type":["integer","null"]},"symbol":{"type":"string"},"trigger_value":{},"triggered_at":{"type":["string","null"]}},"required":["id","symbol"],"type":"object"},"SignalTriggerLogsResponse":{"properties":{"logs":{"items":{"$ref":"#/components/schemas/SignalTriggerLogResponse"},"type":"array"},"total":{"minimum":0,"type":"integer"}},"required":["logs","total"],"type":"object"},"SkillOut":{"description":"Skill entry.","properties":{"category":{"type":["string","null"]},"description":{"type":["string","null"]},"enabled":{"type":"boolean"},"id":{"format":"int64","type":"integer"},"name":{"type":"string"}},"required":["id","name","enabled"],"type":"object"},"SkillsListResponse":{"description":"Skills catalogue.","properties":{"skills":{"items":{"$ref":"#/components/schemas/SkillOut"},"type":"array"}},"required":["skills"],"type":"object"},"StartChatRequest":{"description":"Chat-start request body.","properties":{"context":{"type":"object"},"conversation_id":{"format":"int64","type":["integer","null"]},"message":{"type":"string"},"skill_ids":{"items":{"format":"int64","type":"integer"},"type":["array","null"]}},"required":["message","context"],"type":"object"},"StartInsightRequest":{"description":"Payload for starting an insight run.","properties":{"prompt":{"type":["string","null"]},"symbol":{"type":["string","null"]},"timeframe":{"type":["string","null"]}},"type":"object"},"StatusMessageResponse":{"description":"Generic `{ \"status\": \"success\", \"message\": \"...\" }` ack used by handlers\nwhose primary purpose is side effects (toggles, deletes, async starts).","properties":{"message":{"type":["string","null"]},"status":{"examples":["success"],"type":"string"}},"required":["status"],"type":"object"},"StatusResponse":{"description":"`{ \"status\": \"ok\" | \"degraded\" | \"error\" }` response.","properties":{"status":{"examples":["ok"],"type":"string"}},"required":["status"],"type":"object"},"StorageStatsResponse":{"description":"`GET /api/system/storage-stats` response.","properties":{"tables":{"type":"object"},"total_rows":{"format":"int64","type":["integer","null"]},"total_size_mb":{"format":"double","type":["number","null"]}},"required":["tables"],"type":"object"},"StrategyConfigOut":{"properties":{"enabled":{"type":"boolean"},"exchange":{"type":"string"},"last_trigger_at":{"type":["string","null"]},"scheduled_trigger_enabled":{"type":"boolean"},"signal_pool_ids":{"items":{"format":"int32","type":"integer"},"type":["array","null"]},"trigger_interval":{"format":"int32","type":"integer"}},"required":["trigger_interval","enabled","scheduled_trigger_enabled","exchange"],"type":"object"},"StrategyConfigUpdate":{"properties":{"enabled":{"type":["boolean","null"]},"exchange":{"type":["string","null"]},"scheduled_trigger_enabled":{"type":["boolean","null"]},"signal_pool_ids":{"items":{"format":"int32","type":"integer"},"type":["array","null"]},"trigger_interval":{"format":"int32","type":["integer","null"]}},"type":"object"},"StringListResponse":{"description":"Available factors / symbols catalogue.","properties":{"items":{"items":{"type":"string"},"type":"array"}},"required":["items"],"type":"object"},"SuccessFlagResponse":{"description":"`{ \"success\": bool, \"message\": \"...\" }` variant used by a handful of\nPython-parity handlers.","properties":{"message":{"type":["string","null"]},"success":{"type":"boolean"}},"required":["success"],"type":"object"},"SuccessResponse":{"description":"Generic success envelope for endpoints that don't return domain data\n(toggles, deletes, stub \"deferred to service layer\" handlers).","properties":{"message":{"description":"Optional human-readable note about what happened.","examples":["Operation completed"],"type":["string","null"]},"status":{"description":"Literal `\"success\"` on the happy path.","examples":["success"],"type":"string"}},"required":["status"],"type":"object"},"Suggestion":{"description":"Suggested follow-up prompt / action.","properties":{"category":{"type":["string","null"]},"id":{"type":"string"},"prompt":{"type":"string"},"title":{"type":"string"}},"required":["id","title","prompt"],"type":"object"},"SuggestionsResponse":{"description":"`GET /api/hyper-ai/suggestions` response.","properties":{"suggestions":{"items":{"$ref":"#/components/schemas/Suggestion"},"type":"array"}},"required":["suggestions"],"type":"object"},"SymbolOut":{"description":"Symbols catalogue entry.","properties":{"exchange":{"type":["string","null"]},"name":{"type":["string","null"]},"symbol":{"type":"string"}},"required":["symbol"],"type":"object"},"SymbolsResponse":{"description":"`GET /api/crypto/symbols` response.","properties":{"symbols":{"items":{"$ref":"#/components/schemas/SymbolOut"},"type":"array"}},"required":["symbols"],"type":"object"},"SystemLogOut":{"description":"System log entry.","properties":{"category":{"type":["string","null"]},"context":{"type":"object"},"id":{"format":"int64","type":"integer"},"level":{"type":"string"},"message":{"type":"string"},"timestamp":{"type":["string","null"]}},"required":["id","level","message","context"],"type":"object"},"SystemLogsResponse":{"description":"System log list with metadata.","properties":{"logs":{"items":{"$ref":"#/components/schemas/SystemLogOut"},"type":"array"},"total":{"format":"int64","type":"integer"}},"required":["logs","total"],"type":"object"},"TaskAcceptedResponse":{"description":"`{ \"task_id\": \"...\", \"status\": \"queued\" }` response from async-start endpoints.","properties":{"status":{"examples":["queued"],"type":"string"},"task_id":{"type":"string"}},"required":["task_id","status"],"type":"object"},"TestConnectionResponse":{"description":"Result of `POST /api/hyper-ai/test-connection`.","properties":{"latency_ms":{"format":"double","type":["number","null"]},"message":{"type":["string","null"]},"model":{"type":["string","null"]},"success":{"type":"boolean"}},"required":["success"],"type":"object"},"ToolConfigRequest":{"description":"Save tool config request.","properties":{"config":{"type":"object"},"tool_id":{"type":"string"}},"required":["tool_id","config"],"type":"object"},"ToolOut":{"description":"Tool entry.","properties":{"configured":{"type":"boolean"},"description":{"type":["string","null"]},"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name","configured"],"type":"object"},"ToolsListResponse":{"description":"Tools catalogue.","properties":{"tools":{"items":{"$ref":"#/components/schemas/ToolOut"},"type":"array"}},"required":["tools"],"type":"object"},"TradeKlineResponse":{"description":"K-line buckets around a specific trade.","properties":{"candles":{"items":{"type":"object"},"type":"array"},"period":{"type":"string"},"trade_id":{"format":"int32","type":"integer"}},"required":["trade_id","period","candles"],"type":"object"},"TradeReplayResponse":{"description":"Trade replay / tape entries for a single trade.","properties":{"events":{"items":{"type":"object"},"type":"array"},"trade_id":{"format":"int32","type":"integer"}},"required":["trade_id","events"],"type":"object"},"TradingStatsResponse":{"description":"Trading stats block.","properties":{"environment":{"type":"string"},"exchange":{"type":"string"},"period_days":{"format":"int32","type":["integer","null"]},"total_pnl":{"format":"double","type":"number"},"total_trades":{"format":"int64","type":"integer"},"total_volume":{"format":"double","type":"number"},"win_rate":{"format":"double","type":["number","null"]}},"required":["exchange","environment","total_trades","total_volume","total_pnl"],"type":"object"},"UserAuthResponse":{"properties":{"expires_at":{"type":"string"},"session_token":{"type":"string"},"user":{"$ref":"#/components/schemas/UserOut"}},"required":["user","session_token","expires_at"],"type":"object"},"UserCreate":{"properties":{"email":{"type":["string","null"]},"password":{"type":["string","null"]},"username":{"type":"string"}},"required":["username"],"type":"object"},"UserLogin":{"properties":{"password":{"type":"string"},"username":{"type":"string"}},"required":["username","password"],"type":"object"},"UserOut":{"properties":{"email":{"type":["string","null"]},"id":{"format":"int32","type":"integer"},"is_active":{"type":"boolean"},"username":{"type":"string"}},"required":["id","username","is_active"],"type":"object"},"UserUpdate":{"properties":{"email":{"type":["string","null"]},"username":{"type":["string","null"]}},"type":"object"},"WalletOut":{"description":"Generic wallet descriptor used by both Hyperliquid and Binance listings.","properties":{"account_id":{"format":"int32","type":"integer"},"default_leverage":{"format":"int32","type":["integer","null"]},"environment":{"type":"string"},"id":{"format":"int32","type":"integer"},"is_active":{"type":"boolean"},"key_type":{"type":["string","null"]},"max_leverage":{"format":"int32","type":["integer","null"]},"wallet_address":{"type":["string","null"]}},"required":["id","account_id","environment","is_active"],"type":"object"},"WalletTrackingStatusResponse":{"description":"Wallet-tracking status envelope.","properties":{"enabled":{"type":"boolean"},"last_sync_at":{"type":["string","null"]},"tracked_wallets":{"format":"int64","type":["integer","null"]}},"required":["enabled"],"type":"object"},"WalletsListResponse":{"description":"Response wrapping a list of exchange wallets.","properties":{"wallets":{"items":{"$ref":"#/components/schemas/WalletOut"},"type":"array"}},"required":["wallets"],"type":"object"},"WatchlistResponse":{"description":"Watchlist payload.","properties":{"exchange":{"type":"string"},"symbols":{"items":{"type":"string"},"type":"array"}},"required":["symbols","exchange"],"type":"object"}},"securitySchemes":{"bearer_auth":{"bearerFormat":"session_token","description":"Session token issued by `POST /api/users/login`, transported as `Authorization: Bearer <token>`.","scheme":"bearer","type":"http"},"session_token_query":{"description":"Legacy auth: same session token sent as `?session_token=…`. Prefer the `bearer_auth` scheme for new integrations.","in":"query","name":"session_token","type":"apiKey"}}},"externalDocs":{"description":"User-facing documentation","url":"https://docs.hyperoru.com"},"info":{"contact":{"name":"Hyperoru","url":"https://hyperoru.com"},"description":"AI-powered cryptocurrency perpetual contract trading platform.\n\n**Authentication**: most endpoints require a session token issued by `POST /api/users/login`. Send it either as `Authorization: Bearer <session_token>` (preferred) or as `?session_token=<token>` (legacy). Public endpoints (`/api/health`, static SPA routes) don't require auth.","license":{"identifier":"LicenseRef-Hyperoru","name":"Proprietary"},"title":"Hyperoru API","version":"0.0.1"},"openapi":"3.1.0","paths":{"/api/account/":{"post":{"operationId":"create_account","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountOut"}}},"description":"Create a new account"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/asset-curve":{"get":{"operationId":"asset_curve","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Get asset curve"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/asset-curve/timeframe":{"get":{"operationId":"asset_curve_timeframe","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Get asset curve by timeframe"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/dashboard-visibility":{"patch":{"operationId":"update_dashboard_visibility","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardVisibilityUpdate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Dashboard visibility updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Missing or invalid session token"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/hyperliquid/approve-builder":{"post":{"operationId":"approve_builder","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Builder approved"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/hyperliquid/check-builder-authorization":{"get":{"operationId":"check_builder_auth","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnabledFlagResponse"}}},"description":"Builder auth check"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/hyperliquid/check-mainnet-accounts":{"get":{"operationId":"check_mainnet_accounts","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Mainnet account check result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/list":{"get":{"operationId":"list_accounts","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/AccountOut"},"type":"array"}}},"description":"List all accounts"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/overview":{"get":{"operationId":"overview_default","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountOverview"}}},"description":"Default account overview"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Missing or invalid session token"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"No accounts configured"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/test-llm":{"post":{"operationId":"test_llm","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TestConnectionResponse"}}},"description":"LLM test result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/{account_id}":{"delete":{"operationId":"delete_account","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Account deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Missing or invalid session token"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Account not found"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]},"put":{"operationId":"update_account","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountUpdate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountOut"}}},"description":"Update an account"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/{account_id}/disable-trading":{"post":{"operationId":"accounts_disable_trading","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Trading disabled"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/{account_id}/overview":{"get":{"operationId":"get_account_overview","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountOut"}}},"description":"Get account overview"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/{account_id}/strategy":{"get":{"operationId":"get_strategy","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StrategyConfigOut"}}},"description":"Strategy config for account"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Missing or invalid session token"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Account not found"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]},"put":{"operationId":"update_strategy","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StrategyConfigUpdate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StrategyConfigOut"}}},"description":"Strategy config updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Missing or invalid session token"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/account/{account_id}/trigger-ai-trade":{"post":{"operationId":"trigger_ai_trade","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Trigger accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/accounts/{account_id}/default":{"get":{"operationId":"get_or_create_default","parameters":[{"description":"Account ID (ignored; kept for Python parity)","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountOut"}}},"description":"Existing or newly created default account"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"401":{"description":"Missing or invalid session token"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Accounts"]}},"/api/ai-stream/{task_id}":{"get":{"description":"Returns `{ task_id, status, chunks, done, error, next }` where `next` is\nthe index the client should pass back as `?since=` on the next poll.","operationId":"poll_task_chunks","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiStreamChunksResponse"}}},"description":"Stream task chunks (poll-style fallback for SSE)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"summary":"Poll incremental chunks for an in-flight AI stream task.","tags":["AI Stream"]}},"/api/ai-stream/{task_id}/status":{"get":{"operationId":"get_task_status","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiStreamTaskStatus"}}},"description":"Stream task status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["AI Stream"]}},"/api/analytics/ai-attribution/chat-stream":{"post":{"description":"The LLM dispatcher + streaming bridge are wired in Phase 2.3; until then\nthis endpoint emits a single acknowledgement event + terminator so the\nfrontend SSE reader gets a well-formed response and doesn't hang.","operationId":"ai_attribution_chat_stream","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiAttributionChatRequest"}}},"required":true},"responses":{"200":{"description":"SSE stream of assistant tokens"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"summary":"Server-Sent Events stream for AI attribution chat.","tags":["Analytics"]}},"/api/analytics/ai-attribution/conversations":{"get":{"operationId":"ai_attribution_conversations","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttributionConversationsResponse"}}},"description":"List AI attribution conversations"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/ai-attribution/conversations/{conversation_id}/messages":{"get":{"operationId":"ai_attribution_messages","parameters":[{"description":"Conversation ID","in":"path","name":"conversation_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessagesListResponse"}}},"description":"List messages in a conversation"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/by-account":{"get":{"operationId":"by_account","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Trades grouped by account"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/by-factor":{"get":{"operationId":"by_factor","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Trade performance grouped by factor attribution"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/by-operation":{"get":{"operationId":"by_operation","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Trades grouped by buy/sell side"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/by-strategy":{"get":{"operationId":"by_strategy","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Trades grouped by strategy"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/by-symbol":{"get":{"operationId":"by_symbol","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Trades grouped by symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/by-trigger-type":{"get":{"operationId":"by_trigger_type","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Trades grouped by trigger type"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/program-by-operation":{"get":{"operationId":"program_by_operation","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Program executions grouped by operation"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/program-by-program":{"get":{"operationId":"program_by_program","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Executions grouped by program id"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/program-by-symbol":{"get":{"operationId":"program_by_symbol","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Program executions grouped by symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/program-by-trigger-type":{"get":{"operationId":"program_by_trigger_type","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsGroupResponse"}}},"description":"Program executions grouped by trigger"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/program-summary":{"get":{"operationId":"program_summary","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramAnalyticsResponse"}}},"description":"Aggregate summary for trading programs"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/summary":{"get":{"operationId":"get_summary","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsSummaryResponse"}}},"description":"Aggregate summary across trades"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/trades":{"get":{"operationId":"trades_list","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsTradesListResponse"}}},"description":"List individual trades"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/trades/{trade_id}/kline":{"get":{"operationId":"trade_kline","parameters":[{"description":"Trade ID","in":"path","name":"trade_id","required":true,"schema":{"format":"int32","type":"integer"}},{"description":"K-line period (e.g. 5m, 1h)","in":"query","name":"period","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradeKlineResponse"}}},"description":"K-line data around trade time"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/analytics/trades/{trade_id}/replay":{"get":{"operationId":"trade_replay","parameters":[{"description":"Trade ID","in":"path","name":"trade_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradeReplayResponse"}}},"description":"Decision chain + trade details for replay"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Analytics"]}},"/api/arena/analytics":{"get":{"operationId":"arena_get_analytics","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsSummaryResponse"}}},"description":"Arena leaderboard analytics"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Arena"]}},"/api/arena/check-pnl-status":{"get":{"operationId":"check_pnl_status","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}},"description":"Arena PnL refresh status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Arena"]}},"/api/arena/model-chat":{"get":{"operationId":"get_model_chat","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicListResponse"}}},"description":"Model chat decisions feed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Arena"]}},"/api/arena/model-chat/{decision_id}/snapshots":{"get":{"operationId":"get_model_chat_snapshots","parameters":[{"description":"Decision ID","in":"path","name":"decision_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicListResponse"}}},"description":"Model chat decision snapshots"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Arena"]}},"/api/arena/positions":{"get":{"operationId":"get_positions_snapshot","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangePositionsResponse"}}},"description":"Arena positions snapshot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Arena"]}},"/api/arena/trades":{"get":{"operationId":"get_completed_trades","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnalyticsTradesListResponse"}}},"description":"Arena completed trades feed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Arena"]}},"/api/arena/update-pnl":{"post":{"operationId":"update_pnl","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskAcceptedResponse"}}},"description":"Arena PnL refresh triggered"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Arena"]}},"/api/backtests/":{"get":{"operationId":"list_backtests","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BacktestsListResponse"}}},"description":"Backtests list"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Backtests"]}},"/api/backtests/{id}":{"get":{"operationId":"get_backtest","parameters":[{"description":"Backtest ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BacktestDetailResponse"}}},"description":"Backtest detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Backtests"]}},"/api/binance/account-snapshot":{"get":{"operationId":"get_account_snapshot","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountSnapshotResponse"}}},"description":"Binance account snapshot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/balance":{"get":{"operationId":"binance_get_balance","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeBalanceResponse"}}},"description":"Balance snapshot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/close-position":{"post":{"operationId":"close_position","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Position closed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/config":{"get":{"operationId":"binance_get_config","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Binance account config"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/confirm-limited-binding":{"post":{"operationId":"confirm_limited_binding","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Binding confirmed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/daily-quota":{"get":{"operationId":"get_daily_quota","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Daily quota consumption"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/order":{"post":{"operationId":"place_order","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Order placement result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/positions":{"get":{"operationId":"binance_get_positions","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangePositionsResponse"}}},"description":"Binance positions snapshot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/rate-limit":{"get":{"operationId":"binance_get_rate_limit","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RateLimitResponse"}}},"description":"Rate-limit state"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/setup":{"post":{"operationId":"setup_wallet","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Wallet setup accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/summary":{"get":{"operationId":"binance_get_summary","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionSummaryResponse"}}},"description":"Account summary"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/trading-stats":{"get":{"operationId":"binance_get_trading_stats","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradingStatsResponse"}}},"description":"Trading statistics"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/accounts/{account_id}/wallet":{"delete":{"operationId":"binance_delete_wallet","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Wallet deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/check-rebate-eligibility":{"post":{"operationId":"check_rebate","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuccessFlagResponse"}}},"description":"Rebate eligibility check"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/price/{symbol}":{"get":{"operationId":"binance_get_price","parameters":[{"description":"Symbol","in":"path","name":"symbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceResponse"}}},"description":"Latest Binance price for a symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/symbols/available":{"get":{"operationId":"binance_list_available_symbols","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SymbolsResponse"}}},"description":"Symbols tradable on Binance"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/symbols/watchlist":{"get":{"operationId":"binance_get_watchlist","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WatchlistResponse"}}},"description":"Binance watchlist"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]},"put":{"operationId":"binance_update_watchlist","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Watchlist updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/binance/wallets":{"get":{"operationId":"binance_list_wallets","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WalletsListResponse"}}},"description":"Binance wallets list"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Binance"]}},"/api/bot/chat-bindings":{"get":{"operationId":"list_chat_bindings","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicListResponse"}}},"description":"Chat bindings per platform"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/config":{"post":{"operationId":"save_bot_config","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BotConfigOut"}}},"description":"Bot configuration saved"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/config/{platform}":{"delete":{"operationId":"delete_bot_config","parameters":[{"description":"Platform","in":"path","name":"platform","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Bot configuration deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]},"get":{"operationId":"get_bot_config","parameters":[{"description":"Platform","in":"path","name":"platform","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BotConfigOut"}}},"description":"Bot configuration for a platform"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/configs":{"get":{"operationId":"list_bot_configs","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BotConfigsResponse"}}},"description":"Bot configurations list"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/discord/connect":{"post":{"operationId":"discord_connect","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Discord bot linked"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/discord/disconnect":{"post":{"operationId":"discord_disconnect","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Discord bot disconnected"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/discord/status":{"get":{"operationId":"discord_status","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}},"description":"Discord bot status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/notification-config":{"get":{"operationId":"get_notification_config","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationConfigResponse"}}},"description":"Notification configuration"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]},"put":{"operationId":"update_notification_config","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationConfigResponse"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationConfigResponse"}}},"description":"Notification config updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/status":{"put":{"operationId":"update_bot_status","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuccessFlagResponse"}}},"description":"Bot enabled flag updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/telegram/connect":{"post":{"operationId":"telegram_connect","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Telegram webhook registered"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/telegram/disconnect":{"post":{"operationId":"telegram_disconnect","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Telegram webhook removed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/telegram/retry-webhook":{"post":{"operationId":"telegram_retry","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Telegram webhook retry"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/bot/telegram/webhook":{"post":{"operationId":"telegram_webhook","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Telegram inbound webhook accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Bots"]}},"/api/config/check-required":{"get":{"operationId":"check_required_configs","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StringListResponse"}}},"description":"Missing-config report"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Config"]}},"/api/config/global-sampling":{"get":{"operationId":"get_global_sampling","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplingConfigOut"}}},"description":"Get global sampling config"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Config"]},"put":{"operationId":"update_global_sampling","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplingConfigUpdate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplingConfigOut"}}},"description":"Update global sampling config"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Config"]}},"/api/config/{key}":{"put":{"operationId":"update_system_config","parameters":[{"description":"Config key","in":"path","name":"key","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigValueRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Config saved"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Config"]}},"/api/crypto/popular":{"get":{"operationId":"get_popular","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SymbolsResponse"}}},"description":"Popular symbols"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Crypto"]}},"/api/crypto/price/{symbol}":{"get":{"operationId":"crypto_get_price","parameters":[{"description":"Symbol name","in":"path","name":"symbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceResponse"}}},"description":"Current price for symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Crypto"]}},"/api/crypto/status/{symbol}":{"get":{"operationId":"get_market_status","parameters":[{"description":"Symbol name","in":"path","name":"symbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketStatusResponse"}}},"description":"Market status for symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Crypto"]}},"/api/crypto/symbols":{"get":{"operationId":"get_symbols","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SymbolsResponse"}}},"description":"Available symbols"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Crypto"]}},"/api/factors/compute":{"post":{"operationId":"trigger_compute","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskAcceptedResponse"}}},"description":"Factor compute job queued"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/compute/estimate":{"get":{"operationId":"compute_estimate","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Estimated compute cost/time"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/compute/progress":{"get":{"operationId":"compute_progress","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}},"description":"Current compute job progress"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/custom":{"get":{"operationId":"list_custom_factors","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorsListResponse"}}},"description":"Custom factor definitions"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]},"post":{"operationId":"create_custom_factor","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorExpressionRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorDefinition"}}},"description":"Custom factor created"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/custom/{factor_id}":{"delete":{"operationId":"delete_custom_factor","parameters":[{"description":"Factor ID","in":"path","name":"factor_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Custom factor deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]},"put":{"operationId":"edit_custom_factor","parameters":[{"description":"Factor ID","in":"path","name":"factor_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorExpressionRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorDefinition"}}},"description":"Custom factor updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/effectiveness":{"get":{"operationId":"list_effectiveness","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorEffectivenessResponse"}}},"description":"Factor effectiveness metrics"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/effectiveness/{factor_name}/by-window":{"get":{"operationId":"effectiveness_by_window","parameters":[{"description":"Factor name","in":"path","name":"factor_name","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorEffectivenessResponse"}}},"description":"Effectiveness broken down by time window"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/effectiveness/{factor_name}/history":{"get":{"operationId":"effectiveness_history","parameters":[{"description":"Factor name","in":"path","name":"factor_name","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorEffectivenessResponse"}}},"description":"Historical effectiveness for factor"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/evaluate":{"post":{"operationId":"evaluate_expression","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorExpressionRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorExpressionResult"}}},"description":"Expression evaluation result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/expression-functions":{"get":{"operationId":"list_expression_functions","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StringListResponse"}}},"description":"Available expression functions reference"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/library":{"get":{"operationId":"get_library","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorsListResponse"}}},"description":"Factor library (built-in + custom)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/status":{"get":{"operationId":"get_status","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}},"description":"Factor pipeline status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/validate-expression":{"post":{"operationId":"validate_expression","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorExpressionRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorExpressionResult"}}},"description":"Expression validation result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/factors/values":{"get":{"operationId":"get_values","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Latest factor values snapshot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Factors"]}},"/api/health":{"get":{"description":"Returns `{\"status\":\"ok\"}` whenever the process is responsive. Used by\nload balancers and orchestrators for liveness probes; does not perform\ndeep dependency checks.","operationId":"health_check","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthResponse"}}},"description":"Service is healthy"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"security":[],"summary":"Service health check.","tags":["Health"]}},"/api/hyper-ai/chat":{"post":{"description":"The client POSTs `{ \"message\": \"...\", \"conversation_id\"?: <id> }` and\nreceives SSE frames:\n\n- `event: status` — one up-front frame with the resolved `conversation_id`\n- `event: token`  — zero or more incremental text chunks\n- `event: error`  — on failure\n- `event: done`   — terminal frame (`[DONE]`)\n\nMirrors the Python `POST /api/hyper-ai/chat` SSE contract so the existing\nReact client can consume it unchanged. Provider streaming is handled by\n[`crate::services::ai_shared_tools::stream_llm`], which falls back to\nbuffered output for providers without native SSE.","operationId":"hyper_ai_start_chat","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartChatRequest"}}},"required":true},"responses":{"200":{"content":{"text/event-stream":{}},"description":"Server-Sent Events stream. The stream emits one of four event kinds: `event: status` (handshake + keepalives), `event: token` (incremental text chunks), `event: tool_call` (tool call metadata the agent invoked), `event: done` (final marker), or `event: error` (stream failed). Each event's `data:` line is a JSON object."},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Missing or invalid session token"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"summary":"Server-sent events stream for a Hyper AI chat turn.","tags":["HyperAI"]}},"/api/hyper-ai/confirm-tool":{"post":{"description":"Mirrors Python `POST /api/hyper-ai/confirm-tool`\n(`backend/api/hyper_ai_routes.py::confirm_tool`). When the Hyper AI worker\nencounters a tool that requires user approval it registers a pending\nconfirmation on the `HyperAiConfirmationManager`; this route resolves it so\nthe worker can resume execution.","operationId":"confirm_tool","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmToolRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Confirmation accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"404":{"description":"No matching pending confirmation"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"summary":"Submit a runtime checkpoint response for a pending Hyper AI tool call.","tags":["HyperAI"]}},"/api/hyper-ai/conversations":{"get":{"operationId":"list_conversations","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConversationsListResponse"}}},"description":"Conversation summaries for the authenticated user"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]},"post":{"operationId":"create_conversation","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartChatRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConversationSummary"}}},"description":"New conversation created"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/conversations/{id}/messages":{"get":{"operationId":"hyper_ai_get_conversation_messages","parameters":[{"description":"Conversation ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessagesListResponse"}}},"description":"Ordered messages for a conversation"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/insight":{"post":{"operationId":"start_insight","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartInsightRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsightTaskResponse"}}},"description":"Insight task accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/memories":{"get":{"operationId":"list_memories","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MemoriesListResponse"}}},"description":"Stored long-term memories"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/memories/{memory_id}":{"delete":{"operationId":"delete_memory","parameters":[{"description":"Memory ID","in":"path","name":"memory_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Memory deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/profile":{"get":{"operationId":"hyper_ai_get_profile","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileResponse"}}},"description":"HyperAI profile + preferences"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/profile/llm":{"post":{"operationId":"save_llm_config","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveLlmConfigRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"LLM configuration saved"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/profile/preferences":{"post":{"operationId":"save_preferences","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreferencesRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Preferences saved"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/providers":{"get":{"operationId":"list_providers","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProvidersListResponse"}}},"description":"Configured LLM providers"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/skills":{"get":{"operationId":"list_skills","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SkillsListResponse"}}},"description":"Available skills"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/skills/{skill_name}/toggle":{"put":{"operationId":"toggle_skill","parameters":[{"description":"Skill name","in":"path","name":"skill_name","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreferencesRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Skill toggled"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/suggestions":{"get":{"operationId":"get_suggestions","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestionsResponse"}}},"description":"Suggested prompts / actions"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/test-connection":{"post":{"operationId":"hyper_ai_test_connection","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveLlmConfigRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TestConnectionResponse"}}},"description":"Connection test result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/tools":{"get":{"operationId":"list_tools","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ToolsListResponse"}}},"description":"Available tools"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyper-ai/tools/{tool_name}/config":{"delete":{"operationId":"delete_tool_config","parameters":[{"description":"Tool name","in":"path","name":"tool_name","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Tool configuration removed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]},"put":{"operationId":"save_tool_config","parameters":[{"description":"Tool name","in":"path","name":"tool_name","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ToolConfigRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Tool configuration saved"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["HyperAI"]}},"/api/hyperliquid/account/{account_id}/state":{"get":{"operationId":"get_account_state","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountSnapshotResponse"}}},"description":"Hyperliquid account state"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/balance":{"get":{"operationId":"hyperliquid_get_balance","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeBalanceResponse"}}},"description":"Balance snapshot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/config":{"get":{"operationId":"hyperliquid_get_config","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Hyperliquid account config"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/disable":{"post":{"operationId":"hyperliquid_disable_trading","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Trading disabled"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/enable":{"post":{"operationId":"enable_trading","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Trading enabled"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/orders/manual":{"post":{"operationId":"place_manual_order","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Manual order placement result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/positions":{"get":{"operationId":"get_account_positions","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangePositionsResponse"}}},"description":"Open/closed positions for this account"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/rate-limit":{"get":{"operationId":"hyperliquid_get_rate_limit","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RateLimitResponse"}}},"description":"Rate-limit state"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/setup":{"post":{"operationId":"setup_account","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Account setup accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/snapshots":{"get":{"operationId":"get_snapshots","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicListResponse"}}},"description":"Account snapshot history"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/switch-environment":{"post":{"operationId":"switch_environment","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Environment switched"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/test-connection":{"get":{"operationId":"hyperliquid_test_connection","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TestConnectionResponse"}}},"description":"Exchange connectivity probe"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/trading-stats":{"get":{"operationId":"hyperliquid_get_trading_stats","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradingStatsResponse"}}},"description":"Trading statistics"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/wallet":{"delete":{"operationId":"hyperliquid_delete_wallet","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Wallet deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]},"get":{"operationId":"get_wallet","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WalletOut"}}},"description":"Wallet details"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]},"post":{"operationId":"configure_wallet","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Wallet configured"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/wallet/agent":{"post":{"operationId":"configure_agent","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Agent configured"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/wallet/agent-status":{"get":{"operationId":"agent_status","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Agent wallet status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/wallet/test":{"post":{"operationId":"test_wallet","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TestConnectionResponse"}}},"description":"Wallet connectivity test"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/accounts/{account_id}/wallet/upgrade-to-agent":{"post":{"operationId":"upgrade_to_agent","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Wallet upgraded to agent"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/actions/":{"get":{"operationId":"list_exchange_actions","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionSummaryResponse"}}},"description":"Hyperliquid exchange actions log"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/actions/summary":{"get":{"operationId":"get_action_summary","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionSummaryResponse"}}},"description":"Exchange action summary"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/health":{"get":{"operationId":"hyperliquid_health_check","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeHealthResponse"}}},"description":"Integration health check"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/positions":{"get":{"operationId":"hyperliquid_get_positions","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangePositionsResponse"}}},"description":"Hyperliquid positions snapshot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/symbols/available":{"get":{"operationId":"hyperliquid_list_available_symbols","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SymbolsResponse"}}},"description":"Symbols tradable on Hyperliquid"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/symbols/watchlist":{"get":{"operationId":"hyperliquid_get_watchlist","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WatchlistResponse"}}},"description":"Hyperliquid watchlist"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]},"put":{"operationId":"hyperliquid_update_watchlist","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Watchlist updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/trading-mode":{"get":{"operationId":"get_trading_mode","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}},"description":"Current trading mode"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]},"post":{"operationId":"set_trading_mode","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Trading mode updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/wallet-upgrade-check":{"get":{"operationId":"wallet_upgrade_check","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Pending wallet upgrade status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/hyperliquid/wallets":{"get":{"operationId":"hyperliquid_list_wallets","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WalletsListResponse"}}},"description":"Hyperliquid wallets list"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Hyperliquid"]}},"/api/klines/ai-analysis":{"post":{"operationId":"create_ai_analysis","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskAcceptedResponse"}}},"description":"AI kline analysis accepted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Kline Analysis"]}},"/api/klines/ai-analysis/history":{"get":{"operationId":"get_analysis_history","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/KlineAnalysisHistoryResponse"}}},"description":"Kline analysis history"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Kline Analysis"]}},"/api/klines/ai-analysis/{analysis_id}":{"get":{"operationId":"get_analysis_detail","parameters":[{"description":"Analysis ID","in":"path","name":"analysis_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/KlineAnalysisDetail"}}},"description":"Kline analysis detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Kline Analysis"]}},"/api/klines/backfill":{"post":{"operationId":"create_backfill","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBackfillRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackfillTaskOut"}}},"description":"Backfill task created"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Klines"]}},"/api/klines/backfill-tasks":{"get":{"operationId":"list_backfill_tasks","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackfillTasksResponse"}}},"description":"Kline backfill tasks"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Klines"]}},"/api/klines/backfill-tasks/{task_id}":{"delete":{"operationId":"delete_backfill_task","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Backfill task deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Klines"]}},"/api/klines/backfill/status/{task_id}":{"get":{"operationId":"get_backfill_status","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackfillTaskOut"}}},"description":"Backfill task status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Klines"]}},"/api/klines/coverage":{"get":{"operationId":"get_coverage","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CoverageResponse"}}},"description":"Kline coverage per symbol/interval"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Klines"]}},"/api/klines/data":{"get":{"operationId":"get_kline_data","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/KlineResponse"}}},"description":"Kline candles"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Klines"]}},"/api/klines/gaps/{symbol}":{"get":{"operationId":"detect_data_gaps","parameters":[{"description":"Symbol name","in":"path","name":"symbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DataGapsResponse"}}},"description":"Kline data gaps for symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Klines"]}},"/api/klines/supported-symbols":{"get":{"operationId":"get_supported_symbols","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SymbolsResponse"}}},"description":"Supported kline symbols"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Klines"]}},"/api/market-flow/indicators":{"get":{"operationId":"get_indicators","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketFlowIndicatorsResponse"}}},"description":"Market flow indicators"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Flow"]}},"/api/market-flow/large-order-zones":{"get":{"operationId":"get_large_order_zones","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicListResponse"}}},"description":"Large order zones on order book"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Flow"]}},"/api/market-flow/summary":{"get":{"operationId":"market_flow_get_summary","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Market flow summary"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Flow"]}},"/api/market-intelligence/stream":{"get":{"operationId":"stream_market_intelligence","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"SSE stream of market intelligence events (event: update / error)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Intelligence"]}},"/api/market-regime/batch":{"post":{"operationId":"get_regime_batch","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketRegimeBatchResponse"}}},"description":"Market regime for multiple symbols"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Regime"]}},"/api/market-regime/configs/list":{"get":{"operationId":"list_regime_configs","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketRegimeConfigsResponse"}}},"description":"Market regime configurations"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Regime"]}},"/api/market-regime/configs/{config_id}":{"put":{"operationId":"update_regime_config","parameters":[{"description":"Config ID","in":"path","name":"config_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketRegimeConfigOut"}}},"description":"Regime config updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Regime"]}},"/api/market-regime/{symbol}":{"get":{"operationId":"get_regime_for_symbol","parameters":[{"description":"Symbol name","in":"path","name":"symbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketRegimeResponse"}}},"description":"Market regime for symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Regime"]}},"/api/market/health":{"get":{"operationId":"market_health","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeHealthResponse"}}},"description":"Market data health"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Data"]}},"/api/market/indicators/available":{"get":{"operationId":"get_available_indicators","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndicatorsListResponse"}}},"description":"Available indicators catalog"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Data"]}},"/api/market/kline-with-indicators/{symbol}":{"get":{"operationId":"get_kline_with_indicators","parameters":[{"description":"Symbol name","in":"path","name":"symbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/KlineIndicatorsResponse"}}},"description":"Kline candles + computed indicators"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Data"]}},"/api/market/kline/{symbol}":{"get":{"operationId":"get_kline","parameters":[{"description":"Symbol name","in":"path","name":"symbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/KlineResponse"}}},"description":"Kline candles for symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Data"]}},"/api/market/prices":{"get":{"operationId":"get_multiple_prices","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MultiplePricesResponse"}}},"description":"Current prices for multiple symbols"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Market Data"]}},"/api/news/articles":{"get":{"operationId":"list_articles","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsListResponse"}}},"description":"News articles feed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["News"]}},"/api/news/sources":{"get":{"operationId":"get_sources","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsSourcesResponse"}}},"description":"News sources"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["News"]},"put":{"operationId":"update_sources","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsSourcesResponse"}}},"description":"News sources updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["News"]}},"/api/news/sources/test":{"post":{"operationId":"test_source","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeHealthResponse"}}},"description":"News source connectivity test"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["News"]}},"/api/news/stats":{"get":{"operationId":"get_stats","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsStatsResponse"}}},"description":"News statistics"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["News"]}},"/api/orders/account/{account_id}":{"get":{"operationId":"list_account_orders","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/OrderOut"},"type":"array"}}},"description":"List orders for account"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Orders"]}},"/api/orders/cancel/{order_id}":{"post":{"operationId":"cancel_order","parameters":[{"description":"Order ID","in":"path","name":"order_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Order cancelled"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Orders"]}},"/api/orders/create":{"post":{"operationId":"create_order","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCreateRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderOut"}}},"description":"Create an order"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Orders"]}},"/api/orders/execute/{order_id}":{"post":{"operationId":"execute_order","parameters":[{"description":"Order ID","in":"path","name":"order_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderExecutionResult"}}},"description":"Order execution result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Orders"]}},"/api/orders/health":{"get":{"operationId":"orders_health","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}},"description":"Orders subsystem health"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Orders"]}},"/api/orders/order/{order_id}":{"get":{"operationId":"get_order_details","parameters":[{"description":"Order ID","in":"path","name":"order_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderOut"}}},"description":"Get order details"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Orders"]}},"/api/orders/pending":{"get":{"operationId":"get_pending_orders","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/OrderOut"},"type":"array"}}},"description":"Get pending orders"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Orders"]}},"/api/orders/process-all":{"post":{"operationId":"process_all","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderProcessingResult"}}},"description":"Batch processing result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Orders"]}},"/api/programs/":{"get":{"operationId":"list_programs","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramsListResponse"}}},"description":"Trading programs list"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]},"post":{"operationId":"create_program","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramOut"}}},"description":"Program created"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/accounts/":{"get":{"operationId":"list_accounts_for_programs","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicListResponse"}}},"description":"AI trader accounts available for binding"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/ai-chat":{"post":{"operationId":"programs_ai_chat","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartChatRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatMessage"}}},"description":"AI chat response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/ai-conversations":{"get":{"operationId":"programs_list_ai_conversations","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConversationsListResponse"}}},"description":"Programs AI conversations"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/ai-conversations/{conversation_id}/messages":{"get":{"operationId":"programs_get_ai_conversation_messages","parameters":[{"description":"Conversation ID","in":"path","name":"conversation_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessagesListResponse"}}},"description":"Conversation messages feed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/available-symbols":{"get":{"operationId":"programs_get_available_symbols","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SymbolsResponse"}}},"description":"Symbols supported by the programs runtime"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/backtest":{"post":{"operationId":"run_backtest","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BacktestDetailResponse"}}},"description":"Backtest accepted / result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/backtest/history":{"get":{"operationId":"backtest_history","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BacktestsListResponse"}}},"description":"Historical backtests"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/backtest/trigger/{trigger_id}":{"get":{"operationId":"get_trigger_detail","parameters":[{"description":"Trigger ID","in":"path","name":"trigger_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BacktestTrigger"}}},"description":"Backtest trigger detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/backtest/{backtest_id}":{"get":{"operationId":"get_backtest_result","parameters":[{"description":"Backtest ID","in":"path","name":"backtest_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BacktestDetailResponse"}}},"description":"Backtest detail + metrics"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/backtest/{backtest_id}/markers":{"get":{"operationId":"get_backtest_markers","parameters":[{"description":"Backtest ID","in":"path","name":"backtest_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BacktestMarkersResponse"}}},"description":"Backtest chart markers"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/backtest/{backtest_id}/triggers":{"get":{"operationId":"get_backtest_triggers","parameters":[{"description":"Backtest ID","in":"path","name":"backtest_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BacktestTriggersResponse"}}},"description":"Backtest triggers on the chart"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/bindings/":{"get":{"operationId":"programs_list_bindings","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramBindingsResponse"}}},"description":"Program bindings list"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]},"post":{"operationId":"create_binding","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramBindingOut"}}},"description":"Binding created"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/bindings/{binding_id}":{"delete":{"operationId":"programs_delete_binding","parameters":[{"description":"Binding ID","in":"path","name":"binding_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Binding deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]},"put":{"operationId":"update_binding","parameters":[{"description":"Binding ID","in":"path","name":"binding_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramBindingOut"}}},"description":"Binding updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/bindings/{binding_id}/preview-run":{"post":{"operationId":"preview_run","parameters":[{"description":"Binding ID","in":"path","name":"binding_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Preview run of a binding"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/dev-guide":{"get":{"description":"Hyperoru ships English-only documentation by policy. If a caller passes\n`?lang=` with anything other than `en` we return 400 to make the\nexclusion observable rather than silently defaulting.","operationId":"dev_guide","parameters":[{"description":"Language code. Only `en` is supported; any other value returns 400.","in":"query","name":"lang","required":false,"schema":{"type":["string","null"]}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DevGuideResponse"}}},"description":"Program developer guide (Markdown)"},"400":{"description":"Unsupported language"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"summary":"Return the program developer guide.","tags":["Programs"]}},"/api/programs/executions/":{"get":{"operationId":"list_executions","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramExecutionsResponse"}}},"description":"Program execution history"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/query-market-data":{"post":{"operationId":"query_market_data","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MultiplePricesRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Ad-hoc market data query"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/signal-pools/":{"get":{"operationId":"list_signal_pools","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalListResponse"}}},"description":"Signal pools visible to programs"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/test-run":{"post":{"operationId":"test_run","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Test-run output"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/validate":{"post":{"operationId":"validate_code","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramValidationResponse"}}},"description":"Code validation result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/programs/{id}":{"delete":{"operationId":"delete_program","parameters":[{"description":"Program ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Program deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]},"get":{"operationId":"get_program","parameters":[{"description":"Program ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramOut"}}},"description":"Program detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]},"put":{"operationId":"update_program","parameters":[{"description":"Program ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramOut"}}},"description":"Program updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Programs"]}},"/api/prompt-backtest/items/{item_id}":{"get":{"operationId":"get_item_detail","parameters":[{"description":"Item ID","in":"path","name":"item_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptBacktestResultRow"}}},"description":"Individual backtest item"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompt Backtest"]}},"/api/prompt-backtest/tasks":{"get":{"operationId":"list_tasks","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptBacktestTasksResponse"}}},"description":"Prompt backtest tasks list"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompt Backtest"]},"post":{"operationId":"create_task","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptBacktestTaskOut"}}},"description":"Task created - poll for progress"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompt Backtest"]}},"/api/prompt-backtest/tasks/{task_id}":{"delete":{"operationId":"delete_task","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Task deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompt Backtest"]},"get":{"operationId":"get_task","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptBacktestTaskOut"}}},"description":"Prompt backtest task detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompt Backtest"]}},"/api/prompt-backtest/tasks/{task_id}/items":{"get":{"operationId":"get_task_items","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptBacktestResultsResponse"}}},"description":"Task items list (paginated)"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompt Backtest"]}},"/api/prompt-backtest/tasks/{task_id}/results":{"get":{"operationId":"get_task_results","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptBacktestResultsResponse"}}},"description":"Aggregate task results"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompt Backtest"]}},"/api/prompt-backtest/tasks/{task_id}/retry":{"post":{"operationId":"retry_failed","parameters":[{"description":"Task ID","in":"path","name":"task_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Retry triggered"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompt Backtest"]}},"/api/prompts/":{"get":{"operationId":"list_prompts","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptListResponse"}}},"description":"List all prompts"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]},"post":{"operationId":"create_template","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTemplateCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTemplateOut"}}},"description":"Create prompt template"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/ai-chat":{"post":{"operationId":"prompts_ai_chat","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartChatRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatMessage"}}},"description":"AI chat response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/ai-chat-stream":{"post":{"description":"Mirrors Python `POST /api/prompts/ai-chat-stream`: queues the work on the\nshared `AiStreamService`, returns `{task_id}` immediately, and the\nfrontend polls `/api/ai-stream/{task_id}` for incremental chunks.","operationId":"ai_chat_stream","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartChatRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskAcceptedResponse"}}},"description":"Stream task accepted - poll /api/ai-stream"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"summary":"Submit a prompt-authoring chat turn for asynchronous streaming.","tags":["Prompts"]}},"/api/prompts/ai-conversations":{"get":{"operationId":"prompts_list_ai_conversations","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConversationsListResponse"}}},"description":"Prompt AI conversations"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/ai-conversations/{conversation_id}/messages":{"get":{"operationId":"prompts_get_conversation_messages","parameters":[{"description":"Conversation ID","in":"path","name":"conversation_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessagesListResponse"}}},"description":"Conversation messages feed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/bindings":{"get":{"operationId":"prompts_list_bindings","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramBindingsResponse"}}},"description":"Prompt bindings list"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]},"post":{"operationId":"upsert_binding","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptBindingUpsert"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptBindingOut"}}},"description":"Upsert prompt binding"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/bindings/{id}":{"delete":{"operationId":"prompts_delete_binding","parameters":[{"description":"Binding ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Binding deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/preview":{"post":{"operationId":"preview_prompt","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Rendered prompt preview"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/variables-reference":{"get":{"description":"English-only by policy. A `?lang=` that isn't `en` returns 400 so the\nboundary is visible to clients instead of silently defaulting.","operationId":"variables_reference","parameters":[{"description":"Language code. Only `en` is supported; any other value returns 400.","in":"query","name":"lang","required":false,"schema":{"type":["string","null"]}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DevGuideResponse"}}},"description":"Template variables reference (Markdown)"},"400":{"description":"Unsupported language"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"summary":"Return the prompt-variables reference.","tags":["Prompts"]}},"/api/prompts/{id}":{"delete":{"operationId":"delete_template","parameters":[{"description":"Template ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Template deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]},"get":{"operationId":"get_template","parameters":[{"description":"Template ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTemplateOut"}}},"description":"Get prompt template"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]},"put":{"operationId":"update_template","parameters":[{"description":"Template ID","in":"path","name":"id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTemplateUpdateRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTemplateOut"}}},"description":"Update prompt template"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/{template_id}/copy":{"post":{"operationId":"copy_template","parameters":[{"description":"Template ID","in":"path","name":"template_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTemplateOut"}}},"description":"Template copied"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/prompts/{template_id}/name":{"patch":{"operationId":"rename_template","parameters":[{"description":"Template ID","in":"path","name":"template_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTemplateUpdateRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTemplateOut"}}},"description":"Template renamed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Prompts"]}},"/api/ranking/factors":{"get":{"operationId":"get_available_factors","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FactorsListResponse"}}},"description":"Available ranking factors"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Ranking"]}},"/api/ranking/symbols":{"get":{"operationId":"ranking_get_available_symbols","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SymbolsResponse"}}},"description":"Available ranking symbols"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Ranking"]}},"/api/ranking/table":{"get":{"operationId":"get_ranking_table","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RankingResponse"}}},"description":"Ranked table of symbols by factors"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Ranking"]}},"/api/sampling/pool-details":{"get":{"operationId":"pool_details","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplingPoolDetail"}}},"description":"Sampling pool detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Sampling"]}},"/api/sampling/pool-status":{"get":{"operationId":"pool_status","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplingPoolListResponse"}}},"description":"Sampling pool status per symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Sampling"]}},"/api/signals/":{"get":{"operationId":"list_signals","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalListResponse"}}},"description":"Signal definitions + pools in one payload"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/ai-chat":{"post":{"operationId":"ai_signal_chat","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartChatRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatMessage"}}},"description":"Agent response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/ai-chat-stream":{"post":{"description":"Mirrors Python `POST /api/signals/ai-chat-stream`: queues the work on the\nshared `AiStreamService`, returns `{task_id}` immediately, and the\nfrontend polls `/api/ai-stream/{task_id}` for incremental chunks.","operationId":"ai_signal_chat_stream","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartChatRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskAcceptedResponse"}}},"description":"Stream task accepted - poll /api/ai-stream"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"summary":"Submit an AI signal-explanation chat turn for asynchronous streaming.","tags":["Signals"]}},"/api/signals/ai-conversations":{"get":{"operationId":"signals_list_ai_conversations","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConversationsListResponse"}}},"description":"Signals AI conversations"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/ai-conversations/{conversation_id}/messages":{"get":{"operationId":"signals_get_ai_conversation_messages","parameters":[{"description":"Conversation ID","in":"path","name":"conversation_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessagesListResponse"}}},"description":"Signals AI conversation messages"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/analyze":{"get":{"operationId":"analyze_metric","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Signal metric analysis"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/backtest-preview":{"post":{"operationId":"backtest_preview","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalDefinitionCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalBacktestResponse"}}},"description":"Preview backtest result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/backtest/{signal_id}":{"get":{"operationId":"backtest_signal","parameters":[{"description":"Signal ID","in":"path","name":"signal_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalBacktestResponse"}}},"description":"Signal backtest summary"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/create-pool-from-config":{"post":{"operationId":"create_pool_from_config","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalPoolCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalPoolResponse"}}},"description":"Pool imported from config"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/definitions":{"post":{"operationId":"create_signal","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalDefinitionCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalDefinitionResponse"}}},"description":"Signal created"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/definitions/{signal_id}":{"delete":{"operationId":"delete_signal","parameters":[{"description":"Signal ID","in":"path","name":"signal_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Signal deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]},"get":{"operationId":"get_signal","parameters":[{"description":"Signal ID","in":"path","name":"signal_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalDefinitionResponse"}}},"description":"Signal definition detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]},"put":{"operationId":"update_signal","parameters":[{"description":"Signal ID","in":"path","name":"signal_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalDefinitionUpdate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalDefinitionResponse"}}},"description":"Signal updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/pool-backtest/{pool_id}":{"get":{"operationId":"backtest_pool","parameters":[{"description":"Pool ID","in":"path","name":"pool_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalBacktestResponse"}}},"description":"Pool backtest summary"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/pools":{"post":{"operationId":"create_pool","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalPoolCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalPoolResponse"}}},"description":"Pool created"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/pools/{pool_id}":{"delete":{"operationId":"delete_pool","parameters":[{"description":"Pool ID","in":"path","name":"pool_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Pool deleted"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]},"get":{"operationId":"get_pool","parameters":[{"description":"Pool ID","in":"path","name":"pool_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalPoolResponse"}}},"description":"Signal pool detail"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]},"put":{"operationId":"update_pool","parameters":[{"description":"Pool ID","in":"path","name":"pool_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalPoolUpdate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalPoolResponse"}}},"description":"Pool updated"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/states":{"get":{"operationId":"get_signal_states","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalStatesResponse"}}},"description":"Runtime state per signal x symbol"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/states/reset":{"post":{"operationId":"reset_signal_states","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Signal states reset"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/test/{signal_id}":{"get":{"operationId":"test_signal","parameters":[{"description":"Signal ID","in":"path","name":"signal_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Signal test result"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/trigger-logs":{"get":{"operationId":"list_trigger_logs","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalTriggerLogsResponse"}}},"description":"Signal trigger log entries"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/wallet-tracking/runtime":{"put":{"operationId":"wallet_tracking_runtime","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WalletTrackingStatusResponse"}}},"description":"Wallet tracking runtime snapshot"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/wallet-tracking/status":{"get":{"operationId":"wallet_tracking_status","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WalletTrackingStatusResponse"}}},"description":"Wallet tracking status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/signals/wallet-tracking/token":{"delete":{"operationId":"wallet_tracking_clear_token","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Tracking token cleared"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]},"post":{"operationId":"wallet_tracking_sync_token","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Tracking token synced"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Signals"]}},"/api/system-logs/":{"delete":{"operationId":"clear_system_logs","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"System logs cleared"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System Logs"]},"get":{"operationId":"get_system_logs","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SystemLogsResponse"}}},"description":"System log entries"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System Logs"]}},"/api/system-logs/categories":{"get":{"operationId":"get_log_categories","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LogCategoriesResponse"}}},"description":"Distinct log categories"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System Logs"]}},"/api/system-logs/stats":{"get":{"operationId":"get_log_stats","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LogStatsResponse"}}},"description":"Log statistics by level/category"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System Logs"]}},"/api/system/binance/backfill":{"post":{"operationId":"start_binance_backfill","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackfillStartResponse"}}},"description":"Binance backfill job started"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]}},"/api/system/binance/backfill/status":{"get":{"operationId":"get_binance_backfill_status","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackfillStatusResponse"}}},"description":"Binance backfill status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]}},"/api/system/collection-days":{"get":{"operationId":"get_collection_days","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionDaysResponse"}}},"description":"Collection days per data source"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]}},"/api/system/data-coverage":{"get":{"operationId":"get_data_coverage","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DataCoverageResponse"}}},"description":"Data coverage summary"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]}},"/api/system/hyperliquid/backfill":{"post":{"operationId":"start_hyperliquid_backfill","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackfillStartResponse"}}},"description":"Hyperliquid backfill job started"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]}},"/api/system/hyperliquid/backfill/status":{"get":{"operationId":"get_hyperliquid_backfill_status","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackfillStatusResponse"}}},"description":"Hyperliquid backfill status"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]}},"/api/system/retention-days":{"get":{"operationId":"get_retention_days","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetentionDaysResponse"}}},"description":"Get retention days"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]},"put":{"operationId":"update_retention_days","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetentionDaysRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetentionDaysResponse"}}},"description":"Update retention days"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]}},"/api/system/storage-stats":{"get":{"operationId":"get_storage_stats","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageStatsResponse"}}},"description":"Storage usage statistics"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["System"]}},"/api/trader/{account_id}/export":{"get":{"operationId":"export_trader_data","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Trader data export bundle"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Trader Data"]}},"/api/trader/{account_id}/import/execute":{"post":{"operationId":"execute_import","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Import executed"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Trader Data"]}},"/api/trader/{account_id}/import/preview":{"post":{"operationId":"preview_import","parameters":[{"description":"Account ID","in":"path","name":"account_id","required":true,"schema":{"format":"int32","type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"description":"Import preview summary"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Trader Data"]}},"/api/users/":{"get":{"operationId":"list_users","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/UserOut"},"type":"array"}}},"description":"List all active users"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]}},"/api/users/clear-membership":{"post":{"operationId":"clear_membership","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Membership cleared"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]}},"/api/users/exchange-config":{"get":{"operationId":"get_exchange_config","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeConfigResponse"}}},"description":"Exchange configuration"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]},"post":{"operationId":"set_exchange_config","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeConfigRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Exchange configuration saved"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]}},"/api/users/login":{"post":{"operationId":"login","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserLogin"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserAuthResponse"}}},"description":"Login and get session token"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]}},"/api/users/profile":{"get":{"operationId":"users_get_profile","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserOut"}}},"description":"Get current user profile"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]},"put":{"operationId":"update_profile","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserUpdate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserOut"}}},"description":"Update current user profile"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]}},"/api/users/register":{"post":{"operationId":"register","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserCreate"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserOut"}}},"description":"Register a new user"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]}},"/api/users/sync-membership":{"post":{"operationId":"sync_membership","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicJson"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusMessageResponse"}}},"description":"Membership synced"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid request body or parameters"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal server error"}},"tags":["Users"]}}},"security":[{"bearer_auth":[]},{"session_token_query":[]}],"servers":[{"description":"Local development","url":"http://localhost:8080"},{"description":"Production","url":"https://api.production.hyperoru.com"}],"tags":[{"description":"Health check endpoints","name":"Health"},{"description":"User registration, authentication, and profile","name":"Users"},{"description":"AI trader account management","name":"Accounts"},{"description":"System configuration","name":"Config"},{"description":"System management and backfill","name":"System"},{"description":"System log management","name":"System Logs"},{"description":"Order management","name":"Orders"},{"description":"Prompt template and binding management","name":"Prompts"},{"description":"Prompt backtesting","name":"Prompt Backtest"},{"description":"Cryptocurrency price data","name":"Crypto"},{"description":"Market data and indicators","name":"Market Data"},{"description":"K-line data and backfill","name":"Klines"},{"description":"AI-powered kline analysis","name":"Kline Analysis"},{"description":"Price sampling pool","name":"Sampling"},{"description":"Signal definitions, pools, and triggers","name":"Signals"},{"description":"Trading arena and model chat","name":"Arena"},{"description":"Factor ranking","name":"Ranking"},{"description":"Trade analytics and attribution","name":"Analytics"},{"description":"Trading program management and backtesting","name":"Programs"},{"description":"Backtest results","name":"Backtests"},{"description":"Hyperliquid exchange integration","name":"Hyperliquid"},{"description":"Binance exchange integration","name":"Binance"},{"description":"HyperAI conversational agent","name":"HyperAI"},{"description":"Telegram and Discord bot integration","name":"Bots"},{"description":"Factor engine and computation","name":"Factors"},{"description":"News aggregation and classification","name":"News"},{"description":"Market regime classification","name":"Market Regime"},{"description":"Market flow indicators","name":"Market Flow"},{"description":"Market intelligence streaming","name":"Market Intelligence"},{"description":"Trader data import/export","name":"Trader Data"},{"description":"Polling endpoints for background LLM streaming tasks","name":"AI Stream"}]}