Skip to main content

Connecting Claude or Copilot (MCP)

TrackMyMachines exposes an MCP server — a standard interface that lets AI assistants query your machine data directly. Once connected, you can ask questions in plain English ("which machines had the most downtime last week?") and the assistant fetches the answer from the same aggregated data that powers your dashboards.

MCP is an open standard, so this works with any assistant that supports it. The two most common are Claude (claude.ai, the Claude desktop app, Claude Code) and Microsoft Copilot (Copilot Studio, Copilot CLI, GitHub Copilot in VS Code). Cursor, ChatGPT custom connectors and Gemini CLI connect the same way.

The connection is read-only. The assistant can read your organisation's machine and production data; it cannot change anything, and it cannot see other organisations.

Your MCP endpoint​

There are two addresses, and either works with both ways of connecting below.

Your organisation's own endpoint, on the subdomain you sign in at:

https://your-org.trackmymachines.app/mcp

Replace your-org with your organisation's subdomain — it's the first part of the address you use to sign in. If you log in at https://acme.trackmymachines.app, your MCP endpoint is https://acme.trackmymachines.app/mcp. The examples on this page use this form.

The shared endpoint, the same for every organisation:

https://mcp.trackmymachines.app/mcp

Here your sign-in or API key decides which organisation you see. Use it where a tool needs one fixed URL, or you'd rather not look up your subdomain.

note

Either way, a connection only ever returns one organisation's data. On your own subdomain, the credential must belong to that organisation and is refused otherwise. On the shared endpoint, the organisation is the one the credential belongs to.

There are two ways to connect, and which one you use depends on the tool rather than on your preference. Apps that sign you in with a browser use Option 1; tools configured with a file use Option 2.

Option 1: Sign in (Claude and Copilot apps)​

Use this from claude.ai, the Claude desktop app, Copilot Studio or Copilot CLI. You sign in with your normal TrackMyMachines account and no API key is involved.

Claude (web and desktop)​

  1. In Claude, open Settings → Connectors
  2. Click Add custom connector
  3. Give it a name (for example, TrackMyMachines) and paste your endpoint URL:
    https://your-org.trackmymachines.app/mcp
  4. Click Add. Claude opens a TrackMyMachines sign-in window.
  5. Sign in with your usual username and password if you aren't already signed in.
  6. A confirmation screen names your organisation and what the connector will be able to do. Click Connect.

Claude returns to the connector list and the connection is ready. In a new chat, enable the connector from the attachments (+) menu and start asking questions.

Copilot​

Copilot Studio and Copilot CLI both register themselves automatically — you only ever give them the URL.

  1. Add a new MCP server and paste your endpoint URL:
    https://your-org.trackmymachines.app/mcp
    In Copilot Studio this is under Tools → Add a tool → New tool → Model Context Protocol. In Copilot CLI, use /mcp add and choose the HTTP transport.
  2. Copilot discovers the sign-in service and opens a TrackMyMachines sign-in window.
  3. Sign in, then approve the same confirmation screen described above.
warning

Shared logins used for tablets and wall displays cannot authorise a connector. Sign in with your own named account.

Option 2: API key (Claude Code, VS Code and Cursor)​

Tools that are configured with a file — Claude Code, GitHub Copilot in VS Code, Cursor, your own scripts — authenticate with an API key instead of signing in.

First create a read-only API key: go to API Keys in the main menu and click Create New API Key. Copy the key when it's shown; it's only displayed once.

Claude Code​

claude mcp add --transport http trackmymachines \
https://your-org.trackmymachines.app/mcp \
--header "Authorization: Bearer YOUR_API_KEY"

GitHub Copilot in VS Code​

In .vscode/mcp.json:

