create_agent
⚠ COSTS LLM CREDITS on the NexusTrade account — spins up an Aurora agent via Router V5 classification + ReAct execution loops, billed per token. Manual approval required: do NOT call unless the user explicitly asked to launch an Aurora agent. For strategy creation/backtesting/analysis prefer no-LLM tools: structured create_portfolio (pass full IPortfolio JSON), backtest_portfolio, query_backtest_history, query_*, fetch_portfolios. Create a new autonomous Aurora agent using the same body shape as POST /api/agent. When maxIterations or automationMode are omitted, applies the user's saved ChatSettings. Agent models are product-locked (openai/gpt-5.6-luna planner, openai/gpt-6-luna executor, and the platform tool-role defaults) and cannot be overridden. Pass attachment_ids from upload_chat_attachment (READY) to bind files onto the last user message — same as the web FILES tab. Use this for a method-brief PDF plus a short analyze/report request.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | Optional user-assigned display name for the new agent (max 100 chars). Enables later lookup via title on get_agent / send_agent_message / etc. | |
| messages | No | ChatMessage array, e.g. [{"sender":"User","content":"..."}] | |
| maxIterations | No | Max agent iterations. When omitted, uses the user's saved ChatSettings.agentIterations (same as the web UI). | |
| session_depth | No | Deprecated compatibility field. Both values use Aurora's adaptive routing policy. | |
| attachment_ids | No | READY chat-attachment ids from upload_chat_attachment. Bound onto the last user message as fileAttachments (same refs as the web FILES tab). | |
| automationMode | No | automated | semi-automated. When omitted, uses ChatSettings.agentAutomationMode. | |
| conversationId | No | Optional NexusGenAI conversation id | |
| idempotencyKey | No | Caller-chosen token that makes this create retry-safe. Creation runs the router and the planner and regularly takes longer than the transport will wait, so a call that times out has usually SUCCEEDED. Pass a unique key, and if the call appears to fail, retry with the SAME key: you get the agent the first call created, never a second billed run. A key reused for a different prompt is rejected rather than silently replayed. |