# MT5 API for AI agents: a buyer's checklist

> The best MT5 API for AI trading gives agents a hosted MCP server, safe retries, truthful health and owner controls. Here is the checklist, and how Tickwire meets it.

Source: https://tickwire.io/blog/best-mt5-api-for-ai-trading/

Tickwire blog, published 2026-10-31. General information, not investment advice.

The best MT5 API for AI trading is one an AI agent can reach from the cloud, that can't place an order twice, that tells the truth about whether the account is connected, and that lets the owner limit and stop the agent. Tickwire is built for that: a hosted MT5 and MT4 terminal per account, a REST and WebSocket API, and an MCP server for Claude, ChatGPT and agent frameworks. Use the checklist below to judge any MT5 integration platform for AI trading, ours included.

We don't rank other providers here. Their features change, and you should check them yourself. Each point says what to look for, why it matters for an AI, and where Tickwire documents it. If you want to start rather than compare, see [AI trading on MT5](https://tickwire.io/ai-trading-mt5/).

## 1. A hosted MCP server, not only a local one

AI apps call tools through MCP. Claude on claude.ai and ChatGPT connect from their own cloud, so the server must have a public address. A server on your own computer, such as the terminal's built-in MCP support in MT5 build 6060, only reaches local tools.

**Ask:** Can Claude and ChatGPT add it as a custom connector? Does it sign in with OAuth, so you never paste a key into a chat?

**Tickwire:** `https://api.tickwire.io/mcp`, with sign-in, account picking and look only or look and trade. See [MT5 built-in MCP vs a hosted MCP server](https://tickwire.io/blog/mt5-native-mcp-vs-hosted/).

## 2. Retries that never trade twice

Models retry. Networks drop. An API that places a second order when a request is repeated will, sooner or later, double a position.

**Ask:** Does every order take an idempotency key? Does a repeat return the first answer? What does the API say when it doesn't know if the order ran?

**Tickwire:** every trade takes an `Idempotency-Key`; a repeat returns the first answer (the Idempotent-Replayed header on REST, `replayed: true` in MCP). When the result is ambiguous the outcome is `unknown`, never a guess, and `get_trade_status` tells the agent what happened. See [Idempotency](https://tickwire.io/docs/idempotency/).

## 3. Health you can believe

An agent that trades on a dead connection or a frozen price is guessing. "Connected" should mean the terminal is logged in and the account was read, not that a process is alive.

**Ask:** Does health come with evidence? Does it say when prices stop moving? Does it refuse market orders on stale quotes?

**Tickwire:** REST health is `healthy`, `degraded`, `stale`, `disconnected` or `down`, with evidence. The agent API uses its own words: `connected`, `disconnected` or `unknown`. `prices_live: false` flags a still market, and a stale quote makes market orders answer `409 quote_stale` with nothing sent. See [Health](https://tickwire.io/docs/health/).

## 4. Owner controls the agent can't change

A prompt is not a control. The rules that protect money must sit outside the model.

**Ask:** Can each agent get its own key, limited to chosen accounts? Is there a read-only mode? A kill switch? A hook where your own code approves orders?

**Tickwire:** scoped `twag_` agent keys, read-only mode, kill switches per key and per account, and an optional pre-trade hook that answers allow, deny or hold, signed with HMAC-SHA256. See [AI trading agents](https://tickwire.io/ai-agents/).

## 5. An audit trail with reasons

When an agent does something odd, you need to know what it did and why.

**Ask:** Is every change logged with the time, the actor and a reason? Can the agent read the log too?

**Tickwire:** every trading tool needs a `reason`, written to the audit log with the result. The agent can read it with `get_audit_log`. See [Audit trails for AI trading agents](https://tickwire.io/blog/ai-trading-agent-audit-trail/).

## 6. A real terminal, on MT5 and MT4

Some services copy prices from a feed or route orders their own way. An agent then sees numbers that may not match the account.

**Ask:** Is there a real terminal logged in to my broker account? Does MT4 work through the same API? What happens when MT4 lacks a feature?

**Tickwire:** one real terminal per account, any broker. MT4 and MT5 share the endpoints, and missing MT4 features answer `not_supported_on_mt4` instead of fake data. See [Platforms](https://tickwire.io/docs/platforms/).

## 7. Plain REST and WebSocket under the MCP

You will want code next to the agent: a dashboard, a journal, an alert. The same account should be reachable without the AI.

**Ask:** Is there a documented REST API and a price stream? Webhooks?

**Tickwire:** a REST API, a WebSocket stream, webhooks and TradingView alerts. See the [MT5 REST API quickstart with curl](https://tickwire.io/blog/mt5-rest-api-quickstart-curl/) and the [API reference](https://tickwire.io/docs/reference/).

## 8. A sandbox that can fail on purpose

An agent must handle rejections, disconnects and unknown outcomes. You want to see those before real money does.

**Ask:** Is there a free sandbox? Can it act out failures?

**Tickwire:** a free sandbox with magic logins for an unknown outcome, a rejection, a disconnect, frozen quotes and a wrong login. See [Sandbox](https://tickwire.io/docs/sandbox/).

## 9. Clear pricing per account

AI trading often means several accounts. The cost should be easy to work out.

**Ask:** Is the price per account public? What is included?

**Tickwire:** from $12 per account a month, with the MCP server, webhooks and TradingView alerts included, and a 7-day free trial. See [pricing](https://tickwire.io/pricing/) and [what a hosted MetaTrader API costs per account](https://tickwire.io/metatrader-api-cost/).

## The checklist in one table

| Check | Why it matters for an AI |
|---|---|
| Hosted MCP server with sign-in | Claude and ChatGPT can reach it from the cloud |
| Idempotent orders, `unknown` outcome | A retry never doubles a position |
| Health with evidence, stale quote refusal | No trading on a dead link or a frozen price |
| Scoped keys, read-only, kill switch, hook | Rules sit outside the model |
| Audit log with reasons | You can see what the agent did and why |
| Real terminal, MT4 and MT5 | Numbers match the account |
| REST, WebSocket, webhooks | Code beside the agent |
| Sandbox with failures | Errors are handled before they cost money |
| Public price per account | Easy to plan |

## Frequently asked questions

### What is the best MT5 API for AI trading?

The one that passes the checks above: a hosted MCP server, orders that can't run twice, truthful health, owner controls outside the model, an audit log, and a real terminal. Tickwire is built around those points, and you can test it free in the sandbox.

### What is an MT5 integration platform for AI trading?

A service that connects an AI app or agent to a MetaTrader 5 account. It holds the account, gives the AI tools to read and trade, and should give the owner limits and records. Tickwire does this for MT5 and MT4 through MCP, REST and WebSocket.

### Can I use ChatGPT or Claude for MT5 trading?

Yes, through a hosted MCP server. You add it as a custom connector, sign in and choose look only or look and trade. See [How to connect ChatGPT to MetaTrader 5](https://tickwire.io/blog/connect-chatgpt-to-mt5/) and [How to connect Claude](https://tickwire.io/blog/connect-claude-to-mt5/).

### Does the MT5 API need to run on Windows?

Not with a hosted terminal. Tickwire runs the terminal in the cloud, so your agent can run on a Mac, Linux or any server.

### Does Tickwire set trading limits for my agent?

No. Tickwire sets no size or loss limits for you. You set them in your own pre-trade hook, and you can stop an agent at any time with a kill switch.