{
"servers": {
"trackmymachines": {
"type": "http",
"url": "https://your-org.trackmymachines.app/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}

Cursor and other JSON-configured clients​

{
"mcpServers": {
"trackmymachines": {
"url": "https://your-org.trackmymachines.app/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}

What the assistant can do once connected​

The connector provides eight read-only tools. You don't need to call these yourself — the assistant picks the right one — but knowing what's there tells you what to ask for:

ToolWhat it does
list_chartsLists the datasets with their descriptions and the columns each returns
describe_chartExplains one dataset: every column with its format, unit and your organisation's target where there is one, which time grains and groupings it supports, its defaults, filters and row order
query_chartRuns a dataset query and returns the rows, 500 at a time (it pages for more)
list_factoriesLists your factory → area → machine hierarchy as a tree
list_machinesLists your machines and shift patterns, with the area and factory each machine sits in
list_reason_categoriesLists your downtime reason categories, the reasons in each and their kind
list_dashboardsLists your dashboards and the insights on each, with the dataset behind every insight
query_insightReturns the data behind one saved insight, with its own window, scope, shifts and downtime filters applied

The data is the same datasets documented under Datasets — downtime, downtime_pareto, downtime_stops, downtime_events, utilisation, energy, idle_energy, power, parts, oee, job_oee, cycle_times and work_orders — between them, every figure a dashboard draws. Every one of them returns rows, and every row carries every figure that query produces: to answer "what was our availability", the assistant reads the availability column of oee rather than fetching a different thing.

note

The tool names still say chart — they are a published contract that existing connectors depend on. What they operate on is a dataset.

Asking about a dashboard​

"What does my OEE dashboard say?" is answerable directly: the assistant lists your dashboards, picks the insight, and runs it with the insight's own saved window, machines, shifts and downtime filters. The answer names the column the tile draws, and any pin the data could not honour (a shift selection on OEE, for instance) is reported rather than silently dropped. Signed in, you see the dashboards your own account can; with an API key, every dashboard in the organisation.

A filter a dataset cannot honour is refused with a sentence saying which datasets take it — never quietly ignored. Calls are limited to 60 a minute per connection.

Asking about a site or a cell​

Your assets are a three-level hierarchy — factory (Site) contains areas (Cells), which contain machines — and every chart can be scoped to any level of it by name. So "OEE for the West site today" is a single scoped question, not something the assistant has to assemble by picking machines out of a list.

If you name a level that doesn't exist, or a cell where a site was expected, the connector says so rather than quietly answering for the whole organisation. Answers come back with the machines the scope resolved to, so you can check the figure covered what you meant.

Things to ask​

  • "What was our spindle utilisation last week, broken down by machine?"
  • "What's OEE for the West site today, and how does it compare with East?"
  • "Which downtime reasons cost us the most hours this month?"
  • "Compare OEE across our machines for the last 30 days and tell me where the biggest loss is."
  • "Show me the shift breakdown for the CNC cell in June."
  • "What's the MTBF and MTTR of each machine this week, and what stops them most?"
  • "Which work orders are behind target and due this week?"
  • "What does the Shop Floor dashboard say this morning?"

Filters take names rather than IDs, so you can refer to factories, areas, machines, shift patterns and downtime categories exactly as they appear in TrackMyMachines.

Reading the answer​

Two things the assistant is told to check on every query, and worth knowing about yourself:

  • The window and grain it actually got. Ask for hourly data over a year and the request is corrected to something the query can serve — the correction comes back with its reason, and the assistant is instructed to read that rather than assume it got what it asked for.
  • Units. Percentages come back as 0–1 fractions and durations as whole seconds, and every column says which it is. A figure quoted as "0.87" is 87%.

Access and security​

  • Read-only. Every tool is a read. The connector cannot clock jobs, change reasons, or edit any setting.
  • Scoped to one organisation. A connection is bound to one organisation — the one whose subdomain you used, or on the shared endpoint the one your sign-in or key belongs to — and is re-checked on every request.
  • No row-level restriction. Anyone who can connect sees all of that organisation's machine data — the connector does not narrow results by machine, cell or site. (Dashboards are listed as your account would see them when you signed in.) If a user shouldn't see a machine's data, they shouldn't be given a connector.
  • Revoking access. To revoke a connection made by signing in, contact your TrackMyMachines administrator. Connections made with an API key are revoked by deleting that key under API Keys.
  • Removing a user. Deleting or disabling a user's TrackMyMachines account also stops any connector they had authorised.
warning

Treat API keys like passwords. Never share them or commit them to version control.

Troubleshooting​

"Couldn't register with the sign-in service" — check the URL. It must be https://, must use your own organisation's subdomain or mcp.trackmymachines.app, and must end in /mcp.

The connector added but every request fails — you may be signed in to TrackMyMachines as a different organisation than the subdomain you entered. Remove the connector and add it again using the subdomain you actually sign in at, or use the shared endpoint, https://mcp.trackmymachines.app/mcp.

401 Unauthorized with an API key — the key has expired, has been deleted, or belongs to a different organisation than the subdomain in the URL (the shared endpoint doesn't have this problem). Create a fresh read-only key and update your configuration.