How to monitor a production MCP server: what to check and how often
An uptime ping stays green while your connector is broken. Six checks for a remote MCP server: handshake, tool list drift, tool calls, auth, latency and listings, with a tested probe script.
On this page
- How to monitor a production MCP server: what to check and how often
- 1. The handshake
- 2. The tool list, compared to the last good one
- 3. A real tool call
- 4. The auth boundary and token health
- 5. Latency, as percentiles
- 6. Listings and where you appear
- A probe you can run
- Alerting without noise
- What Shipyard does
- Check your server
How to monitor a production MCP server: what to check and how often
A plain HTTP check on /mcp tells you the host answers. It stays green through an expired token, a deploy that dropped a tool, and an empty tools/list. Users meet those as "the connector stopped working", often days later. This guide lists the checks that catch them, ordered by how much each one costs you to run.
1. The handshake
Prove the server speaks MCP, not just HTTP. The probe has to follow the protocol era your server serves.
On the 2025-11-25 transport that means initialize, then the notifications/initialized notification, then your real request, carrying MCP-Protocol-Version and, if the server issued one, MCP-Session-Id (transport spec). A server that requires a session answers a request without one with 400, so a bare tools/list will fail on it even when the server is healthy.
On 2026-07-28 there is no handshake: every request carries its protocol version, servers MUST implement server/discover, and the HTTP request needs MCP-Protocol-Version and Mcp-Method headers (the transport page lists them). A server that supports only the new revision rejects an old-style request with 400. If you serve both eras, probe both. A dual-era server selects behavior by how the client opens (versioning page).
Treat a probe failure as down only after more than one. A single dropped packet should not page anyone.
2. The tool list, compared to the last good one
This is the check that catches the most real regressions. Fetch tools/list, reduce each tool to name, description, input schema and annotations, sort by name, hash it, and compare to the stored hash. A changed hash means someone changed what models see. Alert on three kinds of change:
- A tool disappeared or the count dropped. Usually a bad deploy or a feature flag.
- A description or schema changed. Users and directory reviewers see this change, and your listing text may need an edit. It is also a security signal, since a tool whose description quietly gains instructions is what tool poisoning looks like.
- A parameter was added or made required. That can break clients that cached the old shape. See tool annotations for hints that should change with it.
The 2026-07-28 tools page says servers SHOULD return tools in a deterministic order and notes that tools/list can carry ttlMs and cacheScope for caching. Sort anyway so your hash is stable. It also says the list MAY vary by the authorization on the request, so hash the list you get with the credentials you monitor with, and know that other users may see a different one.
3. A real tool call
tools/list working does not mean the tools work. Pick one or two read-only tools with a stable demo record, call them on a schedule, and check three things: the call returned and isError is not true, an expected string is in the text, and it finished inside a latency budget. Never call a write tool from a monitor. Spec-wise, input validation and business errors come back as normal results with isError: true, not as HTTP errors, so a monitor that only checks the HTTP status misses every one of them. OpenAI's Apps SDK server guide also asks for "logs and metrics for failed initialization and tool calls", so log those on your side too.
4. The auth boundary and token health
Monitor auth separately from the tools, in two parts.
Unauthenticated. A request without a token should get 401 with a WWW-Authenticate header pointing to your protected resource metadata. Claude's authentication docs say the first 401 must include that header and that Claude ignores it on a 200. A deploy that starts returning 200 or drops the header breaks sign-in with no error on your side. Also fetch the metadata URLs and check they return JSON. The OAuth guide lists them.
Authenticated. Use a dedicated read-only account and token, not a production user's. Run the handshake and a tool call with it. When that token or its refresh path breaks, this check fails before a customer's does. The Claude docs give timeouts to design against: 10 seconds for discovery, registration and token endpoints and 30 seconds for refresh requests, and an invalid refresh token should return invalid_grant. Alert if your token endpoint gets near 10 seconds.
5. Latency, as percentiles
Record the time of each handshake and each fixture. Alert on a budget, not the mean. Claude documents a 240-second ceiling on hosted tool calls, which is a limit and not a target. Pick budgets from what your own tools take, and read the timeouts guide for what to do when a tool gets close.
Run checks from outside your network. Anthropic connects from 160.79.104.0/21, so a firewall or WAF rule can block users while your internal checks pass. A hosted checker, or a job on a different cloud, sees what a client sees.
6. Listings and where you appear
A server can be healthy and still invisible: a directory entry that points at an old URL, or a listing that shows last month's tool count. Check weekly that each place you are listed still resolves and matches your live tool list. See where to list your server.
A probe you can run
We ran this against a live server twice. It performs the 2025-11-25 sequence and printed the same tool count and hash both times, plus the timings.
import { createHash } from 'node:crypto';
const url = process.argv[2];
const H = { 'content-type': 'application/json', accept: 'application/json, text/event-stream' };
async function rpc(body, extra = {}) {
const t0 = performance.now();
const res = await fetch(url, { method: 'POST', headers: { ...H, ...extra }, body: JSON.stringify(body), signal: AbortSignal.timeout(10_000) });
const text = await res.text();
const data = res.headers.get('content-type')?.includes('text/event-stream')
? JSON.parse(text.split('\n').find((l) => l.startsWith('data:')).slice(5))
: text ? JSON.parse(text) : null;
return { res, data, ms: Math.round(performance.now() - t0) };
}
const init = await rpc({ jsonrpc: '2.0', id: 1, method: 'initialize',
params: { protocolVersion: '2025-11-25', capabilities: {}, clientInfo: { name: 'probe', version: '0.0.1' } } });
if (init.res.status !== 200) { console.log('FAIL initialize', init.res.status); process.exit(1); }
const sid = init.res.headers.get('mcp-session-id');
const hdr = { 'mcp-protocol-version': init.data.result.protocolVersion, ...(sid ? { 'mcp-session-id': sid } : {}) };
await rpc({ jsonrpc: '2.0', method: 'notifications/initialized' }, hdr);
const list = await rpc({ jsonrpc: '2.0', id: 2, method: 'tools/list' }, hdr);
const tools = list.data.result.tools
.map((t) => ({ name: t.name, description: t.description, inputSchema: t.inputSchema, annotations: t.annotations }))
.sort((a, b) => a.name.localeCompare(b.name));
const hash = createHash('sha256').update(JSON.stringify(tools)).digest('hex').slice(0, 12);
console.log(JSON.stringify({ initMs: init.ms, listMs: list.ms, tools: tools.length, hash }));
Store the last hash and exit nonzero when it differs or the call fails, and any scheduler becomes a monitor. Two limits: it follows only the first page of tools/list (pagination uses nextCursor), and JSON.stringify depends on key order, so use a canonical serializer if your server reorders keys. It does not cover the 2026-07-28 request shape.
Alerting without noise
Page on a confirmed outage, a missing tool or a failing auth boundary. Send description changes and latency creep to a channel. Do not send the same alert repeatedly. Add a recovery message so people know when to stop looking.
What Shipyard does
Shipyard monitoring covers these checks: a handshake every 5 minutes, a tool diff with each handshake, your marked-safe fixtures hourly, an alert after two failed handshakes in a row, and no repeat of the same alert within six hours. It does not replace the checks above that need your own account, such as the authenticated probe, unless you give it one.
Check your server
Run the free scan at /scan for a one-off version of checks 1 and 5: the handshake and tools/list timing, from outside your network.
Check your server against these rules
Scan runs the checks from this guide against a live URL and lists each failing rule with its fix.