> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.ninjatrader.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.ninjatrader.com/_mcp/server.

# Tools

**Beta, pre-release.** The NinjaTrader MCP server and its trading skills are in beta and
aren't yet generally available. The beta runs on Demo only, which trades simulated money.
Live access opens later. Server hostnames, the tool set, the skills, and the onboarding
flow may change before launch.

Tools are the actions your agent can take. Each tool declares an input schema, the [access it requires](/mcp/authentication#permissions-and-scopes), and a behavior hint your client uses to decide whether to ask for your approval before running it.

* **Read-only** tools only query data. They never change your account.
* **Write** tools change your account by placing or modifying orders, flattening positions, or changing risk settings. The server marks them with the MCP protocol's destructive-action flag, `destructiveHint`, which is why most clients pause for confirmation before running them, and why some clients describe these actions as "destructive."

Your agent discovers the full, live tool list from the server when it connects, so the catalog it sees always matches what the server actually offers. The reference below groups every tool by what it does.

The agent has a built-in [`describe`](#utility) tool for looking up enum values such as
order types, statuses, and time-in-force, plus field meanings and worked examples. If
you're unsure what a value means, ask your agent to "describe" it.

## Recommended workflow

The server follows a natural trading flow. A typical sequence is:

1. **`my_portfolio`**: see accounts, positions, balances, and working orders.
2. **`search_contracts`**: find the exact tradable symbol.
3. **`market_snapshot`**: check the live quote, spec, and margin.
4. **`estimate_order`**: pre-flight the margin, fees, and feasibility of a hypothetical order.
5. **`place_order`**: submit it.

## Account & portfolio

| Tool           | Description                                                                                       | Key inputs          | Access                        | Behavior  |
| -------------- | ------------------------------------------------------------------------------------------------- | ------------------- | ----------------------------- | --------- |
| `my_portfolio` | Account summary, open positions, and working orders.                                              | `account`, `fields` | Positions: Read, Orders: Read | Read-only |
| `user_profile` | Your profile: identity, multifactor authentication, subscription, market data, accounts, add-ons. | `fields`            | Users: Read                   | Read-only |

## Market data & contracts

| Tool               | Description                                                                       | Key inputs                                                                          | Access                | Behavior  |
| ------------------ | --------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- | --------------------- | --------- |
| `search_contracts` | Find tradable contracts by symbol, product, or exchange.                          | `text`, `exchange`, `productType`, `includeFamilySiblings`                          | ContractLibrary: Read | Read-only |
| `market_snapshot`  | Real-time quote, contract spec, and margin for one or more symbols.               | `symbols`, `product`, `fields`                                                      | Prices: Read          | Read-only |
| `market_history`   | Historical open-high-low-close bars with a `Minute`, `Daily`, or `Tick` bar type. | `symbol`, `barType`, `barSize`, `count`, `from`, `to`, `closeOnly`, `volumeProfile` | Prices: Read          | Read-only |
| `dom_snapshot`     | Depth-of-market snapshot: bid/ask price ladders and sizes.                        | `symbol`, `depth`                                                                   | Prices: Read          | Read-only |
| `pulse`            | Crowd-sentiment snapshot for a product, contract, or group.                       | `topic`, `key`                                                                      | Prices: Read          | Read-only |

## Trading & orders

| Tool             | Description                                                                                | Key inputs                                                                                                                                       | Access                               | Behavior  |
| ---------------- | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------ | --------- |
| `estimate_order` | Pre-flight margin, fees, and feasibility for a hypothetical order.                         | `account`, `symbol`, `action`, `quantity`, `orderType`, `price`, `stopPrice`                                                                     | Orders: Read                         | Read-only |
| `place_order`    | Submit a new order, optionally with order-cancels-order or order-sends-order bracket legs. | `account`, `symbol`, `action`, `orderType`, `quantity`, `timeInForce`, `price`, `stopPrice`, `limitIfTouchedPrice`, `expirationTime`, `brackets` | Orders: Full Access                  | **Write** |
| `modify_order`   | Change a working order's price, stop price, or quantity.                                   | `account`, `orderId`, `price`, `stopPrice`, `quantity`                                                                                           | Orders: Full Access                  | **Write** |
| `cancel_order`   | Cancel a single order by ID, or all working orders on an account.                          | `account`, `orderId` *or* `all`                                                                                                                  | Orders: Full Access                  | **Write** |
| `close_position` | Flatten a position for one symbol, or for all symbols, with an opposite-side market order. | `account`, `symbol` *or* `all`                                                                                                                   | Orders: Full Access, Positions: Read | **Write** |

Every order the agent submits must also pass the account's [pre-trade risk checks](/mcp/pre-trade-risk) before it reaches the market. `estimate_order` runs the same checks as a dry run.

**Bracket legs are offsets, not absolute prices.** In `place_order`, a bracket's
`profitTarget` and `stopLoss` specify signed offsets from the entry's working price, in
contract-native units, not absolute prices. In `modify_order`, by contrast, the price
fields are absolute. Ask your agent to `describe(topic='place_order_examples')` for
bracket patterns.

## History & reporting

| Tool                    | Description                                                                 | Key inputs                                                              | Access           | Behavior  |
| ----------------------- | --------------------------------------------------------------------------- | ----------------------------------------------------------------------- | ---------------- | --------- |
| `order_history`         | Historical orders with status, fill price, and timestamps.                  | `account`, `startDate`, `endDate`, `symbol`, `status`, `format`         | Orders: Read     | Read-only |
| `fill_history`          | Historical fills with prices, quantities, and fee breakdown.                | `account`, `startDate`, `endDate`, `symbol`, `format`                   | Orders: Read     | Read-only |
| `order_details`         | Detailed order info: fills, commands, and strategy.                         | `account`, `orderId`                                                    | Orders: Read     | Read-only |
| `position_history`      | Historical positions: open/close times, direction, prices, realized P\&L.   | `account`, `startDate`, `endDate`, `symbol`, `format`                   | Positions: Read  | Read-only |
| `cash_history`          | Per-transaction cash ledger with change types, amounts, and timestamps.     | `account`, `startDate`, `endDate`, `cashChangeType`, `symbol`, `format` | Accounting: Read | Read-only |
| `daily_balance_history` | Daily account balance history with total amounts and realized P\&L.         | `account`, `startDate`, `endDate`, `format`                             | Accounting: Read | Read-only |
| `performance_summary`   | Full trade performance stats: aggregates, winners/losers, drawdown, run-up. | `account`, `startDate`, `endDate`                                       | Accounting: Read | Read-only |

Date inputs accept `YYYY-MM-DD` or natural terms like `today`, `yesterday`, `this week`,
`last month`, or `last N days`. History tools support a compact `columns` response
`format` that's about 50% smaller on large histories. A `fields` filter to keep only the
paths you need is available on `my_portfolio`, `market_snapshot`, and `user_profile`.

## Risk

| Tool                   | Description                                                                              | Key inputs                                                                                                                                                                                | Access             | Behavior  |
| ---------------------- | ---------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ | --------- |
| `risk_settings`        | Per-account risk configuration: loss limits, drawdown, margin thresholds.                | `account`                                                                                                                                                                                 | Risks: Read        | Read-only |
| `update_risk_settings` | Change risk and auto-liquidation settings. The tool changes only the fields you provide. | `account`, `dailyLossLimit`, `weeklyLossLimit`, `dailyProfitLimit`, `weeklyProfitLimit`, `trailingMaxDrawdown`, `trailingMaxDrawdownLimit`, `trailingMaxDrawdownMode`, `flattenTimestamp` | Risks: Full Access | **Write** |

## Alerts

| Tool            | Description                                                              | Key inputs                                                                           | Access              | Behavior            |
| --------------- | ------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------- | ------------------- |
| `create_alert`  | Create a price-cross or expression alert.                                | `symbol`, `trigger`, `price`, `expression`, `message`, `validUntil`, `triggerLimits` | Alerts: Full Access | Write—safe to retry |
| `list_alerts`   | List all your alerts with status, trigger counts, and expiry.            | `status`                                                                             | Alerts: Full Access | Read-only           |
| `dismiss_alert` | Deactivate an alert. The server keeps the record instead of deleting it. | `alertId`                                                                            | Alerts: Full Access | **Write**           |

## Analytics

The calendar tools are available when the deployment has the market-info service enabled. The timeline tools appear in your agent's tool list only when your account has the timeline feature enabled.

| Tool                | Description                                                                            | Key inputs                               | Access           | Behavior  |
| ------------------- | -------------------------------------------------------------------------------------- | ---------------------------------------- | ---------------- | --------- |
| `timeline_report`   | Per-day trade report with P\&L, MAE/MFE, and entry/exit quality. Single date or range. | `account`, `date`, `endDate`, `timezone` | Accounting: Read | Read-only |
| `timeline_details`  | Event-by-event timeline for a single trade: entry, scale-in, scale-out, exit.          | `trade_id`, `timezone`                   | Accounting: Read | Read-only |
| `economic_calendar` | Economic event releases such as CPI, NFP, FOMC, EIA, and OPEC. Paginated.              | `fromDate`, `toDate`, `limit`, `offset`  | Prices: Read     | Read-only |
| `earnings_calendar` | Corporate earnings releases. Paginated.                                                | `fromDate`, `toDate`, `limit`, `offset`  | Prices: Read     | Read-only |

## Utility

| Tool       | Description                                                                                                                              | Key inputs | Access | Behavior  |
| ---------- | ---------------------------------------------------------------------------------------------------------------------------------------- | ---------- | ------ | --------- |
| `describe` | Fetch documentation for a named topic: enum values, field meanings, output shapes, and examples. Use `topic='index'` to list all topics. | `topic`    | None   | Read-only |

`describe` is how the agent looks up the exact valid values for enumerated fields, plus complex output structures and worked examples. For example, `action` accepts `Buy` or `Sell`. `orderType` accepts `Market`, `Limit`, `Stop`, `StopLimit`, `TrailingStop`, `MIT`, `LimitIfTouched`, and more. `timeInForce` accepts `Day`, `GTC`, `IOC`, `FOK`, or `GTD`. Other enumerated fields include `ordStatus`, `barType`, `productType`, and `cashChangeType`.

## Rate limits

Each tool has a per-minute request budget, and the server applies a short time penalty when your agent exceeds a budget. The limits are generous for normal agent use. Read-heavy tools like `my_portfolio` and `market_snapshot` allow far more frequent calls than write tools. If your agent is making rapid repeated calls and starts getting throttled, have it slow down and retry. This mirrors the [rate-limit behavior of the Trade API](/api/authentication#request-rate-limits-and-time-penalties).