Tools

The All Aboard MCP server exposes the following tools to the model. The model decides which tools to call based on the task at hand.

list_documentation

Lists all available documentation sections and pages with short descriptions. Use this first to discover what is available before fetching specific content.

Parameters: None

Example output:

## Getting Started
- Introduction: Overview of All Aboard products and quick start guide
- Getting Started: Prerequisites, API endpoints, authentication setup
...
## Getting Started
- Introduction: Overview of All Aboard products and quick start guide
- Getting Started: Prerequisites, API endpoints, authentication setup
...

read_documentation

Returns the complete All Aboard API documentation as a single plain-text document. This is a large response (~170KB) covering all pages: getting started, booking flows, rail passes, payments, refunds, embeds, blueprints, and error codes.

Use this when you need broad context about the API, or when list_documentation has identified that several sections are relevant to the task.

Parameters: None

explore_schema

Browses the live GraphQL schema. Returns operation signatures with argument types and return types, or a list of available types.

Parameters:

ParameterTypeDescription
categoryqueries | mutations | subscriptions | typesWhich category to list
filterstring (optional)Case-insensitive name filter

Example — list all queries containing "journey":

explore_schema({ category: "queries", filter: "journey" })
explore_schema({ category: "queries", filter: "journey" })

Example output:

- **getJourneys**(origin: String!, destination: String!, date: String!, filter: JourneyFilterInput): [Journey!]!
  Find available train routes between two locations on a specific date.
- **getJourneyOffer**(journey: ID!, passengers: [PassengerInput!]!): JourneyOffer
  Get pricing and offers for a journey.
- **getJourneys**(origin: String!, destination: String!, date: String!, filter: JourneyFilterInput): [Journey!]!
  Find available train routes between two locations on a specific date.
- **getJourneyOffer**(journey: ID!, passengers: [PassengerInput!]!): JourneyOffer
  Get pricing and offers for a journey.

get_type

Returns full details of a specific GraphQL type: all fields with their argument types and return types, enum values, input fields, interfaces implemented, and possible types for unions/interfaces.

Parameters:

ParameterTypeDescription
namestringExact name of the type (e.g. Journey, Booking, PassBundle)

Example:

get_type({ name: "Booking" })
get_type({ name: "Booking" })

If the type is not found, the tool returns suggestions for similarly named types.

execute_query

Executes a GraphQL query or mutation against the All Aboard API and returns the JSON response.

Each call requires the user's own API key passed as the apiKey parameter. The MCP server does not store or inject credentials — the key is sent directly to the API on the user's behalf and is not retained between calls. If the user has not provided their API key, ask for it before calling this tool.

API keys are available from the All Aboard Dashboard.

Parameters:

ParameterTypeDescription
querystringGraphQL query or mutation string
variablesobject (optional)Variables for the operation
apiKeystringYour All Aboard API key, available from the dashboard
environmentlive | test (default: test)Which environment to execute against

Always use test first

The environment parameter defaults to test. Only switch to live when you are confident the query is correct — live executions create real bookings and charges.

Example:

graphql
query FindJourneys {
  getJourneys(
    origin: "Sb0ISveC"
    destination: "p6fERure"
    date: "2025-06-15"
  ) {
    id
    itinerary {
      duration
    }
  }
}
query FindJourneys {
  getJourneys(
    origin: "Sb0ISveC"
    destination: "p6fERure"
    date: "2025-06-15"
  ) {
    id
    itinerary {
      duration
    }
  }
}

GraphQL errors in the response are surfaced clearly alongside the full response body for debugging.