Start a live deployment
start_deploymentPrepares owner review for a new BotSpot deployment; this call does not start a bot or place trades before approval. After explicit owner approval, this is HIGH RISK: the deployment may place real-money trades. Call for an authorized start request even when required saved variables are missing: readiness validation returns the exact missing-variable secure entry cards. Preparing those cards is the next setup step, not a completed start or approval. Never request secret values in chat or claim a schedule was created by this preparation. For an extra iteration of an existing scheduled bot, use run_deployment_once; do not create another deployment. Never use this tool for a direct or one-off buy, sell, or order request. Use place_trade instead; a start_deployment approval is not a trade approval. When the user asks to run, start, turn on, or deploy an attached saved strategy, call this tool to create the website approval request; do not substitute a backtest. Strongly prefer pre-selecting brokerCredentialId from list_broker_credentials whenever an active, connected saved broker matches the strategy or user request (for example a matching broker name, paper/live mode, or the user's clearest active account for that asset class) so the owner only reviews and confirms instead of picking from a blank dropdown. For a new paper bot, external MCP clients (Claude, Codex, Cursor, ChatGPT) should create a fresh dedicated managed paper account via broker_connections(action="create_paper") rather than silently reusing an unrelated existing named paper account, while still honoring an existing paper account if the user explicitly names or asks to reuse it. The website approval page still lets the owner change or select a broker before approving and blocks approval until a valid broker is selected; omit brokerCredentialId only when no connected matching account is clear. This tool accepts only saved references: aiStrategyRevisionId for code, optional brokerCredentialId for broker access, and optional envVarSetIds for saved non-broker runtime secrets. Broker access must come from a saved broker credential selected in the tool call or on the website approval page. Run mode, schedule first: most bots should run on a schedule (once a day, weekly, at set times, or during market hours on weekdays); 24/7 is the last resort. A 24/7 start (deploymentMode always_on) needs alwaysOnReason, one sentence on why a schedule covering every time it can trade is not enough; the typical valid reason is a market that trades around the clock (crypto). Without alwaysOnReason an always_on start runs as auto and the result says so. deploymentMode defaults to auto. Auto uses, in order: the schedule passed here, the strategy's saved schedule, the original strategy's schedule for a Marketplace copy, then the hours its market is open (US stocks, ETFs and options: weekdays 09:25 to 16:05 ET; futures: the Sunday to Friday session). Auto picks 24/7 only for markets that trade around the clock (crypto) or when the code analysis says the bot must run continuously. The result says which run mode was chosen and why. Passing scheduleMetadata for the strategy's real cadence (daily, weekly, at the open) is cheapest. For daily or weekly strategies (for example sleeptime="1D" or "7D"), prefer deploymentMode=scheduled with cadence.type=specific_times at 09:35 America/New_York on weekdays (about $0.02 a month). For intraday US stock or options strategies, prefer deploymentMode=scheduled with cadence.type=continuous_window (09:30 to 16:00 America/New_York, Mon-Fri, about $1.60 a month) rather than always_on. For futures, match the asset class session hours (Sun-Thu 18:00 to 17:00 America/New_York). Use deploymentMode='always_on' with alwaysOnReason only when the strategy trades around the clock (such as 24/7 crypto monitoring) or the owner asks for 24/7 again after hearing it costs about $8.50 a month instead of cents. 'Keep it running all the time', 'always on' or 'I don't want to start it by hand' for a strategy that acts once a day, once a week or only in market hours is not a 24/7 request: it means keep the bot live without manual starts, so schedule it to cover every time it can trade and say why in one line. Use deploymentMode='scheduled' when you can provide or reuse schedule metadata/policy. Explicit modes fail instead of silently changing route. When the user asks for a daily schedule and does not name a clock time, do not ask what time or timezone. Call this tool in the same turn with deploymentMode scheduled, runImmediately false, and scheduleMetadata schemaVersion 1, marketSession regular, liveCadenceMatchesBacktest true, source user_instruction, and cadence specific_times at 09:35 America/New_York (five minutes after the US market open, avoiding the turbulent opening minute). For a NEW deployment with an immediate first iteration (including afternoon intraday runs), set runImmediately=true. For one iteration of an EXISTING scheduled deployment, use run_deployment_once; never substitute this start operation or an update. Do not refuse by citing opening-range or market-open+N timing from the recurring schedule; that timing is trading eligibility for later ticks, not a ban on starting an owner-requested one-shot now. For a one-off clock time such as 3:10 p.m., prefer scheduleMetadata with specific_times or event_window for that time and runImmediately=true. For a one-time run "in N minutes", use an event_window window with startAfterApprovalMinutes (at least 3) and durationMinutes instead of startAt, so the run starts N minutes after the owner approves however long the approval takes. An exact startAt that is less than about 4 minutes away is refused, and its approval request expires before that time. Do not pass a broker credential whose status is reconnect_required. Omit brokerCredentialId and still create the start approval; the website approval page lets the owner select, add, or reconnect a broker before approving, including through /account-settings/broker-connections. Non-broker runtime secrets must come from saved environment variables: pass their ids as envVarSetIds. Do not pass raw broker credentials, raw environment variables, raw runtime configuration, inline code, requirements text, API keys, screener exports, CSV rows, JSON row dumps, workbook data, or large base64 blobs. Use broker_connections(action="connect_existing")/list_broker_credentials before deployment, and use saved_env_vars(action="create")/saved_env_vars(action="list") for data-provider API keys or other non-broker runtime secrets. Broker credential key examples: Kalshi (kalshi): KALSHI_API_KEY_ID + KALSHI_PRIVATE_KEY. Optional: KALSHI_SUBACCOUNT, KALSHI_EXCHANGE_INDEX, KALSHI_BASE_URL, KALSHI_WS_URL. Do not pass KALSHI_IS_DEMO; BotSpot derives it from paperOrLive. Example credentialValues: {"KALSHI_API_KEY_ID":"key-id...","KALSHI_PRIVATE_KEY":"private-key-pem..."}. Alpaca (alpaca): ALPACA_API_KEY + ALPACA_API_SECRET OR ALPACA_OAUTH_TOKEN. Do not pass ALPACA_IS_PAPER; BotSpot derives it from paperOrLive. Example credentialValues: {"ALPACA_API_KEY":"PK...","ALPACA_API_SECRET":"secret..."}. Tradier (tradier): TRADIER_ACCOUNT_NUMBER + TRADIER_ACCESS_TOKEN OR TRADIER_ACCOUNT_NUMBER + TRADIER_API_KEY OR TRADIER_ACCOUNT_NUMBER + TRADIER_TOKEN. Optional: TRADIER_REFRESH_TOKEN, TRADIER_OAUTH_CLIENT_ID, TRADIER_OAUTH_CLIENT_SECRET. Do not pass TRADIER_IS_PAPER; BotSpot derives it from paperOrLive. Example credentialValues: {"TRADIER_ACCOUNT_NUMBER":"6AB12345","TRADIER_ACCESS_TOKEN":"token..."}. Charles Schwab (schwab): SCHWAB_ACCOUNT_NUMBER + SCHWAB_TOKEN. Example credentialValues: {"SCHWAB_ACCOUNT_NUMBER":"123456789","SCHWAB_TOKEN":"base64url-token-payload..."}. Tradovate (tradovate): TRADOVATE_USERNAME + TRADOVATE_DEDICATED_PASSWORD + TRADOVATE_CID + TRADOVATE_SECRET. Optional: TRADOVATE_APP_ID, TRADOVATE_APP_VERSION. Do not pass TRADOVATE_IS_PAPER; BotSpot derives it from paperOrLive. Example credentialValues: {"TRADOVATE_USERNAME":"username...","TRADOVATE_DEDICATED_PASSWORD":"dedicated-password...","TRADOVATE_CID":"client-id...","TRADOVATE_SECRET":"secret..."}. TopstepX (projectx-topstepx): PROJECTX_TOPSTEPX_API_KEY + PROJECTX_TOPSTEPX_USERNAME. Optional: PROJECTX_TOPSTEPX_PREFERRED_ACCOUNT_NAME. Example credentialValues: {"PROJECTX_TOPSTEPX_API_KEY":"key...","PROJECTX_TOPSTEPX_USERNAME":"username..."}. WEEX (weex): WEEX_API_KEY + WEEX_API_SECRET + WEEX_API_PASSPHRASE. Example credentialValues: {"WEEX_API_KEY":"key...","WEEX_API_SECRET":"secret...","WEEX_API_PASSPHRASE":"passphrase..."}. Bitunix (bitunix): BITUNIX_API_KEY + BITUNIX_API_SECRET. Optional: BITUNIX_TRADING_MODE. Example credentialValues: {"BITUNIX_API_KEY":"key...","BITUNIX_API_SECRET":"secret..."}. Kraken (kraken): KRAKEN_API_KEY + KRAKEN_API_SECRET. Example credentialValues: {"KRAKEN_API_KEY":"key...","KRAKEN_API_SECRET":"secret..."}. Coinbase (coinbase): COINBASE_API_KEY_NAME + COINBASE_PRIVATE_KEY. Optional: COINBASE_API_PASSPHRASE, COINBASE_SANDBOX. Example credentialValues: {"COINBASE_API_KEY_NAME":"organizations/.../apiKeys/...","COINBASE_PRIVATE_KEY":"-----BEGIN EC PRIVATE KEY-----..."}. Any other CCXT 4.5.64 exchange id (for example okx, binance, bybit, bitget, hyperliquid): use that id as the broker and the credentials it requires, named _API_KEY, _API_SECRET, _API_PASSPHRASE, _UID, _PRIVATE_KEY or _WALLET_ADDRESS. Do not pass _SANDBOX; BotSpot derives it from paperOrLive. memoryGb may be 2, 3, or 4 when the user sets bot memory, including because the strategy needs a browser. Omit memoryGb to keep the current size. Do not send any other size, and do not send a CPU field. CPU stays as it is. Pass memoryGb only with deploymentMode scheduled. A 2, 3, or 4 GB always-on start is rejected because that larger host is not approved; tell the user that start was not placed instead of dropping the memory setting. The tool always creates a short-lived website authorization request and returns an approval URL the user must open while signed in to BotSpot. It does not execute from chat-only approval or reusable grants. No broker secrets are returned to the MCP response. For Codex, Claude, Cursor, and other clients without BotSpot native confirmation cards, return the exact authorizationUrl as a clickable Markdown link in your reply. Do not say a card or button was created unless the client actually rendered it. BotSpot clients may render structuredContent as a native confirmation, but a button name alone is not an approval link. A pending request is not execution; only the signed-in user may approve on the website. Report expiry and check get_deployment_action_status after approval.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"aiStrategyRevisionId": "<aiStrategyRevisionId>"
},
"name": "start_deployment"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| memoryGb | No | ||
| acceptances | No | ||
| envVarSetIds | No | ||
| alwaysOnReason | No | Required to run 24/7 (deploymentMode always_on): one sentence on why a schedule that covers every time this bot can trade is not enough, for example "it trades crypto around the clock". Without it, an always_on start runs as auto (a schedule or market hours) and says how to force 24/7. | |
| deploymentMode | No | auto | |
| idempotencyKey | No | ||
| runImmediately | No | ||
| scheduleMetadata | No | ||
| schedulePolicyId | No | ||
| tradeApprovalMode | No | Controls whether bot orders execute automatically ('auto', default for Python and AI bots) or stage for explicit owner review and approval before broker execution ('require_approval'). | |
| brokerCredentialId | No | ||
| aiStrategyRevisionId | Yes | ||
| strategyParameterSetId | No |