Transit Data MCP
MCP server over Norwegian public transport reference data (NeTEx): lines, service journeys, quays, stop places, operators, authorities and journey patterns, with read-only tools to look up one entity or page through many.
Transit Data MCP is a Model Context Protocol (MCP) server over Entur's NeTEx-derived transit reference data. Connect it to an MCP-capable AI client and the assistant can look up lines, service journeys, the quays they call at, stop places, operators and authorities, and page through any of them.
Connecting
Point your MCP client at https://api.entur.io/transit-data/v1beta/mcp.
The endpoint is public and needs no authentication. Identify your client
with the ET-Client-Name header, in the form <company>-<application>
(lowercase, no spaces); see
Client identification.
Tools
Each kind of entity has a read-only tool that looks up one entity by
identifier (serviceJourney, quay, line, ...) and one that pages through
them (serviceJourneys, quays, lines, ...). Experimental data
(real-time departures, geo-queries, activeDates) is not offered as tools and
is rejected if requested through fields.
A tool takes its own arguments, plus an optional fields:
fieldsis a GraphQL selection set for the entity the tool returns, such asid line { id name }. Without it, a tool returns the entity's scalar and enum fields. Each tool'sfieldsdescription lists what can be selected on that entity, one level deep.- A tool that returns a page (
quays,lines, ...) takesfirstandafter. The result has the entities undernodes(underedges { node }fordatedServiceJourneys) and apageInfowithhasNextPageandendCursor; passendCursorasafterfor the next page. For these toolsfieldsdescribes one entity, not the page.
Tool results
A tool result carries the GraphQL response as JSON text in content[0].text:
{"data": ...} on success. When the call did not do what it asked for (a
missing required argument, an unknown or experimental field, an invalid
fields), the result has isError: true and the text is {"errors": [...]}
or a plain message. An unknown tool name is reported the same way, not as a
JSON-RPC error.
Transport
The server speaks Streamable HTTP in stateless mode, so any replica can
answer any request. See the /mcp operation for the details and the status
codes.