Tradovate MCP Tools
The Tv_* tools let an Elite user's AI client talk to their own linked Tradovate account through the hosted MCP server. No NT8 add-on is involved: calls execute server-side against the Tradovate Web API, so they work even when NinjaTrader is closed.
The only extra requirement beyond Elite is a linked Tradovate account. Without one, every Tv_* call returns a clean tradovate_not_linked error with a pointer to the Tradovate Account Manager, instead of an opaque client exception.
Read tools require the read scope; trade tools require trade (see Scopes). The REST twin of this surface, with the full field grammar, mutation safety guarantees, and error table, is the Tradovate API.
Read Tools
All 16 read tools use the read scope and return {"success": true, "data": ...} shapes matching the /v1/api/tv REST reads.
| Tool | Required args | Use it for |
|---|---|---|
Tv_Status | none | Link status: linked identities, environments (demo/live), token expiry. |
Tv_ListAccounts | none | List the linked Tradovate accounts (name, id, environment). |
Tv_AccountSnapshot | none | One-shot live snapshot of every linked account: balances, open positions with P&L, working orders. |
Tv_GetAccount | account | One account with its current cash-balance snapshot. |
Tv_ListPositions | none (account optional) | Open positions: fill-reconciled for one account, or raw rows across all linked identities. |
Tv_GetPosition | account, instrument | Net position for one account and instrument. netPos is signed; 0 means flat. |
Tv_ListOrders | none (account optional) | Working orders for one account, or every order across all linked identities. |
Tv_GetOrder | order_id | One order by id (includes ordStatus). |
Tv_GetOrderLifecycle | order_id | Audit trail for one order: current version, submitted commands, and command reports (rejectReason/text for refusals). |
Tv_ListFills | none (account optional) | Fills, optionally scoped to the identity that owns one account. |
Tv_CashBalances | none | Cash-balance rows for every linked identity. |
Tv_MarginSnapshots | none | Margin snapshots for every linked identity. |
Tv_FindContract | name | One contract by exact Tradovate symbol, e.g. ESU6. |
Tv_SuggestContracts | text | Contract autocomplete; use it to resolve the active front month. |
Tv_ListExchanges | none | Exchange reference list from Tradovate. |
Tv_GetWatermarks | account | P&L high-water marks (pnlhigh, netliqhigh, unrealhigh) tracked by the CrossTrade Account Manager. |
Trade Tools
All 13 trade tools use the trade scope. Order references (order_id) accept either a Tradovate numeric order id or the user-assigned order_id from a previous Tv_PlaceOrder.
| Tool | Required args | Use it for |
|---|---|---|
Tv_PlaceOrder | account, instrument, action, qty, order_type | Place an order. Supports market/limit/stop/stoplimit/mit/trailing types, server-side OCO brackets via take_profit/stop_loss, and inline atm_* multibracket fields. |
Tv_FlatPlace | account, instrument, action, qty, order_type | Flatten the position and cancel working orders on the instrument, then place a fresh entry in one atomic command. |
Tv_CancelOrder | order_id | Cancel one working order. |
Tv_CancelOrders | account | Cancel every working order on one account. |
Tv_CancelAllOrders | none | Cancel every working order across all linked identities. |
Tv_ChangeOrder | order_id | Modify a working order in place (quantity and/or prices); unchanged values are merged from the live order version. |
Tv_CancelReplace | order_id, account, instrument, action, qty, order_type | Cancel a working order and place a replacement in one command. |
Tv_CancelAndBracket | account, instrument, action, qty | Cancel working orders on the instrument, clamp to the live position, and attach a fresh OCO bracket. |
Tv_ClosePosition | account, instrument | Close the position; optional qty or percent (0-1) closes part of it. |
Tv_Flatten | none (filters optional) | Flatten positions matching account/instrument/market_position filters. No filters means every position. |
Tv_FlattenEverything | none | Liquidate every position and cancel every working order across all linked identities. |
Tv_Reverse | account, instrument | Reverse the live position: liquidate, then enter the opposite side at the same size. |
Tv_ReversePosition | account, instrument, action, qty, order_type | Flatten the instrument, then place the specified entry (explicit-size reverse). |
Trade tools build a webhook-vocabulary command and run it through the same parser and dispatcher as the /v1/api/tv REST mutations and webhook signals: field validation, Account Manager locks (kill switch and close-only), and Trade Copier fan-out all apply. instrument accepts continuous (ES1!), NT8 (ES 09-26), or Tradovate (ESU6) forms.
Examples
A tools/call request that places a market order:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "Tv_PlaceOrder",
"arguments": {
"account": "DEMO12345678",
"instrument": "ES1!",
"action": "buy",
"qty": 1,
"order_type": "market"
}
}
}
A tools/call request that reads the live snapshot of every linked account:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "Tv_AccountSnapshot",
"arguments": {}
}
}
Related
- Tradovate API: the REST twin, field grammar, and error table.
- Scopes: read vs trade permissions.
- Workflows and Safety: safe placement in an agent loop.